Zum Inhalt springen
View in the app

A better way to browse. Learn more.

Fachinformatiker.de

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Empfohlene Antworten

Veröffentlicht

Moin,

meine PHP-Session funzt nicht, habe schon diverse Varianten probiert aber es klappt einfach nicht.

Die Login-Seite:

<?php

session_start();

$title="Kunden Login";

require'config.cfg.php';

require'libs/DB.inc.php';

if (isset($_POST['submit'])){

if(!$_POST['kundenid'] || $_POST['kundenid'] == "") {

$error="Bitte KundenID eingeben";

}

elseif(!$_POST['password'] || $_POST['password'] == "") {

$error="Bitte Passwort eingeben";

}

else{

$query = @mysql_query("SELECT Kunde_Id, Passwort FROM Kunde WHERE Kunde_Id = '".$_POST['kundenid']."'") or die('Select ist fehlgeschlagen!');

$result = @mysql_fetch_array($query) or $error="KundenID nicht vorhanden";

if ($result){

if($_POST['password'] != $result['Passwort']){

$error="Password ist falsch";

}

else{

// Cookie wird gesetzt und eine neue Seite aufgerufen

$_SESSION['userName'] = $_POST[kundenid];

// $user = $result['kundenid'];

// session_register('kundenid');

echo '<p align="center">LogIn erfolgreich! :-)<br><br><a href="sichere_seite.php">Weiter</a></p>';

// setcookie("sessionlogin", "$UserID", time()+500);

// echo"klappt";

// $user = $result['Kunden_Id'];

// session_register('user');

// echo '<p align="center">LogIn erfolgreich! <br><br><a href="kundenweb.php">Weiter</a></p>'; }

}

}

}

}

include'templates/seit1.tpl';

?>

Bekomme den Fehler (alleine wenn in Zeile 2 nur "session_start();" steht) :

Warning: session_start(): open(/tmp\sess_a6a12f332a75db5a42a588b070ee9cfb, O_RDWR) failed: No such file or directory (2) in G:\apache\htdocs\test\login.php on line 2

Warning: session_start(): Cannot send session cookie - headers already sent by (output started at G:\apache\htdocs\test\login.php:2) in G:\apache\htdocs\test\login.php on line 2

Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at G:\apache\htdocs\test\login.php:2) in G:\apache\htdocs\test\login.php on line 2

Aber auf dem (fernen) Server.... :rolleyes:

Muss dann ja eine Fehlkonfiguration bei meinem Provider sein.....

oder du hast händisch den session_dir verändert?

Erstelle ein Konto oder melde dich an, um einen Kommentar zu schreiben.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.