Gegen Bilderklau - Das Original (https://www.gegen-bilderklau.net/index.php)
- Design, Website, Copyright (https://www.gegen-bilderklau.net/board.php?boardid=80)
--- Homepagehilfe (https://www.gegen-bilderklau.net/board.php?boardid=27)
---- Homepagehilfe - Archiv (https://www.gegen-bilderklau.net/board.php?boardid=139)
----- [PHP & MySQL] Problem mit logincode (PHP und MySQL) (https://www.gegen-bilderklau.net/thread.php?threadid=152508)


Geschrieben von sarah99 am 23.03.2009 um 16:33:

  Problem mit logincode (PHP und MySQL)

Hallo!
Mein Problem ist das wenn ich das login Formular aufrufe folgende fehlermeldung kommt, und ich nicht weiß wo der Fehler liegt:
Warning: include(functions.inc.php) [function.include]: failed to open stream: No such file or directory in /usr/export/www/vhosts/funnetwork/hosting/nevader/PHP/login.php on line 8

Warning: include() [function.include]: Failed opening 'functions.inc.php' for inclusion (include_path='.:') in /usr/export/www/vhosts/funnetwork/hosting/nevader/PHP/login.php on line 8


Außerdem kommt wenn man sich einloggt diese Fehlermeldung:
Warning: include(functions.inc.php) [function.include]: failed to open stream: No such file or directory in /usr/export/www/vhosts/funnetwork/hosting/nevader/PHP/login.php on line 8

Warning: include() [function.include]: Failed opening 'functions.inc.php' for inclusion (include_path='.:') in /usr/export/www/vhosts/funnetwork/hosting/nevader/PHP/login.php on line 8

Fatal error: Call to undefined function exist() in /usr/export/www/vhosts/funnetwork/hosting/nevader/PHP/login.php on line 10


So und des is der login.php code:
php:
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
41:
42:
43:
44:
45:
46:
47:
48:
49:
50:
51:
52:
53:
54:
55:
56:
57:
58:
59:
60:
61:
62:
63:
64:
<html>
<head>
</head>
<body style="text-align: center">
<?php
session_start(); 
include("db.php");
include("functions.inc.php");
if(isset($_REQUEST["submit"])) { 
if(exist("mitglieder WHERE name = '".strip_tags($_REQUEST["name"])."' AND passwort = '".md5($_REQUEST["passwort"])."'") && anzahl("login WHERE ip = 
'".getenv("REMOTE_ADDR")."' AND erfolgreich = 'nein' AND timestamp > '".(time()-60*30)."'") < 4) { 
$eintragen mysql_query("INSERT INTO login 
(name, ip, timestamp, erfolgreich) VALUES ('".strip_tags($_REQUEST["name"])."', '".getenv("REMOTE_ADDR")."', '".time()."', 'ja')"); 

$abfrage "SELECT id FROM mitglieder WHERE name = '".strip_tags($_REQUEST["name"])."' LIMIT 0,1";
$ergebnis mysql_query($abfrage);
while($row mysql_fetch_object($ergebnis))
{
$_SESSION["login"] = $row->id; 
}
echo "<meta http-equiv="refresh" content="0URL=mitgliederbereich.php">"; 
} else { 
$eintragen mysql_query("INSERT INTO login (name, ip, timestamp, erfolgreich) 
VALUES ('".strip_tags($_REQUEST["name"])."', '".getenv("REMOTE_ADDR")."', '".time()."', 'nein')"); // Eintrag in Login!
?>
Login schlug fehl.
<?php
}
} else { }
?>
<form action=login.php method=post>
<table width=90%>
<tr>
<td width="47%" align="right">
<b>Name:</b>
</td>
<td width="2%">
 </td>
<td width=50%>
<input type="text" name="name">
</td>
</tr>
<tr>
<td width="47%" align="right">
<b>Passwort:</b>
</td>
<td width="2%">
 </td>
<td width=50%>
<input type="password" name="passwort">
</td>
</tr>
<tr>
<td width=100% colspan=3>
<p align="center">
<input type="submit" value="Login" name="submit">
</td>
</tr>
</table>
</form>

</body>
</html>


Ich hoffe jemand kann mir helfen.
Und schon mal danke im vorraus.
LG sarah99



Geschrieben von victor am 24.03.2009 um 00:50:

 

Du bindest in Zeile 8 die Datei functions.inc.php - und die ist offenbar nicht da. Das zieht dann nen langen Schwanz an Fehlern hinter sich her, weil du die ja in Zeile 8 nicht umsonst einbinden willst ^^



Geschrieben von Baronesse am 24.03.2009 um 01:20:

 

Und vor Session_start() darf nichts anderes stehen Augenzwinkern
Das muss gleich in die erste Zeile.



Geschrieben von sarah99 am 24.03.2009 um 15:50:

 

Danke für die Hilfe!
Jetzt funktionierts.
Jeden einen Keks geb.



Geschrieben von victor am 25.03.2009 um 22:16:

 

Danke schön *keks mampf* fröhlich


Forensoftware: Burning Board, entwickelt von WoltLab GmbH