[English]
Paiement en ligne
include "include/configure.php"; include "include/dbconnect.php"; function pref1_pref2(){ global $connection; $prefs=array(); $sql = "SELECT id_prefix, prefix1, prefix2 FROM prefixes"; $req = mysql_query($sql) or die('Erreur SQL !
'.$sql.'
'.mysql_error()); while($prefix = mysql_fetch_assoc($req)){ $prefs[$prefix["id_prefix"]]=array(ereg_replace("^41","0",$prefix["prefix1"]),$prefix["prefix2"]); } mysql_close($connection); return $prefs; } ?>
Compte SIP -
---
$pref1_pref2=pref1_pref2(); $found=""; if(isset($_GET['ind'])){ list($part1,$part2,$part3)= split ("-", $_GET['ind'], 3); $part3=""; } elseif(isset($_GET['t'])) list($part1,$part2,$part3)= split ("-", $_GET['t'], 3); if (strlen($part3)!=4) $part3=""; foreach ($pref1_pref2 as $id_pref => $prefixes){ if ( $prefixes[0]==$part1 && $prefixes[1]==$part2 && $found=="" ){ $found=$id_pref; } } if ($found==""){ foreach ($pref1_pref2 as $id_pref => $prefixes){ if ($prefixes[0]==$part1){ $found=$id_pref; } } } foreach ($pref1_pref2 as $id_pref => $prefixes){ echo '
'.$prefixes[0].'-'.$prefixes[1].'
'."\n"; } ?>
*
Montant que vous souhaitez ajouter sur votre compte SIP : if (!isset($_GET['s'])) { $montant = '5'; } else { $montant = $_GET['s']; } ?>
(pour paiement en ligne min. 5 CHF)