Questions tagged as 'regex'

1
answer

Put flag at bash shell command line

I'm trying to put a flag that can sort or shuffle the output, but I could only do that in code and intended it to work when I put the flag on the command to run the file, for example ./bash.sh -r .     
asked by 02.01.2018 / 22:34
1
answer

regex for url validation

I've done this regex to validate URL: const std::regex pattern( "(?:(ftp|http[s]?:[//])?)?([w]{3}[.])?" "(.*[.](com|php|net|org|br|dk|at|us|tv|info|uk|co.uk|biz|se)?)?" "(.*[.](aspx|htm|html|HTM|HTML|jhtm|jhtml|JHTM|JHTML|xhtm|xhtml|X...
asked by 27.12.2017 / 22:45
0
answers

Replace, tag with attributes for document merging

Hello, I am creating a document that makes it possible to merge through tags, but I will allow the user to add a separator within the tag, because I am doing this, in the case of a qualification of a client my system would do so Qualification...
asked by 27.12.2017 / 11:52
3
answers

Find record with regular expression in mssql

I have a column that stores data in the following pattern #campo#=valor;#campo#=valor (and so on) ex: '#aaaa#=1111;#bbbbb#=2222;#cccc#=33333' However, they added ; within the value and I wanted to find them, I need to...
asked by 11.01.2018 / 13:31
1
answer

Regex to validate the mime type

What would be the regex to validate this mime types only image / bmp image / gif image / x-icon image / pjpeg image / jpeg image / png I want to make a image upload system only , in case of this mime types: $verifyimg = getim...
asked by 10.11.2017 / 17:29
2
answers

Txt block with Regex

How do I get block by block of a txt with this format? I have to pick up the last date. Sometimes there are two dates in each block AAAAAAAAAA AAAAAAAAAAA - AAAAAAAAAAAAA AAAAAAAAAAAAAAAAAAAA AAAAAAAA em: 20/04/2017 AAAAAAAAAA AAAAAAAAAAA - A...
asked by 29.11.2017 / 19:53
1
answer

Regex Regular expression - Include parentheses in place of quotation marks

How do I change the quotation marks for a tag? working to convert (* .dml -> delphi form) where something that was as text becomes list (stringlist). Text Example: CommandText = 'SELECT * FROM PRODUTOS' We want to convert to SQL.Text =...
asked by 27.10.2017 / 17:42
1
answer

Find file via file_exists with partial name

I need to check for a file in two domains. However, the format of the file that is written to the database does not match the one recorded on the server, for a few seconds delay (the format of the file name is shown in the example below)....
asked by 13.10.2017 / 16:04
2
answers

Regex - Removal of Special Characters C #

Regex.Replace is a great solution to remove accent. Now I just can not remove a character type, I have a string that receives the text "1st General Place" , in the string it has the character '°' / strong>, is there a list for these types...
asked by 19.07.2014 / 19:07
1
answer

Regex problem for UserAgent Android

I'm trying to create a regex (for use in PHP) that can match the groups correctly and extract the information I need. In this case it is to get information from android useragent. When the userAgent is like this:    p> Of course,...
asked by 05.09.2017 / 14:21