Jump to content

undefined function error


mindapolis

Recommended Posts

why am I getting a undefined function error?  The function contactInfo names are spelled the same, right? 

 

<?php
function menu() {
echo <<<HEREDOC
	<ul id = "navBar">
		<li class = "menuChoice"><a href="homepage.php">Home</a></li>  
		<li class = "menuChoice"><a href="benefits.php">Benefits</a></li>  
		<li class = "menuChoice"><a href="portfolio.php">Portfolio</a></li>  	
		<li class = "menuChoice"><a href="contact.php">Contact</a>			
	</ul>
HEREDOC;
}
function logo()  {
echo <<<HEREDOC
	<hgroup>
		<h1>Site Services Unlimited</h1>
	</hgroup>
HEREDOC;	
}
function contactInfo() {
echo <<<HEREDOC
	808 Melching Drive Ossian, IN  46777 <br>
(260)-273-2708 <br>
<a href="mailto:[email protected]">Contact Us</a>
HEREDOC;
}
?>

 

<?php
require_once("functions.php");
?><!DOCTYPE HTML>
<html lang="en">
<head>
<meta charset="utf-8">
    <title>Untitled Document</title>
    <!--meta description -->
    <link rel="stylesheet" href="siteServices.css">
    <!--[if It IE 9]>
    <script src="http://html5shiv.googlecode-.com/svn/trunk/html5.js">
    </script>
    <![endif]--> 
<script type="text/javascript" language="javascript">
var slideArray = new Array()
slideArray[0]= "Web Design";
slideArray[1]= "Website Maintenance";
slideArray[2]= "Article Writing"; 
slideArray[3]= "Internet Research"; 
slideArray[4]=  "Blogging"; 
function textSlideShow()
{
var total_slides;
total_slides=Math.floor(Math.random()*slideArray.length)
document.getElementById('div_display').innerHTML=slideArray[total_slides];
setTimeout("textSlideShow()",800);
}
</script>
</head>

<body>
<div id="mainContent">
<header>
   		<?php logo(); ?>
    	<nav>
        	<?php menu(); ?>
        </nav>
     </header>
<table id = "skills">
<tr>
<td>
<div id="div_display"><script type="text/javascript" language="javascript">textSlideShow();</script></div>
</td>
</tr>
</table>
     <footer>
	<?php  contactInfo(); ?>
     </footer>
</div>
</body>
</html>

Link to comment
https://forums.phpfreaks.com/topic/264827-undefined-function-error/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.