Thanks!
Leon Poon wrote:
The simplest way to make sure everything work well regardless of what
the values are:
?
$url = somepage.php?var1=.urlencode($var1).var2=.urlencode($var2);
echo a href=\.htmlspecialchars($url).\;
?
htmlspecialchars() changes characters '', '', ''', '', '' into the
Marek Kilimajer wrote:
Jack Jackson wrote:
Murray @ PlanetThoughtful wrote:
If I want to make a link to a URL which includes some GETs can I
just do:
a href='{$_SERVER['PHP_SELF']}?p={$p}c={$s}' ... etc etc
or must I escape the ampersand somehow?
...
You should use amp; for all
I actually forgot that 's are supposed to be amp;'ed when putting
them into SGML(HTML . XML, etc). I retract my previous statments on
the matter.
On 6/4/05, Jack Jackson [EMAIL PROTECTED] wrote:
Rory Browne wrote:
On 6/4/05, Jack Jackson [EMAIL PROTECTED] wrote:
Hi, Rory
Rory Browne
Hi,
If I want to make a link to a URL which includes some GETs can I just do:
a href='{$_SERVER['PHP_SELF']}?p={$p}c={$s}' ... etc etc
or must I escape the ampersand somehow?
TIA,
--Jack
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
I think you have the idea. The 's are used to seperate the various
variables. If you want to set $p to something like 'Tom Jerry' then
personally I'd do something like:
?php
$p = Tom Jerry;
$s = Cat Mouse;
printf(a href='{$_SERVER['PHP_SELF']}?p=%ss=%s, urlencode($p),
urlencode($s));
?
On
Hi, Rory
Rory Browne wrote:
I think you have the idea. The 's are used to seperate the various
variables. If you want to set $p to something like 'Tom Jerry' then
personally I'd do something like:
?php
$p = Tom Jerry;
$s = Cat Mouse;
printf(a href='{$_SERVER['PHP_SELF']}?p=%ss=%s,
If I want to make a link to a URL which includes some GETs can I just do:
a href='{$_SERVER['PHP_SELF']}?p={$p}c={$s}' ... etc etc
or must I escape the ampersand somehow?
Depends very much on the document type of your page. Valid XHTML
(transitional, at least), for example, doesn't like
On 6/4/05, Jack Jackson [EMAIL PROTECTED] wrote:
Hi, Rory
Rory Browne wrote:
I think you have the idea. The 's are used to seperate the various
variables. If you want to set $p to something like 'Tom Jerry' then
personally I'd do something like:
?php
$p = Tom Jerry;
$s = Cat
Murray @ PlanetThoughtful wrote:
If I want to make a link to a URL which includes some GETs can I just do:
a href='{$_SERVER['PHP_SELF']}?p={$p}c={$s}' ... etc etc
or must I escape the ampersand somehow?
Depends very much on the document type of your page. Valid XHTML
(transitional, at
Jack Jackson wrote:
Murray @ PlanetThoughtful wrote:
If I want to make a link to a URL which includes some GETs can I just
do:
a href='{$_SERVER['PHP_SELF']}?p={$p}c={$s}' ... etc etc
or must I escape the ampersand somehow?
Depends very much on the document type of your page. Valid
Rory Browne wrote:
On 6/4/05, Jack Jackson [EMAIL PROTECTED] wrote:
Hi, Rory
Rory Browne wrote:
I think you have the idea. The 's are used to seperate the various
variables. If you want to set $p to something like 'Tom Jerry' then
personally I'd do something like:
?php
$p = Tom Jerry;
The simplest way to make sure everything work well regardless of what the
values are:
?
$url = somepage.php?var1=.urlencode($var1).var2=.urlencode($var2);
echo a href=\.htmlspecialchars($url).\;
?
htmlspecialchars() changes characters '', '', ''', '', '' into the HTML
equivilant. And yup, you
12 matches
Mail list logo