La ligne suivante ne fonctionne pas car c'est du "pur" HTML (la variable PHP n'est pas 
interpr�t�e)
<a href ="rep.php?variable=$change">Transmission variable</a>

Il faut donc ins�rer du code PHP pour afficher (g�n�rer) le contenu de ta variable en 
HTML
<a href ="rep.php?variable=<? echo $change; ?>">Transmission variable</a>

Bien � toi,
Alec

-----Original Message-----
From: Alain Barth�lemy [mailto:[EMAIL PROTECTED]]
Sent: Monday, January 13, 2003 5:34 PM
To: Liste Linux
Subject: [linux] php transmission param�tres via URL?


Bonjour,

Question PHP

Je sais d�j� que pour faire un transfert de variables via un URL, il faut
utiliser:

<a href ="rep.php?variable=string">Cliquez ici</a>

variable devient $variable � la r�ception
et string est "un_string"

Je ne trouve cependant aucun RTFM ou manuel ou HowTo pour
m'�clairer sur les diff�rentes fa�ons (s'il y en a?) de transmettre des
variables ou des param�tres de cette fa�on.

Par exemple:

1) comment transmettre une variable (pas un string)
Je cr�e donc la variable $change que je d�finis avec $change =
"un_string" et je voudrais transmettre cette variable � la page Web
rep.php.

<a href ="rep.php?variable=$change">Transmission variable</a>
ne fonctionne pas naturellement

2) sur unixtech.be, je peux lire:

<a href="banners.php?opt=click&amp;bid=42" >
ou
<a href="user.php?op=userinfo&amp;uname=alain>

Ces lignes sont interpr�t�es. Il semble que c'est ainsi qu'une variable
est transmise (alain dans uname=alain doit �tre une interpr�tation de
uname=$votre_nom).
Quel est le r�le de *&* (&amp;) dans user.php?op=userinfo&uname=alain  ?

Tout howto qui explique tout cela est le bienvenu.

J'esp�re avoir �t� assez clair.

Merci

-- 
Alain Barth�lemy
[EMAIL PROTECTED]
http://bartydeux.be
_______________________________________________________
Linux Mailing List - http://www.unixtech.be
Subscribe/Unsubscribe: http://www.unixtech.be/mailman/listinfo/linux
Archives: http://www.mail-archive.com/[email protected]
IRC: efnet.unixtech.be:6667 - #unixtech


Notice: 
This e-mail and any attachments thereto may contain information, which is confidential 
and/or protected by intellectual property rights, and are intended for the sole use of 
the recipient(s) named above. Any use of the information contained herein (including, 
but not limited to, total or partial reproduction, communication or distribution in 
any form) by persons other than the designated recipient(s) is prohibited. If you have 
received this e-mail in error, please notify the sender either by telephone or by 
e-mail and delete the material from any computer. Although we attempt to sweep e-mail 
and attachments for viruses, it does not guarantee that either is virus-free and we 
accept no liability for any damage sustained as a result of viruses.
Thank you for your co-operation.

_______________________________________________________
Linux Mailing List - http://www.unixtech.be
Subscribe/Unsubscribe: http://www.unixtech.be/mailman/listinfo/linux
Archives: http://www.mail-archive.com/[email protected]
IRC: efnet.unixtech.be:6667 - #unixtech

Répondre à