From 5e568f1fe8da343df1ffa3a118b88c8cf9df071d Mon Sep 17 00:00:00 2001 From: x2000habouzit Date: Tue, 31 Aug 2004 21:43:47 +0000 Subject: [PATCH] last echoes --- include/cyberpaiement.inc.php | 100 ----------------------------------- include/geoloc.inc.php | 20 ++++--- plugins/function.select_db_table.php | 4 +- 3 files changed, 14 insertions(+), 110 deletions(-) delete mode 100644 include/cyberpaiement.inc.php diff --git a/include/cyberpaiement.inc.php b/include/cyberpaiement.inc.php deleted file mode 100644 index 062be1b..0000000 --- a/include/cyberpaiement.inc.php +++ /dev/null @@ -1,100 +0,0 @@ -hasflag('unique')) ? str_pad("",15,"0") : rand_url_id(); -$fullref = substr("$prefix-xorg-$ref",-15); - -// on recupere les infos sur l'utilisateur -$res = $globals->db->query("select username, nom, prenom from auth_user_md5 where user_id={$_SESSION['uid']}"); -list($username,$nom,$prenom) = mysql_fetch_row($res); -mysql_free_result($res); -?> - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Paiement via CyberP@iement
Transaction
Montant (euros)
  -
-
- -

-En cliquant sur "Valider", tu seras -redirigé vers le site de la -BP Lorraine Champagne, où il te sera demandé de saisir ton numéro de -carte bancaire. Lorsque le paiement aura été effectué, tu recevras -une confirmation par email. -

- diff --git a/include/geoloc.inc.php b/include/geoloc.inc.php index 032b841..f000bab 100644 --- a/include/geoloc.inc.php +++ b/include/geoloc.inc.php @@ -18,49 +18,53 @@ * Foundation, Inc., * * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * *************************************************************************** - $Id: geoloc.inc.php,v 1.5 2004-08-31 16:04:11 x2000habouzit Exp $ + $Id: geoloc.inc.php,v 1.6 2004-08-31 21:43:47 x2000habouzit Exp $ ***************************************************************************/ /** donne la liste déroulante des pays * @param $current pays actuellement selectionné - * @return echo */ function geoloc_pays($current) { global $globals; $sql = "SELECT a2,pays FROM geoloc_pays ORDER BY pays"; $result = $globals->db->query($sql); + $html = ""; while (list($my_id,$my_pays) = mysql_fetch_row($result)) - printf("\n",$my_id,($current==$my_id?"selected='selected'":""),$my_pays); + $html .= sprintf("\n",$my_id,($current==$my_id?"selected='selected'":""),$my_pays); + + return $html; } + function _geoloc_pays_smarty($params){ if(!isset($params['pays'])) return; - geoloc_pays($params['pays']); + return geoloc_pays($params['pays']); } $page->register_function('geoloc_pays', '_geoloc_pays_smarty'); /** donne la liste deroulante des regions pour un pays * @param $pays le pays dont on veut afficher les regions * @param $current la region actuellement selectionnee - * @return echo */ function geoloc_region($pays,$current) { global $globals; $sql = "SELECT region,name FROM geoloc_region where a2='".$pays."' ORDER BY name"; $result = $globals->db->query($sql); - echo ""; + $html = ""; while (list($regid,$regname) = mysql_fetch_row($result)) - printf("\n",$regid,($current==$regid?"selected='selected'":""),$regname); + $html .= sprintf("\n",$regid,($current==$regid?"selected='selected'":""),$regname); + return $html; + } function _geoloc_region_smarty($params){ if(!isset($params['pays'])) return; if(!isset($params['region'])) return; - geoloc_region($params['pays'], $params['region']); + return geoloc_region($params['pays'], $params['region']); } $page->register_function('geoloc_region', '_geoloc_region_smarty'); diff --git a/plugins/function.select_db_table.php b/plugins/function.select_db_table.php index 7b30e55..7600166 100644 --- a/plugins/function.select_db_table.php +++ b/plugins/function.select_db_table.php @@ -18,7 +18,7 @@ * Foundation, Inc., * * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * *************************************************************************** - $Id: function.select_db_table.php,v 1.2 2004-08-31 11:19:51 x2000habouzit Exp $ + $Id: function.select_db_table.php,v 1.3 2004-08-31 21:43:47 x2000habouzit Exp $ ***************************************************************************/ @@ -34,7 +34,7 @@ function select_options($table,$valeur,$champ="text",$pad=false,$where="") { if ($pad) $html.= '\n"; while (list($my_id,$my_text) = mysql_fetch_row($result)) { - $html .= printf("\n",$my_id,($valeur==$my_id?$sel:""),$my_text); + $html .= sprintf("\n",$my_id,($valeur==$my_id?$sel:""),$my_text); } mysql_free_result($result); return $html; -- 2.1.4