Jump to content

White empty page


Leverkusen

Recommended Posts

When i post, get white page fo no reason, what could be the problem?

<?php
// upis para
if($_POST['tim1']!="" and $_POST['tim2']!="" and $_POST['tip']!="" and $_POST['kvota']!="" and $_POST['link']!=""){
    $racun=$_SESSION['liga_user_id'];
    $result = mysql_query("select * from clanovi_njihovi_racuni where id='$racun';");
    $row = mysql_fetch_array($result);
    $klikovi = $row['klikovi'];
    
    $tim1=str_ireplace(array("\"","'","<",">"),"",$_POST['tim1']);
    $tim2=str_ireplace(array("\"","'","<",">"),"",$_POST['tim2']);
    $tip=str_ireplace(array("\"","'","<",">"),"",$_POST['tip']);
    
    $kvota=str_ireplace(array(","),".",$_POST['kvota']);
    $link=$_POST['link'];
    $ip=$_SERVER['REMOTE_ADDR'];
    
    $tim1=strtolower($tim1);$tim1=ucwords($tim1);
    $tim2=strtolower($tim2);$tim2=ucwords($tim2);
    
    $link=str_ireplace(" ","",$link);
    $prvoslovo=str_ireplace("http://www.flashscore.com/","#",$link);
    $linkDozvola=0;
        $broj_po_danu = 9;
        $datum=curdate();
$select = mysql_query("SELECT racun FROM clanovi_njihovi_racuni WHERE datum_unosa='$datum'");

if(mysql_num_rows($select) == $broj_po_danu){
echo 'Postignut maksimalni broj parova u danu';
} else {
    if($prvoslovo[0]=="#")$linkDozvola=1; 
    if($linkDozvola==1 and $kvota>1 and $kvota<100){
        $result = mysql_query("insert into clanovi_njihovi_parovi set racun='$racun',ip='$ip',datum=curdate(),vrijeme=curtime(),tim1='$tim1',tim2='$tim2', tip='$tip', kvota='$kvota',link='$link';");
    }
    else if($linkDozvola==0)echo "<script>alert('Vas link je neispravan. Link utakmice kopirajte sa www.flashscore.com .')</script>";
    else if($kvota<1.01 and $kvota>99.99)echo "<script>alert('Kvota vam nije u opsegu od 1.01 do 99.99 .')</script>";
}
}
?>
Link to comment
https://forums.phpfreaks.com/topic/287180-white-empty-page/
Share on other sites

<?php
// upis para
if($_POST['tim1']!="" and $_POST['tim2']!="" and $_POST['tip']!="" and $_POST['kvota']!="" and $_POST['link']!=""){
    $racun=$_SESSION['liga_user_id'];
    $result = mysql_query("select * from clanovi_njihovi_racuni where id='$racun';");
    $row = mysql_fetch_array($result);
    $klikovi = $row['klikovi'];
    
    $tim1=str_ireplace(array("\"","'","<",">"),"",$_POST['tim1']);
    $tim2=str_ireplace(array("\"","'","<",">"),"",$_POST['tim2']);
    $tip=str_ireplace(array("\"","'","<",">"),"",$_POST['tip']);
    
    $kvota=str_ireplace(array(","),".",$_POST['kvota']);
    $link=$_POST['link'];
    $ip=$_SERVER['REMOTE_ADDR'];
    
    $tim1=strtolower($tim1);$tim1=ucwords($tim1);
    $tim2=strtolower($tim2);$tim2=ucwords($tim2);
    
    $link=str_ireplace(" ","",$link);
    $prvoslovo=str_ireplace("http://www.flashscore.com/","#",$link);
    $linkDozvola=0;
    $broj_po_danu=1;

$select = mysql_query("SELECT racun FROM clanovi_njihovi_parovi WHERE datum=CURDATE()");
if(mysql_num_rows($select) == $broj_po_danu){
echo 'Postignut maksimalni broj parova u danu';
} else {
    if($prvoslovo[0]=="#")$linkDozvola=1; 
    if($linkDozvola==1 and $kvota>1 and $kvota<100){
        $result = mysql_query("insert into clanovi_njihovi_parovi set racun='$racun',ip='$ip',datum=curdate(),vrijeme=curtime(),tim1='$tim1',tim2='$tim2', tip='$tip', kvota='$kvota',link='$link';");
    }
    else if($linkDozvola==0)echo "<script>alert('Vas link je neispravan. Link utakmice kopirajte sa www.flashscore.com .')</script>";
    else if($kvota<1.01 and $kvota>99.99)echo "<script>alert('Kvota vam nije u opsegu od 1.01 do 99.99 .')</script>";
}
}
?>

I dont get any error, but this is not working, i can still post

Link to comment
https://forums.phpfreaks.com/topic/287180-white-empty-page/#findComment-1473618
Share on other sites

1 - turn on php error checking and let us see the lines in this code.

2 - whenever you do a function call that MUST be run correctly, you should CHECK the result of it to ensure that it ran.  Modify ALL of your present code to check results and echo error messages where appropriate.

 

Do those two things and you and we will learn what your problem is.

Link to comment
https://forums.phpfreaks.com/topic/287180-white-empty-page/#findComment-1473645
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.