Include error

Gestart doorThomvh20 reacties88 weergaven

21 berichten · pagina 1 van 2

Thomvh

Lid · Topicstarter

Berichten
649
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Beste one2xs,

Ik wil een dj zegt include op mijn site maar ik krijg iedere keer deze error:
Spoiler tonen
Warning: include(../panel/frontend/djzegt.php) [function.include]: failed to open stream: No such file or directory in /home/xantosw80/domains/muziekcity.nl/public_html/modules/mod_php/mod_php.php(36) : eval()d code on line 4

Warning: include(../panel/frontend/djzegt.php) [function.include]: failed to open stream: No such file or directory in /home/xantosw80/domains/muziekcity.nl/public_html/modules/mod_php/mod_php.php(36) : eval()d code on line 4

Warning: include() [function.include]: Failed opening ../panel/frontend/djzegt.php for inclusion (include_path=.:/usr/local/lib/php) in /home/xantosw80/domains/muziekcity.nl/public_html/modules/mod_php/mod_php.php(36) : eval()d code on line 4
En ik heb dit gebruikt om te include:

[COLOR= #0000BB]<?php[/COLOR]
[URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]../panel/frontend/djzegt.php[/COLOR][COLOR= #007700]);[/COLOR]
?>


Weet iemand hoe ik deze kan fixen?

Alvast bedankt,

Thom
0
Berichten
6.201
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Misschien het goede bestand includen?

No such file or directory

Kortom; hij kan het bestand niet vinden wink
0
Thomvh

Lid · Topicstarter

Berichten
649
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Kjeld schreef:
Misschien het goede bestand includen?
No such file or directory

Kortom; hij kan het bestand niet vinden winkMaar het bestand is er toch echt?!
0
Berichten
93.699
Reputatie
0
Punten
1,27
Lid sinds
Laatst gezien
Hoe is je mappen structuur?
Waar staat het bestand wat je oproept (djzegt.php) en waar staat het bestand waarin die include staat..
0
Berichten
93.699
Reputatie
0
Punten
1,27
Lid sinds
Laatst gezien
[COLOR= #0000BB]<?php[/COLOR]
[URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]panel/frontend/djzegt.php[/COLOR][COLOR= #007700]);[/COLOR]
?>


Zo werkt die.
0
Thomvh

Lid · Topicstarter

Berichten
649
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Jellesch schreef:
[COLOR= #0000BB]<?php[/COLOR]
[URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]panel/frontend/djzegt.php[/COLOR][COLOR= #007700]);[/COLOR]
?>
Zo werkt die.

Deze werkte!!! Bedankt voor julllie hulp!
0
Berichten
93.699
Reputatie
0
Punten
1,27
Lid sinds
Laatst gezien
Thomvh schreef:
Eerdere citaten tonen
Jellesch schreef:
[COLOR= #0000BB]<?php[/COLOR]
[URL="http://www.php.net/include"]include[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]panel/frontend/djzegt.php[/COLOR][COLOR= #007700]);[/COLOR]
?>
Zo werkt die.
Deze werkte!!! Bedankt voor julllie hulp!

Werkte? Nu niet meer dan?
0
Thomvh

Lid · Topicstarter

Berichten
649
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Wil ik het volgende include krijg ik deze error:

Fatal error: Cannot redeclare ingelogd() (previously declared in /home/xantosw80/domains/muziekcity.nl/public_html/panel/inc/config.php:32) in /home/xantosw80/domains/muziekcity.nl/public_html/panel/inc/config.php on line 37


En dit is de config:

[COLOR= #0000BB]<?php[/COLOR]
[COLOR= #FF8000]// Laat dit staan, wanneer je deze code verwijdert krijg je geen support en updates meer![/COLOR]
  [URL="http://www.php.net/define"]define[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]versie[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000]1.0[/COLOR][COLOR= #007700]);[/COLOR]
  [COLOR= #0000BB]$fp[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/fopen"]fopen[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"http://dl.dropbox.com/u/55654170/versie.txt"[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000]"r"[/COLOR][COLOR= #007700]);[/COLOR]
  [URL="http://www.php.net/while"]while[/URL] [COLOR= #007700]([/COLOR][COLOR= #0000BB]$versie[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/fgets"]fgets[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$fp[/COLOR][COLOR= #007700])) {[/COLOR]
      [COLOR= #0000BB]$versoe[/COLOR][COLOR= #007700];[/COLOR]
      [URL="http://www.php.net/if"]if[/URL] [COLOR= #007700]([/COLOR]versie [COLOR= #007700]!=[/COLOR] [COLOR= #0000BB]$versie[/COLOR][COLOR= #007700]) {[/COLOR]
?>
<div id="versie">
Jouw versie is out-dated! Vraag de nieuwste versie aan SebastiaanH! <br>
Nieuwste versie: [COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #0000BB]$versie[/COLOR][COLOR= #007700];[/COLOR] ?>
</div>
[COLOR= #0000BB]<?php[/COLOR]
        [URL="http://www.php.net/die"]die[/URL][COLOR= #007700]();
      }
  }[/COLOR]
  
[COLOR= #FF8000]// shDJ is gemaakt door SebastiaanH op One2XS. Dit systeem mag niet verkocht worden!
// Iets kopieëren uit dit systeem is ten strengste verboden! [/COLOR]

[COLOR= #0000BB]$host[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700];[/COLOR]
[COLOR= #0000BB]$gebruiker[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700];[/COLOR]
[COLOR= #0000BB]$wachtwoord[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700];[/COLOR]
[COLOR= #0000BB]$database[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #DD0000]""[/COLOR][COLOR= #007700];[/COLOR]

[COLOR= #0000BB]$footer[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #DD0000]"&copy; Copyright shDJ - MuziekCity"[/COLOR][COLOR= #007700];[/COLOR]

[COLOR= #0000BB]$verbinding[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_connect"]mysql_connect[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"$host"[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000]"$gebruiker"[/COLOR][COLOR= #007700],[/COLOR] [COLOR= #DD0000]"$wachtwoord"[/COLOR][COLOR= #007700])[/COLOR] or [URL="http://www.php.net/die"]die[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"Kan geen verbinding maken met de server!"[/COLOR][COLOR= #007700]);[/COLOR]
              [URL="http://www.php.net/mysql_select_db"]mysql_select_db[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"$database"[/COLOR][COLOR= #007700])[/COLOR] or [URL="http://www.php.net/die"]die[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"Kan geen verbinding maken met de database!"[/COLOR][COLOR= #007700]);

function[/COLOR] ingelogd[COLOR= #007700](){[/COLOR]
    [URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/empty"]empty[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]naam[/COLOR][COLOR= #007700]])){[/COLOR]
        [URL="http://www.php.net/header"]header[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"Location: ?p=inloggen"[/COLOR][COLOR= #007700]);[/COLOR]
        [URL="http://www.php.net/exit"]exit[/URL][COLOR= #007700]();
    }[/COLOR][URL="http://www.php.net/else"]else[/URL][COLOR= #007700]{
    }
}[/COLOR]
?>
0
Berichten
93.699
Reputatie
0
Punten
1,27
Lid sinds
Laatst gezien
De functie ingelogd bestaat al.
0
Thomvh

Lid · Topicstarter

Berichten
649
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Hoe krijg ik die er dan uit? Want ik include in joomla. En dit is het dj panel dus dat zijn 2 verschillende logins. Heb hem er uit gekregen. Maar krijg nu steeds de error vul wel een title in http://muziekcity.nl/index.php/vraag-een-nummer-aan
0
Berichten
93.699
Reputatie
0
Punten
1,27
Lid sinds
Laatst gezien
De functie hernoemen.
0
Berichten
10.421
Reputatie
4
Punten
0,00
Lid sinds
Laatst gezien
Of een quick-fix..

include_once() gebruiken.
0
Thomvh

Lid · Topicstarter

Berichten
649
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Aarclay schreef:
Of een quick-fix..

include_once() gebruiken.
Als ik hem include met include_once pakt hij hem nog niet

[COLOR= #0000BB]<?php[/COLOR]
[URL="http://www.php.net/require"]require[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]panel/inc/config.php[/COLOR][COLOR= #007700]);[/COLOR]
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_SERVER[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]REQUEST_METHOD[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #DD0000]"POST"[/COLOR][COLOR= #007700]){[/COLOR]
    [URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/empty"]empty[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]naam[/COLOR][COLOR= #007700]])){[/COLOR]
        [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #DD0000]Vul wel een naam in![/COLOR][COLOR= #007700];
    }[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/empty"]empty[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]artiest[/COLOR][COLOR= #007700]])){[/COLOR]
        [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #DD0000]Vul wel een artiest in![/COLOR][COLOR= #007700];
    }[/COLOR][URL="http://www.php.net/elseif"]elseif[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/empty"]empty[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]titel[/COLOR][COLOR= #007700]])){[/COLOR]
        [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #DD0000]Vul wel een titel in![/COLOR][COLOR= #007700];
    }[/COLOR][URL="http://www.php.net/else"]else[/URL][COLOR= #007700]{[/COLOR]
        [COLOR= #0000BB]$datum[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/date"]date[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]I:s d-m-Y[/COLOR][COLOR= #007700]);[/COLOR]
        [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"INSERT INTO shouts (id, van, artiest, nummer, datum) VALUES (, "[/COLOR] [COLOR= #007700].[/COLOR] [URL="http://www.php.net/mysql_real_escape_string"]mysql_real_escape_string[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]naam[/COLOR][COLOR= #007700]]) .[/COLOR] [COLOR= #DD0000]", "[/COLOR] [COLOR= #007700].[/COLOR] [URL="http://www.php.net/mysql_real_escape_string"]mysql_real_escape_string[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]artiest[/COLOR][COLOR= #007700]]) .[/COLOR] [COLOR= #DD0000]", "[/COLOR] [COLOR= #007700].[/COLOR] [URL="http://www.php.net/mysql_real_escape_string"]mysql_real_escape_string[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]titel[/COLOR][COLOR= #007700]]) .[/COLOR] [COLOR= #DD0000]", "[/COLOR] [COLOR= #007700].[/COLOR] [COLOR= #0000BB]$datum[/COLOR] [COLOR= #007700].[/COLOR] [COLOR= #DD0000]")"[/COLOR][COLOR= #007700])[/COLOR] or [URL="http://www.php.net/die"]die[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/mysql_error"]mysql_error[/URL][COLOR= #007700]());[/COLOR]
        [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #DD0000]Jouw request is verzonden![/COLOR][COLOR= #007700];
    }
}[/COLOR][URL="http://www.php.net/else"]else[/URL][COLOR= #007700]{[/COLOR]
?>
    <form action="#" method="post" />
        Naam: <br />
        <input type="text" name="naam" /> <br />
        Artiest: <br />
        <input type="text" name="artiest" /> <br /> 
        Nummer: <br />
        <input type="text" name="nummer" /> <br /> 
        <input type="submit" name="submit" value="Verstuur" />
    </form>
[COLOR= #0000BB]<?php[/COLOR]
[COLOR= #007700]}[/COLOR]
?>


Dit is de request.php die ik include op de pagina die nu met een error op komt
0
Berichten
10.421
Reputatie
4
Punten
0,00
Lid sinds
Laatst gezien
Even wat anders; Je foutafhandeling is niet correct.
0
Thomvh

Lid · Topicstarter

Berichten
649
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Aarclay schreef:
Even wat anders; Je foutafhandeling is niet correct.
Hoe bedoel je?
0

Jouw reactie

Deel je idee, stel een vraag of help een ander verder.

Editor laden…

Praat mee met de One2xs-community.

Inloggen om te reageren