Hallo,
ich bin gerade dabei in meine Seite PHPSessionID zu integrieren.
Leider musste ich feststellen, das nach einfügen des Befehls
session_start(); meine Javascript-Funktion nicht mehr anspringen.
Es ist das erste mal das ich mit SessionIDs arbeite. Woran könnte es liegen das meine JavaScript-Funktionen nicht mehr ausgeführt werden?
Ich würde zwar den ganzen Quelltext posten, aber der ist mit fast 700 Zeilen ein wenig lang.
Ich habe leider nach längeren Recherchen im Internet keine Antwort auf mein Problem finden können.
Hier schon mal der Anfang des Quelltext:
Wenn ihr mehr benötigt, dann werde ich den Rest auch noch posten, aber vieleicht reicht das schon.
<?php
session_start();
echo '
<html>
<head>';
include('../menu/menu.php');
?>
<script type="text/javascript">
function email_link(name, domain, tld)
{
var link = "<a href='mailto:"+name+"@"+domain+"."+tld+"'>"+name+"@"+domain+"."+tld+"</a>";
document.write(link);
}
function email_form(name, domain, tld)
{
var form = "<form name='Formular' action='mailto:"+name+"@"+domain+"."+tld+"' enctype='Text/Plain' method='POST' onsubmit='return check_form()'>";
document.write(form);
}
function check_form_auswahl()
{
if (document.form_auswahl.hersteller_select.value == "" && document.form_auswahl.gruppe1_select.value == "" && document.form_auswahl.gruppe2_select.value == "" && document.form_auswahl.gruppe3_select.value == "")
{
alert("Bitte min. eine Kategorie auswählen!");
document.form_auswahl.hersteller_select.focus();
return false;
}
}
function check()
{
//echo "<select name=gruppe1_select onchange=window.location.href="${_SERVER['SCRIPT_NAME']}"."?gruppe1_select="+this.value+"&gruppe2_select="+document.form_auswahl.gruppe2_select.value>";
window.location.href="shop.php?hersteller_select="+document.form_auswahl.hersteller_select.value
+"&gruppe1_select="+document.form_auswahl.gruppe1_select.value
+"&gruppe2_select="+document.form_auswahl.gruppe2_select.value
+"&gruppe3_select="+document.form_auswahl.gruppe3_select.value;
}
function switchlayer(Layer_Name)
{
var GECKO = document.getElementById? 1:0 ;
var NS = document.layers? 1:0 ;
var IE = document.all? 1:0 ;
if (GECKO)
{document.getElementById(Layer_Name).style.display=
(document.getElementById(Layer_Name).style.display=='block') ? 'none' : 'block';}
else if (NS)
{document.layers[Layer_Name].display=(document.layers[Layer_Name].display==
'block') ? 'none' : 'block';}
else if (IE)
{document.all[Layer_Name].style.display=(document.all[Layer_Name].style.display==
'block') ? 'none' : 'block';}
}
</script>
<table cellspacing="0" cellpadding="0" border="0" width="100%" >
<tr>
<td valign="top" >
<table cellspacing="0" cellpadding="0" border="0" width="100%">
<tr>
<td valign="top" class="label" width="100%">Shop</td>
</tr>
<tr>
<td class="inhalt" valign="top" width="100%" >
<?php
...