dj03091986 Posted January 23, 2015 Share Posted January 23, 2015 Hi everyone, I'm new to this and a little stuck. Please could someone help me. I have the following code: if (!preg_match('^(' . $value . ')(;q=[0-9]\\.[0-9])?$', $this->browser_languages[$i]) && isset($this->catalog_languages[$key]')) { $this->language = $this->catalog_languages[$key]; break 2; When I test the code I get the following error. preg_match() [<a href='function.preg-match'>function.preg-match</a>]: No ending delimiter '^' found /public_html/includes/classes/language.php 87 Please help me Thanks in advance Quote Link to comment Share on other sites More sharing options...
Ch0cu3r Posted January 23, 2015 Share Posted January 23, 2015 You need apply delimiters to your regex pattern Quote Link to comment Share on other sites More sharing options...
dj03091986 Posted January 23, 2015 Author Share Posted January 23, 2015 Thanks for your speedy reply, I'm sorry, how would I do that ? Quote Link to comment Share on other sites More sharing options...
Ch0cu3r Posted January 23, 2015 Share Posted January 23, 2015 Did you click the link? It explains it all in there. Quote Link to comment Share on other sites More sharing options...
dj03091986 Posted January 23, 2015 Author Share Posted January 23, 2015 I didnt :-) I will do now, thanks for the help :-) Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.