wuzzle
-
Posts
2 -
Joined
-
Last visited
Never
Posts posted by wuzzle
-
-
Alright here's my problem. I currently have a layout php called include.inc.php which holds this code:
Echo "$SHTM<table border=1>
<tr>
<td>Cell 1</td>
<td>Cell 2</td>
</tr>
</table>
$EHTML";
?>
Now my issue is when I want to include this layout into other pages whenever I add text to a new .php it puts it after the table, when I want it to go into either cell 1 or cell 2 of the table. Now I'm pretty sure the below code is correct, however I do not know what to put after the include("include.inc.php"); part in order to edit the certain cells. Any help would be amazing!
<?PHP
include("include.inc.php");
?>
Layout template help
in PHP Coding Help
Posted
[code]<?php
include("include.inc.php");[/code]
at the very start of code.
What I need to know is how to insert text or other things in the middle of this include.inc.php file.
-------------
So an example (this is my include.php file)
<?php
Echo "$SHTM<table border=1>
<tr>
<td>Cell 1</td>
<td>Cell 2</td>
</tr>
</table>
$EHTML";
?>
My index page needs a welcome message and my layout is just a normal two cell table. I want to insert the word hello into the second cell by changing the /index.php file while leaving the include.inc.php file alone. And then another page (lets say index2.php needs to say another message in the cell 2, but only by changing the index2.php.
index.php file:
<?PHP
include("include.inc.php");
?>
??? ??? ??? (PS sorry I'm very noob at PHP and I hope this makes sense.)