Re: split string into array with 2 delimiters Programming Web Development by Thyvo … got this error when trying it out: Warning: preg_split() [function.preg-split]: Delimiter must not be alphanumeric or backslash in C:\xampp… Re: split words and numbers Programming Web Development by diafol …;NUM: $num WORD: $word" : "ERROR"; Of course, preg functions have the advantage of **easily** being able to check… Re: split words and numbers Programming Web Development by LastMitch >Of course, preg functions have the advantage of easily being able to check … preg_split issue Programming Web Development by samsambm … but I'm getting the error : "Warning: preg_split() [function.preg-split]: No ending delimiter '=' found in C:" The code is…;',$request_url ); $page_is = array_shift($parsed_url ); $getVars = array(); foreach($parsed_url as $argument) { //split GET vars along '=' symbol to separate variables and values list… Re: preg_split issue Programming Web Development by C#Jaap …[/URL] Withing preg_split you should use a regular expression to split. An regular expression string starts with a character that also… Re: What is the php regular expression to get everything before a certain character? Programming Web Development by jedi_ralf …curious.[/QUOTE]"explode() takes a delimiter to split by ... split() takes a regular expression" "documentation…url]http://forums.codewalkers.com/php-coding-7/split-vs-preg-split-vs-explode-71423.html[/url] So in answer… to your question, preg_split uses regex like split. … Re: echo part of url Programming Web Development by IIM Instead of explode you can use preg_split here to split on the basis of mutiple delimiters.It will return array. http://php.net/manual/en/function.preg-split.php The first parameter is regular expression and second is data you want to split.In your case it is URL. $urlstring = preg_split( "/([,]|[\/])/", $urlstring ); Re: PHP to parse at | and at ^ Programming Web Development by jondoughty … code worked. How would I display the output of the preg split? Before I used [CODE] echo "Test: ".$data[2… import file and get rid of certain charaters Programming Web Development by HITMANOF44th … to get rid of " character from the file then split it by , and ideas or a kick in the right… direction would be appreciated i also tryed to preg by , but still cnat get it right my code now… Re: Preg_match regex help Programming Web Development by Setvir … impossible task ;-)) from raw emial data. This preg should use be able to split the following strings: multipart/alternative; boundary="001636284f500b21f90494114b4d…="001636284f5"\; fy="00b21f90494114b4d" It should only split on the one (or multiple) ';' character except where it is… Re: Rewrite Javascript validation code as PHP code Programming Web Development by pritaeas Here's one hint: https://www.php.net/manual/en/function.preg-match.php Re: preg_split issue Programming Web Development by samsambm Hi. Thanks for the reply . I used "!=!" insted of "=" and didnt got the error. Issue solved. Re: Reading a file in PHP Programming Web Development by Atli …just a waste of resources. [*]The [url=http://php.net/split]split[/url] function, and the rest of the POSIX functions, … should be using the [url=http://php.net/pcre]PCRE (preg) functions[/url] [i](See the example below)[/i]. [*]Your… for a patter, rather than using a regular expression to split the string. [code=php] <?php // Set headers and… Re: Check a string for <img> tag and if it has a valid file extension Programming Web Development by diafol … img tag in the html. For this, pehaps best to split "<img and first following ">" into… an array and then apply the preg. In which case, you just search for the [B]/src… Re: Check a string for <img> tag and if it has a valid file extension Programming Web Development by Aksel … img tag in the html. For this, pehaps best to split "<img and first following ">" into… an array and then apply the preg. In which case, you just search for the [B]/src… Re: How to trap time range in mysql table with same day Programming Web Development by diafol … quite understand what you're trying to achieve. Is it split the string into parts, to get the day? IF so…;; $r = preg_split('/ /',$str); $day1 = $r[count($r)-1]; echo "PREG DAY: $day1 <br />"; $pos = strrpos($str, "… Re: How to extract all email addresses from a string Programming Web Development by ddymacek Just for fun, I coded up something for you. Yes preg match is much more elegant but does not meet all … replace the commas, semis; and <> tags before you split the string, SO: $str = str_replace(',',' ',$str); $str = str_replace("<… Re: import file and get rid of certain charaters Programming Web Development by ShawnCplus PHP has a built-in function to parse CSV files: [url]http://us3.php.net/manual/en/function.fgetcsv.php[/url] Re: import file and get rid of certain charaters Programming Web Development by HITMANOF44th suprisingly i did not find that in my travels of the world wide web thanks for the reply