Kod
Undefined index: check in
<div id="content"> <div class="postui2 text-title"> <h2> Cennik </h2> </div> <div class="postui2 text-con"> <div class="con-wrap"> <div id="fuibar"> <div class="fuibarui fui-title"> <p>Cennik</p> </div> <div class="fuibarui fui-con"> <div class="fui-wrap"> <table width="168" border="0" align="center"> <tr> <td width="84" class="topLine">10 PLN -></td> <td width="74" class="tdunkel"> 100 Monet</td> </tr> <tr> <td class="topLine">25 PLN -></td> <td class="tdunkel">250 Monet</td> </tr> <tr> <td class="topLine">50 PLN -></td> <td class="tdunkel">550 Monet</td> </tr> </table> </div> </div> <div class="fuibarui fui-end"> </div></div> <div id="fuibar"> <div class="fuibarui fui-title"> <p>Doładowanie Monet</p> </div> <div class="fuibarui fui-con"> <div class="fui-wrap"> <?PHP if(isset($_SESSION['user_admin']) && checkInt($_SESSION['user_admin']) && $_SESSION['user_admin']>=0) { $maxStunde = 10; ); $id = 10; # numer ID zarejestrowanego klienta $code = "abcd"; # identyfikator usług SMS $type = "sms"; # typ konta: C1 - 8 znakowy kod bezobsługowy # typ konta: sms dla sprawdzania SMSow #$page = "main.php"; # strona ktora ma sie otworzyc po podaniu poprawnego kodu # # gdy sprawdzane będą zarówno konta smsowe jak i konta przy płatnościach kartą # to należy wtedy użyć zapisu: # $type = "c1,sms"; # # # przy sprawdzaniu kilku kont o różnych identyfikatorach należy użyć zapisu: # $code = "abcd1,abcd2,kody2,kody6"; # $check = "xxxxxxxx"; # podany kod na stronie gdzie wejście jest płatne i wymagany jest zakupiony kod $check = $_POST['check']; # podany kod na stronie gdzie wejście jest płatne i wymagany jest zakupiony kod $del=0; # jezeli kod ma byc jednorazowy to ustaw wartosc na 1; ################################################################################
############################################# if($check == NULL) $array['check']= $check; $array['code'] = $code; $array['id'] = $id; $array['type'] = $type; $array['del'] = $del; $ch = curl_init (); curl_setopt ($ch, CURLOPT_URL, "https://ssl.dotpay.pl/check_code.php"); curl_setopt ($ch, CURLOPT_SSL_VERIFYPEER, FALSE); curl_setopt ($ch, CURLOPT_SSL_VERIFYHOST, 2); curl_setopt ($ch, CURLOPT_FOLLOWLOCATION, 1); curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt ($ch, CURLOPT_TIMEOUT, 100); curl_setopt ($ch, CURLOPT_POST, 1); curl_setopt ($ch, CURLOPT_POSTFIELDS, $array); $recv = curl_exec ($ch); curl_close ($ch); $status = $dane[0]; $czas_zycia = $dane[1]; else { # gdy kod poprawny: { } else { } //header("Location: ".$page); # włączenie strony głównej } ?> <FORM ACTION='' METHOD=POST> <table> <tr> <td>Kod SMS:</th> <td><INPUT class='input' TYPE=TEXT NAME='check' SIZE=10 MAXLENGTH=8> </td> </tr> <tr> <td class="tdunkel" colspan="2" style="text-align:center;"><input type="submit" name="getMonet" value="beantragen" class="btn"/> - <input type="reset" class="btn"/></td> </tr> </table> </form> <?PHP } else { } ?> </div> </div> <div class="fuibarui fui-end"> </div></div> </div> </div> <div class="postui2 text-end">