Special charecters problem
- From: "NurAzije" <nurazije@xxxxxxxxx>
- Date: 22 Oct 2005 02:26:30 -0700
I have written a code and can't figure what is wrong, the code will
read a content of a file and cut all the emails from it,then echo them,
but I have a problem with '"' charecter I think..
Take a look:
****************************
<?php
$url="http://www.bihstudenti.com/kontakt.php";
$lines = file_get_contents($url);
$done=explode("@",$lines);
for($i=0;$i<count($done)+1;$i++)
{
$j=$i+1;
$a=strrpos($done[$i],":");
$b=strrpos($done[$i],">");
$c=strpos($done[$j],chr(34));
$d=strpos($done[$j],"<");
$front=$done[$i];
$back=$done[$j];
if($a>$b){
if($c<$d){
echo "Line $i
".substr($front,strrpos($front,":")+1)."@".substr($back,0,strpos($back,chr(34)))."<br>";
}else{
echo "Line $i
".substr($front,strrpos($front,":")+1)."@".substr($back,0,strpos($back,"<"))."<br>";
}
}else{
if($c<$d){
echo "Line $i
".substr($front,strrpos($front,">")+1)."@".substr($back,0,strpos($back,chr(34)))."<br>";
}else{
echo "Line $i
".substr($front,strrpos($front,">")+1)."@".substr($back,0,strpos($back,"<"))."<br>";
}
}
}
?>
****************************
I am looking at www.bihstudenti.com/kontakt.php content..
Please help, do any one have a clue what is wrong..
.
- Follow-Ups:
- Re: Special charecters problem
- From: ingspi
- Re: Special charecters problem
- Prev by Date: PHP system(), exec(), passthru()
- Next by Date: Re: PHP system(), exec(), passthru()
- Previous by thread: PHP system(), exec(), passthru()
- Next by thread: Re: Special charecters problem
- Index(es):
Relevant Pages
|