Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

ereg - to - Preg_match


Kasketkarl.nu

Recommended Posts

Posted

Hello.

I need to change this line:

 

if (ereg('_', $cPath))

 

to preg_match - how does this works?

 

I just tryed to

 

if (preg_match('_', $cPath))

 

without any / that didnt work

 

Can someone help ? :)

thanks

Posted

Try

 

if (preg_match('/_/', $cPath))

Mark Evans

osCommerce Monkey & Lead Guitarist for "Sparky + the Monkeys" (Album on sale in all good record shops)

 

---------------------------------------

Software is like sex: It's better when it's free. (Linus Torvalds)

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...