> > //print "<LI><A HREF='$_SERVER['PHP_SELF']?letter=$chars[$cnt]'>" .

This is the problem with not breaking out of a string to display a variable.
Ideally, you would do it this way:

print "<LI><A HREF='" . $_SERVER['PHP_SELF'] . "?letter=" . $chars[$cnt] .
"'>";

But some people just have a problem with doing it that way, so you can use
braces.

print "<LI><A HREF='{$_SERVER['PHP_SELF']}?letter={$chars[$cnt]}'>";

If you don't use the braces, how is PHP supposed to know what you mean. Do
you mean to print a variable called $_SERVER, followed by a literal
['PHP_SELF'], or do you mean an array? How is PHP supposed to decide for
you? Like your second variable, $chars. Is that an array? Do you mean to
print out the value of an $chars element, or do you mean to print out value
of $char, followed by "[", value of $cnt, followed by "]" ??

Hope that helps.

---John Holmes...



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

Reply via email to