I have this known issue with special characters < > " & and the powermail extension in Typo3. I already googled and found that it's related to double trigger of the htmlspecialchars in 2 files. I tried many suggestions but they just didn't help.
- removed htmlspecialchars from class.tx_powermail_html.php.
- removed it from class.tx_powermail_markers.php.
- ...
does somebody has an exact solution to this issue?
thanks in advance.
Ps: I am using v. 1.6.9 on typo3 4.5
well ,
I could find an answer in case somebody faces the same problem. Just comment out both appearances of "htmlspecialchars" in the function sec() in "lib\class.tx_powermail_functions_div.php".
That should fix it
Related
I have a problem with Nagvis. There I created several maps with the locations of hosts and used the service lines to display the bandwidth and utilization of individual interfaces. It all worked well until we eventually switched to CheckMK 2.0. We have renamed the interfaces and theoretically it would not be a problem to simply transfer the new names to NagVis.
However, the regex error mentioned below occurs. I also checked the new label with the regex using regex101 and found that the label has changed. It is structured according to the pattern: 'Interface_Name "Interface description"'. Nagvis's regex doesn't allow quotes, and thus neither does the name of the interface.
I'm relatively new to this and haven't had much to do with it before. One solution would be to escape the quotation marks, but I don't know where to do that. If you have any suggestions for a solution, I would be very grateful.
If you have any questions, just ask.
CMK version: 2.0.0p26
OS version: Windows 10
Error message: The attribute has the wrong format (Regex: /^[0-9a-zа-яё\p{L}\s:+_.,'-*?!##=/]+ $/u).
Can someone help me understand why I am getting a syntax error for this PHPMyAdmin query? A developer did a find and replace for window popups and it truncated the replacement on hundreds of pages to 'onclick="return false;"' by mistake. Full code needed in in the replacement field below.
UPDATE `r61bq_content` SET `introtext` = replace(introtext, 'onclick="return false;"', 'onclick="window.open(this.href, \'\', \'resizable=no,status=no,location=no,toolbar=no,menubar=no,fullscreen=no,scrollbars=no,dependent=no,width=500,height=50\'); return false;"')
thanks in advance!
I was able to do it with the PHPMyAdmin find and replace:
onclick="window.open(this.href,\'\', \'resizable=no,status=no,location=no,toolbar=no,menubar=no,fullscreen=no,scrollbars=no,dependent=no,width=500,height=50\'); return false;"
if anyone needs to know.
I am creating custom snippets for flutter/dart. My goal is to pull the file name (TM_FILENAME_BASE) remove all of the underscores and convert it to PascalCase (or camelCase).
Here is a link to what I have learned so far regarding regex and vscode's snippets.
https://code.visualstudio.com/docs/editor/userdefinedsnippets
I have been able to remove the underscores nicely with the following code
${TM_FILENAME_BASE/[\\_]/ /}
I can even make it all caps
${TM_FILENAME_BASE/(.*)/${1:/upcase}/}
However, it seems that I cannot do two steps at a time. I am not familiar with regex, this is just me fiddling around with this for the last couple of days.
If anyone could help out a fellow programmer just trying make coding simpler, it would be really appreciated!
I expect the output of "my_file_name" to be "MyFileName".
It's as easy as that: ${TM_FILENAME_BASE/(.*)/${1:/pascalcase}/}
For the camelCase version you mentioned, you can use:
${TM_FILENAME_BASE/(.*)/${1:/camelcase}/}
I'm dealing with some google spreadsheet with data, some of which is in a very confused way, but regular, so i hope we can figure this out.
I've tried reg ex builders but I can't find the right one for google sheets or I misunderstand some stuff.
I would appreciate help with these sentances below:
1. {"user":{"Czy faktura?":"Y","Nazwa firmy":"Name of the company ","NIP":"113 234 20 57"}}
2. {"user":{"Czy faktura?":"Y","Nazwa firmy":"The longer name of the company","NIP":"2352225961"}}
3. {"user":{"Czy faktura?":"N","Nazwa firmy":"","NIP":""}}
The point is to extract: (using arrayformula in google sheets)
Y or N
Name of the company
NIP number
Problems:
The name of the company has different lengths, and the NIP number is sometimes with white-spaces.
Do you guys have any idea how can I properly use it?
I know it's the REGEXEXTRACT formula of course :)
Just have a problem on how to formulate the regular expression..
=regexreplace(B1, "(^.*Nazwa firmy"":"")(.*)("",""NIP.*$)", "$2")
Well the support was fantastic :)
After all, a simple "Y|N" solves the first problem
I used #ttarchala's solution for the company name as it seems to work for some reason - i don't know why or how :)
"(^.Nazwa firmy"":"")(.)("",""NIP.*$)", "$2"
and the NIP is isolated by this one: "NIP\"":\""(.+)\"""),"-|\s","" and later trimmed of off the "-" minus and whitespaces signs.
cheers
I'm quite new to coding but i'm makin' my way through it :)
So here is my problem.
I'm using this code which is working perfectly except this one little thingy. Links are being blocked also if it is the ending of a sentence like:
this.communication works well
It should only match if there is a space/blank after the TLD.
on $#*:text:*:#:{
if ($regex($1-,/.+\.(ftp|thalia|com|ly|ml|gl|tk|ga|biz|co|net|org|gov|tv|edu|fm|myftp|myftp.biz)/iS)) && ($nick !isop $chan) {
if (!$istok(%permit,$nick,32)) {
.timerban 1 1 /msg $chan /ban $nick
msg $chan $Nick , posting links without permission is not allowed.
}
}
Maybe you guys can help me and I think i isn't a big issue but I'm searching for weeks now and can't find anything!
Big thanks in advance and sorry .. english isn't my native language.
Cheers, Marv
You can use
/.+\.(ftp|thalia|com|ly|ml|gl|tk|ga|biz|co|net|org|gov|tv|edu|fm|myftp|myftp.biz)( |\/|\n|\r)/iS
instead so it needs that the string has a space, a / or a newline.