Danke schön vt1816! :)
Die übertragung der Variable funktioniert einwandfrei :) nur hab ich jetzt das Problem, dass ich den Syntaktischen Ausdruck nicht korrekt wiederspiegeln kann.
Der JS-Code um DiaShow zu erreichen sah so aus.
Code:
this.b_insert= function(){
var b, thestylid, thez, thevis, slidehei;
slidehei=(showcontr)?(pichei+25):(pichei); //add space for the controls
var myhtml="<div style='width:"+picwid+"px;height:"+slidehei+"px;'>";
myhtml+="<div style='position:absolute;width:"+picwid+"px;height:"+pichei+"px;'>";
for(b=1;b<=emax;b++){
thez=1;thevis='hidden';
if(b<=1) {thez=2; thevis='visible';}
myhtml+="<div id='img_"+slideid+"_"+b+"' style='font-size:0;height:"+pichei+"px;width:"+picwid+"margin:0;padding:0;text-align:center;visibility:"+thevis+";z-index:"+thez+";position:absolute;left:0;top:0;width:"+picwid+"px;height:"+pichei+"px;background-color:"+backgr+";'>";
myhtml+="<img src='"+imges[(b-1)]+"' style='vertical-align:middle;border:0;height:600px;width:1000px' alt=''/></div>";
}
myhtml+="</div>";
Und es wird in HTML dann so ausgegeben:
<div style="font-size: 0px; padding: 0px; text-align: center; visibility: hidden; z-index: 1; position: absolute; left: 0px; top: 0px; width: 800px; height: 600px; opacity: 0;" id="img_0_1"><img alt="" style="vertical-align:middle;border:0;height:600px;width:1000px" src="Freitag/Folie2.jpg"></div>
Leider, wird es bei mir in PHP mit dieser Codierung:
PHP-Code:
echo ' this.b_insert= function(){
var b, thestylid, thez, thevis, slidehei;
slidehei=(showcontr)?(pichei+25):(pichei); //add space for the controls
var myhtml=\'<div style="width:"+picwid+ "px;height:" +slidehei+"px;" >\';
myhtml+=\'<div style="position:absolute;width:"+picwid+"px;height:"+pichei+"px;">\';
for(b=1;b<=emax;b++){
thez=1;thevis=\'hidden\';
if(b<=1) {thez=2; thevis=\'visible\';}
myhtml+=\'<div id=\'img_\'+slideid+\'_\'+b+" \' style="font-size:0;height:"+pichei+"px;width:"+picwid+"margin:0;padding:0;text-align:center;visibility:"+thevis+";z-index:"+thez+";position:absolute;left:0;top:0;width:"+picwid+"px;height:"+pichei+"px;background-color:"+backgr+";\'>\';
myhtml+=\'<img src=\' "+imges[(b-1)]+\'" style="vertical-align:middle;border:0;height:600px;width:1000px" alt=""/></div>\';
} myhtml+=\'</div>\'; ';
So Ausgegeben:
<div +pichei+"px;width:"+picwid+"margin:0;padding:0;text-align:center;visibility:"+thevis+";z-index:"+thez+";position:absolute;left:0;top:0;width:"+picwid+"px;heigh t:"+pichei+"px;background-color:"+backgr+";'="" style="font-size:0;height:" '="" slideid'_'+b+"="" id="img_">';
myhtml+='<img alt="" style="vertical-align:middle;border:0;height:600px;width:1000px" "="" src=" "+imges[(b-1)]+"></div>
Ich hab es mit verschieden Lösungsansätzen ausprobiert, jedoch hat dies nicht zum erfolg geführt.
Gruß Rewa