> var rule2 = eval('/' + txt + '\s/i');
> console.log(str2.match(rule2)); // returns fooSz

Try var rule2 = eval('/' + txt + '\\s/i');


Regards,
Rimantas
--
http://rimantas.com/


*******************************************************************
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
*******************************************************************

Reply via email to