Ok, I have a slight problem that I am wondering if someone could help me out with. Like the title says, I want to include a php file, inside of html code, that is inside of more php code. What I mean by that is that if you look at the code below, you will notice $head = " this is a section of a php file. Now this $head variable is just the header of a template. Anyway, thats not the point. To simplify it, the:
Blue = PHP script in the php file
Green = HTML code inside that PHP code
Red = The php file I want to include but am having trouble doing so
$head = "
<html>
<head>
<LINK href='../lib/style.css' rel='stylesheet' type='text/css'>
<title>TITLE</title>
</head>
<body>
<center>
<div id='wrapper'>
<div id='topnav'>
<div class='nav'>
<? include('../lib/userlogin.php'); ?>
</div>
</div>
<div id='header'>
<a href='../index.php'><img src='../images/logo.png' border='0' alt='aaa' title='aaa'></a>
</div>
<div id='mainnav'>
<a href='../index.php'><img src='../images/01home.jpg' alt='Home' border='0' height='49' width='191' /></a><a href='../plans.php'><img src='../images/02plans.jpg' alt='Plans' border='0' height='49' width='197' /></a><a href='http://retect.com/forum/'><img src='../images/03forums.jpg' alt='Forums' border='0' height='49' width='201' /></a><a href='#'><img src='../images/04support.jpg' alt='Support' border='0' height='49' width='211' /></a>
</div>
<div id='menu'>
<? include('../admin/lib/nav.php'); ?>
</div>
<div id='content'>
<div class='ads'>
<p><center><? include('../lib/ads.php'); ?></center></p>
</div>
<br>
";
Could anyone please help me out with this problem of how to include a php file, that is inside of html code, that is inside of php script (if its no too confusing :P). Thanks.
Enter your message below
Sign in or Join us (it's free).