Currently, I am utilizing regular expressions to identify CSS values.
The input string that needs to be matched is:
font-size:25px;font-family:georgian;content:"' unicode given in pseudo © '";
The specific regex pattern I am using for the matching process is:
/.*\bcontent:(\s*[^;]*)/
I am retrieving the actual string output of the regex by using $1.
The expected output should be "' unicode given in pseudo © '".**
However, the current output is "' unicode given in pseudo ©
This discrepancy occurs because the regex detects the semicolon inside the content value and breaks there. To resolve this bug, I need the regex to locate the last semicolon that is not within the quotes. The reason for this is that each property value in my input string will always end with a semicolon.
Thank you!