Hallo Andi,
In einen Beitrag schriebst Du, das man die Funktion mxSessionGetVar($Variable) anstelle $_SESSIONS benutzen sollte.
Nun meine Frage, nur zur meiner Verständnis:
Ich habe jetzt die Sessons Abfrage vom Original:
if (!tep_session_is_registered('customer_id')) {
$navigation->set_snapshot();
tep_redirect(tep_href_link(FILENAME_LOGIN, '', 'SSL'));
}
Die dazugehörige wegfallende Funktion:
function tep_session_is_registered($variable) {
if (PHP_VERSION < 4.3) {
return session_is_registered($variable);
} else {
return isset($_SESSION) && array_key_exists($variable, $_SESSION);
}
}
in :
if (!mxSessionGetVar('user_uid')) {
$navigation->set_snapshot();
tep_redirect(tep_href_link(FILENAME_LOGIN, '', 'SSL'));
}
geändert.
Nur bekomme ich so noch nicht die benötigte uid aus der Session. Diese bekomme ich erst mit dem zusätzlichen Code:
$userdata = mxGetUserData();
$uid = $userdata['uid'];
Wenn ich jetzt die Sessionabfrage mit if (!mxSessionGetVar($user_uid)) einleite, bekomme ich arge Probleme mit der Session und das Shopmodul will auf die "cookie_usage.php" weiterleiten, das ist aber nicht der sinn der Sache.
"Notice: Undefined variable: cart in /srv/vhosts/pitbull/public_html/osc2pragmamx/modules/catalog/includes/application_top.php on line 279 Notice: Undefined variable: currency in /srv/vhosts/pitbull/public_html/osc2pragmamx/modules/catalog/includes/application_top.php on line 318 Notice: Undefined variable: navigation in /srv/vhosts/pitbull/public_html/osc2pragmamx/modules/catalog/includes/application_top.php on line 329 Notice: Use of undefined constant DIR_WS_LANGUAGES - assumed 'DIR_WS_LANGUAGES' in /srv/vhosts/pitbull/public_html/osc2pragmamx/modules/catalog/cookie_usage.php on line 15 Warning: require(DIR_WS_LANGUAGESgerman/cookie_usage.php): failed to open stream: No such file or directory in /srv/vhosts/pitbull/public_html/osc2pragmamx/modules/catalog/cookie_usage.php on line 15 Fatal error: require(): Failed opening required 'DIR_WS_LANGUAGESgerman/cookie_usage.php' (include_path='.:/usr/share/php5:/usr/share/php5/PEAR') in /srv/vhosts/pitbull/public_html/osc2pragmamx/modules/catalog/cookie_usage.php on line 15"
Kannst Du mir mal bitte ein Denkanstoß geben?
Die Notices
"Notice: Undefined variable: cart in /srv/vhosts/pitbull/public_html/osc2pragmamx/modules/catalog/includes/application_top.php on line 279 Notice: Undefined variable: currency in /srv/vhosts/pitbull/public_html/osc2pragmamx/modules/catalog/includes/application_top.php on line 318 Notice: Undefined variable: navigation in /srv/vhosts/pitbull/public_html/osc2pragmamx/modules/catalog/includes/application_top.php on line 329"
Ignoriere erstmal, die werde ich noch mit
if (isset($_GET['xxxxxx'])) {
$xxxxxx = intval($_GET['xxxxxx']);
}
if (empty($xxxxxx)) {
$xxxxxx = "";
}
Prüfen.
Ich könnte nun auch mit der MXISUSER Funktion arbeiten, wäre aber in diesen Fall nicht angebracht, da sonst wirklich
nur Registrierte Benutzer bestellen könnten. Für alles weitere im Kundenbereich (Registrierte Benutzer), da benutze ich selbstverständlich die MXISUSER Funktion.
Vielen Dank im vorraus.
"Edit: im ersten Codeschnipsel die dazugehörige Funktion hinzugefügt"