PHP Footer is causing problems...

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
doctork11
Forum Newbie
Posts: 1
Joined: Mon Feb 07, 2011 12:17 am

PHP Footer is causing problems...

Post by doctork11 »

I have this PHP code that I'm confused about.

Code: Select all

<?php 
	$footer_data =<<<EOT
<script type="text/javascript">
var json_form = {$json_form};
var json_elements = {$json_element};
</script>
EOT;
	require('includes/footer.php'); 
?>
the problem is the footer. Without it, the page would load completely. With it, it brings in different information. The standard page says "Company Name" "Copyright", with this code, the footer has default information... "Your Company" "Enter Copyright"...

Here is the footer data I want, but I don't get...

Code: Select all

</div><!--end panel-->

</div><!--end container-->

<img id="bottom" src="images/bottom.png" class="fix_png"/>
<div id="footer">
<div align="center"><strong>Powered by Dot-3</strong><br />&copy; Copyright 2009-2010 Dot-3 Technology</div>
</div><!--footer-->
<?php if(!empty($footer_data)){ echo $footer_data; } ?>
</body>
</html>
Thoughts?
cpetercarter
Forum Contributor
Posts: 474
Joined: Sat Jul 25, 2009 2:00 am

Re: PHP Footer is causing problems...

Post by cpetercarter »

Which is the bit which you think should put the company and copyright stuff on the page? The javascript in the code you have posted simply defines two variables - there must be something else which actually displays it. And where are the php variables $json_form and $json_element defined?
Post Reply