On Fri, 11 Jul 2003 00:53:32 -0400, you wrote:

>foreach ($profileArray[$i][attributes] as $key => $val) {
>     $singleProfileHTML .= $key . "=\"" . str_replace("'", ''', str_replace('"', 
> '"', $val)) . "\"\n";
>    }
>
>The parsing error occurs in the "$singleProfileHTML.." line.  I'm completely don't 
>get it; I see absolutely nothing wrong with this, what did I miss?

Line 1 - attributes should have a $ in front of it, or be a string literal.

BTW, that's a really nasty line. Maybe it would be easier to read as :

foreach ($profileArray[$i][$attributes] as $key => $val) {
        $val = str_replace('"', '"', $val);
        $val = str_replace("'", ''', $val);
        $singleProfileHTML .= "$key=\"$val\"\n";
}


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to