Niet Ingelogd // Nieuwe vraag

Gestart doorWouter12 reacties5 weergaven

13 berichten · pagina 1 van 1

Wouter

Lid · Topicstarter

Berichten
3.540
Reputatie
0
Punten
0,01
Lid sinds
Laatst gezien
Hoe ik ook probeer, nu ik mijn script in een nieuwe layout gezet heb, hij logt niet meer in.
Session_start(); en ob_start(); al allemaal geprobeerd, niets werkt ...

[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"settings.php"[/COLOR][COLOR= #007700]);[/COLOR] ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"$sitenaam"[/COLOR][COLOR= #007700]);[/COLOR] ?></title>
[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"meta.php"[/COLOR][COLOR= #007700]);[/COLOR] ?>
<script language="javascript" type="text/javascript">
function clearText(field){

    if (field.defaultValue == field.value) field.value = ;
    else if (field.value == ) field.value = field.defaultValue;

}
</script>
</head>
<body>
<div id="templatemo_header_wrapper">
<!--  Free Web Templates by TemplateMo.com  -->
  <div id="templatemo_header">
    
       <div id="site_logo"></div>
        
        <div id="templatemo_menu">
              <div id="templatemo_menu_left"></div>
[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"menuboven.php"[/COLOR][COLOR= #007700]);[/COLOR] ?>     
        </div> <!-- end of menu -->
    
    </div>  <!-- end of header -->
</div> <!-- end of header wrapper -->

<div id="templatemo_content_wrapper">
    <div id="templatemo_content">
    
        <div id="column_w530">
            
            <div class="header_02">Maak je eigen klikspel</div>
            
            <p class="em_text">Hier kun je je aamelden om snel met je eigen klikspel te beginnen.<br />
          Binnen een paar minuten staat je klikspel al online!<br />
          </p>[COLOR= #0000BB]<?[/COLOR]
        [URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SERVER[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]REQUEST_METHOD[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]"POST"[/COLOR][COLOR= #007700]){[/COLOR]

[COLOR= #0000BB]$user[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]user[/COLOR][COLOR= #007700]];[/COLOR]
[COLOR= #0000BB]$pass[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]pass[/COLOR][COLOR= #007700]];[/COLOR]

[COLOR= #0000BB]$result2[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"SELECT * FROM users WHERE username = $user"[/COLOR][COLOR= #007700]);[/COLOR]
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/mysql_num_rows"]mysql_num_rows[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$result2[/COLOR][COLOR= #007700]) !==[/COLOR] [COLOR= #0000BB]1[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"Incorrecte login!"[/COLOR][COLOR= #007700];[/COLOR]
?>
<meta http-equiv="refresh" content="1;URL=inloggen.php" />
[COLOR= #0000BB]<?[/COLOR]
[URL="http://www.php.net/exit"]exit[/URL][COLOR= #007700];
}[/COLOR]

[COLOR= #0000BB]$query[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"SELECT * FROM users WHERE username = $user AND pass = $pass"[/COLOR][COLOR= #007700]);[/COLOR]
[COLOR= #0000BB]$result[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_num_rows"]mysql_num_rows[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$query[/COLOR][COLOR= #007700]);[/COLOR]

[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$result[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/while"]while[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$object[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_fetch_object"]mysql_fetch_object[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$query[/COLOR][COLOR= #007700])){[/COLOR]
[COLOR= #0000BB]$memberid[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$object[/COLOR][COLOR= #007700]->[/COLOR]id[COLOR= #007700];
}}[/COLOR]

[COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]memberid[/COLOR][COLOR= #007700]] =[/COLOR] [COLOR= #0000BB]$memberid[/COLOR][COLOR= #007700];[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"<meta http-equiv="refresh" content="0;URL=dealer_statistieken.php">"[/COLOR][COLOR= #007700];[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"<br><br>Inloggen..."[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/else"]else[/URL][COLOR= #007700]{[/COLOR]
?>
        <form name="form1" id="form1" method="post" action="">
          <p><img src="http://www.famfamfam.com/lab/icons/silk/icons/user.png"> Gebruikersnaam:<br />
            <input name="user" type="text" id="user" />
            <br />
            <img src="http://www.famfamfam.com/lab/icons/silk/icons/key.png"> Wachtwoord:<br />
            <input name="pass" type="password" id="pass" />
            <br />
            <img src="http://www.famfamfam.com/lab/icons/silk/icons/accept.png"> <input type="submit" name="Submit" value="Doorgaan &gt;&gt;" />
          </p>
        </form>
        [COLOR= #0000BB]<?[/COLOR]
        [COLOR= #007700]}[/COLOR]
        ?>
    </p>
            
            
            <div class="cleaner"></div>
        </div>
        
[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"menurechts.php"[/COLOR][COLOR= #007700]);[/COLOR] ?>
            
            <div class="cleaner"></div>
        </div>
    
        <div class="cleaner"></div>
    </div> <!-- end of content wrapper -->
</div> <!-- end of content wrapper -->

<div id="templatemo_footer_wrapper">

[COLOR= #0000BB]<?[/COLOR] [URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"menuonder.php"[/COLOR][COLOR= #007700]);[/COLOR] ?>
        
        <div class="margin_bottom_20"></div>
        [COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"$copy"[/COLOR][COLOR= #007700]);[/COLOR] ?>
    <div class="cleaner"></div>
    </div> <!-- end of footer -->
    <!--  Free CSS Templates by TemplateMo.com  -->
</div> <!-- end of footer -->
</body>
</html>


~Wouter


MOEST IN WEBSITEHULP ...
IM SORRY
0
Berichten
5.209
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Schopje naar Webwereld.
0
Berichten
20.364
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Welke error geeft hij aan?
0
Wouter

Lid · Topicstarter

Berichten
3.540
Reputatie
0
Punten
0,01
Lid sinds
Laatst gezien
Shahiem schreef:
Welke error geeft hij aan?
dat is het hem nu juist, hij geeft geen error, maar is gewoon niet ingelogged!
0
Berichten
20.364
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Als je inglogt hé, Wat doet hij dan?
En wat heb je voor het laatst veranderd?
0
Berichten
6.201
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Wat dacht je van session_start(); boven aan je script zetten? biggrinOw, dat heb je.. emo zeg je, maar ik zie het niet?
0
Berichten
8.602
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
en dit?

[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"settings.php"[/COLOR][COLOR= #007700]);[/COLOR] ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"$sitenaam"[/COLOR][COLOR= #007700]);[/COLOR] ?></title>
[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"meta.php"[/COLOR][COLOR= #007700]);[/COLOR] ?>
<script language="javascript" type="text/javascript">
function clearText(field){

    if (field.defaultValue == field.value) field.value = ;
    else if (field.value == ) field.value = field.defaultValue;

}
</script>
</head>
<body>
<div id="templatemo_header_wrapper">
<!--  Free Web Templates by TemplateMo.com  -->
  <div id="templatemo_header">
    
       <div id="site_logo"></div>
        
        <div id="templatemo_menu">
              <div id="templatemo_menu_left"></div>
[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"menuboven.php"[/COLOR][COLOR= #007700]);[/COLOR] ?>     
        </div> <!-- end of menu -->
    
    </div>  <!-- end of header -->
</div> <!-- end of header wrapper -->

<div id="templatemo_content_wrapper">
    <div id="templatemo_content">
    
        <div id="column_w530">
            
            <div class="header_02">Maak je eigen klikspel</div>
            
            <p class="em_text">Hier kun je je aamelden om snel met je eigen klikspel te beginnen.<br />
          Binnen een paar minuten staat je klikspel al online!<br />
          </p>[COLOR= #0000BB]<?[/COLOR]
        [URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SERVER[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]REQUEST_METHOD[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]"POST"[/COLOR][COLOR= #007700]){[/COLOR]

[COLOR= #0000BB]$user[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]user[/COLOR][COLOR= #007700]];[/COLOR]
[COLOR= #0000BB]$pass[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]pass[/COLOR][COLOR= #007700]];[/COLOR]

[COLOR= #0000BB]$result2[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"SELECT * FROM users WHERE username = "[/COLOR] [COLOR= #007700].[/COLOR] [COLOR= #0000BB]$user[/COLOR] [COLOR= #007700].[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]);[/COLOR]
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/mysql_num_rows"]mysql_num_rows[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$result2[/COLOR][COLOR= #007700]) !==[/COLOR] [COLOR= #0000BB]1[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"Incorrecte login!"[/COLOR][COLOR= #007700];[/COLOR]
?>
<meta http-equiv="refresh" content="1;URL=inloggen.php" />
[COLOR= #0000BB]<?[/COLOR]
[URL="http://www.php.net/exit"]exit[/URL][COLOR= #007700];
}[/COLOR]

[COLOR= #0000BB]$query[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"SELECT * FROM users WHERE username = "[/COLOR] [COLOR= #007700].[/COLOR] [COLOR= #0000BB]$user[/COLOR] [COLOR= #007700].[/COLOR] [COLOR= #DD0000]" AND pass = "[/COLOR] [COLOR= #007700].[/COLOR] [COLOR= #0000BB]$pass[/COLOR] [COLOR= #007700].[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700]);[/COLOR]
[COLOR= #0000BB]$result[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_num_rows"]mysql_num_rows[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$query[/COLOR][COLOR= #007700]);[/COLOR]

[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$result[/COLOR][COLOR= #007700]){[/COLOR]
[URL="http://www.php.net/while"]while[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$object[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_fetch_object"]mysql_fetch_object[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$query[/COLOR][COLOR= #007700])){[/COLOR]
[COLOR= #0000BB]$memberid[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$object[/COLOR][COLOR= #007700]->[/COLOR]id[COLOR= #007700];
}}[/COLOR]

[COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]memberid[/COLOR][COLOR= #007700]] =[/COLOR] [COLOR= #0000BB]$memberid[/COLOR][COLOR= #007700];[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"<meta http-equiv="refresh" content="0;URL=dealer_statistieken.php">"[/COLOR][COLOR= #007700];[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL][COLOR= #DD0000]"<br><br>Inloggen..."[/COLOR][COLOR= #007700];
}[/COLOR][URL="http://www.php.net/else"]else[/URL][COLOR= #007700]{[/COLOR]
?>
        <form name="form1" id="form1" method="post" action="">
          <p><img src="http://www.famfamfam.com/lab/icons/silk/icons/user.png"> Gebruikersnaam:<br />
            <input name="user" type="text" id="user" />
            <br />
            <img src="http://www.famfamfam.com/lab/icons/silk/icons/key.png"> Wachtwoord:<br />
            <input name="pass" type="password" id="pass" />
            <br />
            <img src="http://www.famfamfam.com/lab/icons/silk/icons/accept.png"> <input type="submit" name="Submit" value="Doorgaan &gt;&gt;" />
          </p>
        </form>
        [COLOR= #0000BB]<?[/COLOR]
        [COLOR= #007700]}[/COLOR]
        ?>
    </p>
            
            
            <div class="cleaner"></div>
        </div>
        
[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"menurechts.php"[/COLOR][COLOR= #007700]);[/COLOR] ?>
            
            <div class="cleaner"></div>
        </div>
    
        <div class="cleaner"></div>
    </div> <!-- end of content wrapper -->
</div> <!-- end of content wrapper -->

<div id="templatemo_footer_wrapper">

[COLOR= #0000BB]<?[/COLOR] [URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"menuonder.php"[/COLOR][COLOR= #007700]);[/COLOR] ?>
        
        <div class="margin_bottom_20"></div>
        [COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"$copy"[/COLOR][COLOR= #007700]);[/COLOR] ?>
    <div class="cleaner"></div>
    </div> <!-- end of footer -->
    <!--  Free CSS Templates by TemplateMo.com  -->
</div> <!-- end of footer -->
</body>
</html>
0
Berichten
20.364
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Waarom gebruik je eerst shorttags en daarna niet meer emo
0
Wouter

Lid · Topicstarter

Berichten
3.540
Reputatie
0
Punten
0,01
Lid sinds
Laatst gezien
Het script van Milan werkt.
Alleen heb ik nog altijd bovenaan elke pagina headers already sent, maar als ik in settings session_start(); weghaal, logt hij niet meer in confused
Wouter
0
Berichten
8.602
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Staat het helemaal bovenin in de settings? dus meteen naar de eerste php tag met niks ervoor?
0
Berichten
20.364
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Doe is ob_start(); er onder?
0
Wouter

Lid · Topicstarter

Berichten
3.540
Reputatie
0
Punten
0,01
Lid sinds
Laatst gezien
Nog een probleempje smilevoor mijn uitloggen.php had ik iets van
session_start();
session_destroy();
en nog iets

maar nu krijg ik alleen header te zien
http://www.klikspel.eu
0
Rik

Lid

Berichten
18.393
Reputatie
0
Punten
0,04
Lid sinds
Laatst gezien
Laat settings.php eens zien? smile
0

Jouw reactie

Deel je idee, stel een vraag of help een ander verder.

Editor laden…

Praat mee met de One2xs-community.

Inloggen om te reageren