views:

15

answers:

2

I'm trying to port a code from PHP to C++. I was using the PHP build-in regular expression to extract some value and it works well. From some reason the same reg expression does not work when using the boot regexp library.

Could anyone spot what I'm doing wrong:

reg exp: regex exp("__EVENTVALIDATION" value="(.*)");

and the string is:

    <input type="hidden" name="__EVENTVALIDATION" id="__EVENTVALIDATION" value="/wEWBQL5gZjOBAL3+ML0DwL9ooevDwKMxOHvBwKJwsCnBEiKdYmQYZ6urlXsMG74R8hkXeMM" />

I need to extract the value.

Thanks

A: 

You probably need to escape the quotes for c++. Like so

regex exp("__EVENTVALIDATION\" value=\"(.*)");

abdollar
A: 

I just did it, no success. The regular expression was as you wrote it.

embedded