Jump to content

phpsycho

Members
  • Posts

    164
  • Joined

  • Last visited

    Never

Everything posted by phpsycho

  1. I got this code.. $expr = '\(?:http://){0,1}(?:www.){0,1}youtube.com/watch\?.*?v=([^&[]++)[^[]*+/is'; $replacement = '${1}1,$3'; $string = preg_replace($expr, $replacement, $string); I am not familiar with regex well enough to understand the problem here. the \ in the front of $expr and the /is at the end is causing this code not to work. No idea what I am supposed to have there instead. Been messing around with the code but can't figure out how to fix it. Warning: preg_replace(): Delimiter must not be alphanumeric or backslash in /var/www/se1/includes/functions.php on line 74 Warning: preg_replace(): Delimiter must not be alphanumeric or backslash in /var/www/se1/includes/functions.php on line 74 Warning: preg_replace(): Delimiter must not be alphanumeric or backslash in /var/www/se1/includes/functions.php on line 74 Warning: preg_replace(): Delimiter must not be alphanumeric or backslash in /var/www/se1/includes/functions.php on line 74 Warning: preg_replace(): Delimiter must not be alphanumeric or backslash in /var/www/se1/includes/functions.php on line 74
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.