Christian Walgenbach: 2x die selbe Datei includen

Beitrag lesen

in dem man zwei mal include "datei.xy" schreibt.

index.php

<? include ("titel.php") ?>

html quellcode

<? include ("titel.php") ?>

--------

titel.php
<?
include("titelclass.php");

$titelclass = new titelclass();

$titelclass->titel( "Übersicht", "unserangebot/anatomiekurse/index.php");
$titelclass->titel( "Infos", "unserangebot/anatomiekurse/infos/index.php");
$titelclass->titel( "Erfahrungsberichte", "unserangebot/anatomiekurse/berichte/index.php");
$titelclass->titelother2( "Bildergalerie", "unserangebot/anatomiekurse/gallery/index.php");
$titelclass->titelother( "E-Mail", "Kontakt", "E-Mail", "kontakt/formular/index.php");

$titelclass->build();
?>
--------

Folgende Fehlermeldung bekomme ich:

Fatal error: Cannot redeclare class titelclass in F:\xampplite\htdocs\unserangebot\anatomiekurse\titelclass.php on line 4