Ik heb (dankzij luuk) een include pagina ofsowiets gemaakt. Ik heb dus (bij home.php) een code staan, die ervoor zorgt dat de tekst die bij pagina.html staat in home komt te staan. Maar dat lukt niet helemaal. Want er staat dat er een error is:

http://www.bouterworld.nl/home.php

Op lijn 37. Ik zal hier mijn code plaatsen, die van home.php. Maar ik ga nu ook slapen. Ik kijk morgen wel wat jullie allemaal gezegd hebben!!! Alvast bedankt.

<html>
<head>
<title>Welkom op www.bouterworld.nl</title>;
<style type="text/css">
<!--
body {
background-color: #99ccff;
font-size: 15 pt;
font-family: Cooper Black;
color: black;}
-->
</style>
</head>
<body bgcolor="#FFFFFF" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<table id="Tabel_01" width="971" height="593" border="0" cellpadding="0" cellspacing="0">
<tr>
<td colspan="2">
<img src="afbeeldingen/achtergrond_01.gif" width="971" height="89" alt=""></td>
</tr>
<tr>
<td width="970">
<img src="afbeeldingen/achtergrond_02.gif" width="271" height="411" alt=""></td>if
<?php if (isset($_GET['page']))
{
$page = $_GET['page'];
}
else
{
$page = 'home';
}
switch($page)
{
case 'home':
include 'home.html';
break;
case 'pagina'
include 'pagina.html'
break;
default:
echo 'niks';
}
?>
<td rowspan="2" width="1">
</tr>
<tr>
<td width="970">
<img src="afbeeldingen/achtergrond_04.gif" width="271" height="93" alt=""></td
</table>
</body>
</html>

Greets, lotte

ps. Welterusten iedereen!!!
Ik zie het. In welk vak wil je die tekst hebben? Het middelste?
jepsons, in het middelste.
Ik ga ff voor je sleutelen. Tien minuutjes!
Zo beter?

<html>
<head>
<title>Welkom op www.bouterworld.nl</title>;
<style type="text/css">
<!--
body {
background-color: #99ccff;
font-size: 15 pt;
font-family: Cooper Black;
color: black;}
-->
</style>
</head>
<body bgcolor="#FFFFFF" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<table id="Tabel_01" width="971" height="593" border="0" cellpadding="0" cellspacing="0">
<tr>
<td colspan="2"><img src="afbeeldingen/achtergrond_01.gif" width="971" height="89" alt=""></td>
</tr>

<tr>
<td width="1"><img src="afbeeldingen/achtergrond_02.gif" width="271" height="411" alt=""></td>
<td valign="top">
<p><font face="Cooper Black">Alles kan, ik zeg hier zomaar wat, omdat ik eigenlijk helemaal niets hoef te zeggen. </font></p>
<p><font face="Cooper Black">Maar goed, kijk eens naar dit plaatje: </font></p>
<p>&nbsp;</p>
<p> <img border="0" src="bigsadsmiley[1].gif" width="128" height="127"></p>
<p>&nbsp;</p>
<p><font face="Cooper Black">Dit is dus écht gewoon rotzooi hé!!! ff dat je dat weet</font></p></td>
</tr>

<tr>
<td colspan="2"><img src="afbeeldingen/achtergrond_04.gif" width="271" height="93" alt=""></td>
</tr>
</table>
</body>
</html>
Dus je index.php wordt zo:


<html>
<head>
<title>Welkom op www.bouterworld.nl</title>
<style type="text/css">
<!--
body {
background-color: #99ccff;
font-size: 15 pt;
font-family: Cooper Black;
color: black;}
-->
</style>
</head>
<body bgcolor="#FFFFFF" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0"> 
<table id="Tabel_01" width="971" height="593" border="0" cellpadding="0" cellspacing="0"> 
	<tr> 
		<td colspan="2"><img src="afbeeldingen/achtergrond_01.gif" width="971" height="89" alt=""></td> 
	</tr> 

	<tr> 
		<td width="1"><img src="afbeeldingen/achtergrond_02.gif" width="271" height="411" alt=""></td> 
		<td valign="top">
		<?php
			// hier je include stukje
		?>
		</td> 
	</tr> 

	<tr> 
		<td colspan="2"><img src="afbeeldingen/achtergrond_04.gif" width="271" height="93" alt=""></td> 
	</tr>
</table> 
</body>
</html>

En je content.php wordt zo:


<p><font face="Cooper Black">Alles kan, ik zeg hier zomaar wat, omdat ik eigenlijk helemaal niets hoef te zeggen. </font></p> 
<p><font face="Cooper Black">Maar goed, kijk eens naar dit plaatje: </font></p> 
<p>&nbsp;</p> 
<p> <img border="0" src="bigsadsmiley[1].gif" width="128" height="127"></p> 
<p>&nbsp;</p> 
<p><font face="Cooper Black">Dit is dus écht gewoon rotzooi hé!!! ff dat je dat weet</font></p>
SanThe schreef op 11.03.2006 22:28
En include 'bla'; moet met haakjes dus include('bla');
Quote uit de manual page op php.net:
Because include() is a special language construct, parentheses are not needed around its argument.
Oftewel: de haakjes zijn niet per se nodig.

Reageren