how to display background in dynamic html pages with DOM

Oct 23 2013 1:26 AM
Hi, below code is  related  to displaying banner and background in dynamic html pages. Banner is displaying in html pages but background is not displayed
<?php
require('simple_html_dom.php');
$banner = $_GET["banner"];
$background = $_GET["background"];
$z="uploadbanner/";
a="uploadbackground/";
$bannerid= substr_replace($z,$banner,14,0);
//$backgroundid= substr_replace($a,$background,18,0);
$html=file_get_html("player.html");
$ele3=$html->getElementById('test3');
//$ele4=$html->getElementById('test4');
//$ele4->setAttribute('src',$backgroundid);
$n=file_put_contents("$name.html",$html);
$page=$name.'.html';
?>
player.html:
------------------
<img id="test3" src="" width="1600" height="200"> //for displaying banner
------------how to write code for background----------------

Answers (2)