clauske Posted February 26, 2011 Share Posted February 26, 2011 elseif ( isset ($_GET['p']) && $_GET['p'] == "detail" ) { $sql= "SELECT id, naam, omschrijving FROM artiest WHERE id =".$_GET['id'].""; $result = mysql_query($sql); if ( mysql_num_rows($result) >= 1 ) { $i = 0; while ($data = mysql_fetch_array($result)) { $naam = stripslashes( $data['naam'] ); $omschrijving = stripslashes( $data['omschrijving'] ); echo '<table border="0">'.PHP_EOL; echo '<tr>'.PHP_EOL; echo '<td colspan="3" height="50"><p align="center"><h1>'.$naam.'</H1></td>'.PHP_EOL; echo '</tr>'.PHP_EOL; echo '<tr>'.PHP_EOL; echo '<td width="200" height="200" align="center">'.PHP_EOL; echo '<img src="../images/'.$naam.'.jpg" border="0" alt="'.$naam.'" /><br />'.PHP_EOL; echo '</td>'.PHP_EOL; echo '<td width="25">'.PHP_EOL; $result = mysql_query( " SELECT alfart FROM artiest_alfabetartiest, alfabetartiest WHERE artiest_id = '".$_GET['id']."' AND alfart_id = alfabetartiest.id ", $conn ); $i = 0; while ( $data3 = mysql_fetch_array($result) ) { $alfart = stripslashes( $data3['alfart'] ); $alfartlijst[] = $alfart; } echo '</td>'.PHP_EOL; echo '<td width="700"><font face="Arial" size="2">'.PHP_EOL; echo $omschrijving; echo '</td>'.PHP_EOL; echo '</tr>'.PHP_EOL; echo '</table>'.PHP_EOL; echo '<br/>'.PHP_EOL; $sql = "SELECT titel_id, titel, pos, jaar, song FROM artiest_titels, titels WHERE titel_id = titels.id AND artiest_id = '".$_GET['id']."' ORDER BY jaar ASC;"; $result = mysql_query ($sql ); if ( mysql_num_rows($result) >= 1 ) { $i = 0; echo '<div align="center">'.PHP_EOL; echo '<table border="0">'.PHP_EOL; while ($data = mysql_fetch_array($result)) { $titel_id = stripslashes( $data['titel_id'] ); $titel = stripslashes( $data['titel'] ); $pos = stripslashes( $data['pos'] ); $jaar = stripslashes( $data['jaar'] ); $song = stripslashes( $data['song'] ); echo '<tr>'.PHP_EOL; echo '<td width="200">'.PHP_EOL; echo '</td>'.PHP_EOL; echo '<td width="200">'.PHP_EOL; echo ''.$titel.''.PHP_EOL; echo '</td>'.PHP_EOL; echo '<td width="50" align="center" >'.PHP_EOL; echo ''.$pos.''.PHP_EOL; echo '</td>'.PHP_EOL; echo '<td width="50" align="right">'.PHP_EOL; echo ''.$jaar.''.PHP_EOL; echo '</td>'.PHP_EOL; echo '<td width="50" align="right">'.PHP_EOL; echo '<script type="text/javascript"> <!-- var aySound = new Array(); aySound[0] = "' .$song. '"; document.write("<BGSOUND ID="auIEContainer">") IE = (navigator.appVersion.indexOf("MSIE")!=-1 && document.all)? 1:0; NS = (navigator.appName=="Netscape" && navigator.plugins["LiveAudio"])? 1:0; ver4 = IE||NS? 1:0; onload=auPreload; function auPreload() { if (!ver4) return; if (NS) auEmb = new Layer(0,window); else { Str = "<DIV ID="auEmb" STYLE="position:absolute;"></DIV>"; document.body.insertAdjacentHTML("BeforeEnd",Str); } var Str = ''; for (i=0;i<aySound.length;i++) Str += "<EMBED SRC=""+aySound+"" AUTOSTART="FALSE" HIDDEN="TRUE">" if (IE) auEmb.innerHTML = Str; else { auEmb.document.open(); auEmb.document.write(Str); auEmb.document.close(); } auCon = IE? document.all.auIEContainer:auEmb; auCon.control = auCtrl; } function auCtrl(whSound,play) { if (IE) this.src = play? aySound[whSound]:""; else eval("this.document.embeds[whSound]." + (play? "play()":"stop()")) } function playSound(whSound) { if (window.auCon) auCon.control(whSound,true); } function stopSound(whSound) { if (window.auCon) auCon.control(whSound,false); } //--> </script>'.PHP_EOL; // line 335 echo '<img border="0" src="images/speakerdark.jpg" width="19" height="20" onMouseOver="playSound(0)" onMouseOut="stopSound(0)">'.PHP_EOL; echo '</td>'.PHP_EOL; echo '</tr>'.PHP_EOL; } echo '</table>'.PHP_EOL; if ( isset($_SESSION['userid']) && $_SESSION['dvdadmin']) { echo '<br />'.PHP_EOL; echo '<a href="'.titel.'?p=addartiesttitelform&did='.$_GET['id'].'" title="Extra titel toevoegen aan deze artiest" class="formleft">Extra titel toevoegen aan deze artiest</a>'.PHP_EOL; } echo '<br /><br /><hr />'.PHP_EOL; echo '<a href="'.artiest.'" title="Terug naar overzicht" class="formleft">Terug naar artiest overzicht</a>'.PHP_EOL; } else { echo 'Er zijn nog geen titels toegevoegd aan deze artiest.'.PHP_EOL; if ( isset($_SESSION['userid']) && $_SESSION['dvdadmin']) { echo '<br />'.PHP_EOL; echo '<a href="'.titel.'?p=addartiesttitelform&did='.$_GET['id'].'" title="Extra titel toevoegen aan deze artiest" class="formleft">Extra titel toevoegen aan deze artiest</a>'.PHP_EOL; } echo '<br /><br /><br /><hr />'.PHP_EOL; echo '<a href="'.artiest.'" title="Terug naar overzicht" class="formleft">Terug naar artiest overzicht</a>'.PHP_EOL; } } Quote Link to comment Share on other sites More sharing options...
sasa Posted February 26, 2011 Share Posted February 26, 2011 you must escape single qoutes in your echoed string (line 93) Quote Link to comment Share on other sites More sharing options...
clauske Posted February 26, 2011 Author Share Posted February 26, 2011 thanx sasa, no errors this is fixed. the next problem: i have the picture but don't play music www.hitarchief.be/artiest Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.