Jump to content


Photo

Include multiple files


  • Please log in to reply
2 replies to this topic

#1 chris86

chris86
  • Members
  • PipPip
  • Member
  • 20 posts

Posted 06 June 2006 - 02:49 PM

I want to use a PHP include for more than one external file. How do I separate the file names? Do I use a comma, or a space? Is the code below correct?

include("domains.php" "rotate.php");

#2 ober

ober
  • Staff Alumni
  • Advanced Member
  • 5,337 posts
  • LocationEast Coast, USA

Posted 06 June 2006 - 02:52 PM

You can't do that for more than one file.

include("domains.php");
include("rotate.php");
include("other.php");
etc.

Info: PHP Manual


#3 chris86

chris86
  • Members
  • PipPip
  • Member
  • 20 posts

Posted 06 June 2006 - 02:56 PM

[!--quoteo(post=380619:date=Jun 6 2006, 10:52 AM:name=ober)--][div class=\'quotetop\']QUOTE(ober @ Jun 6 2006, 10:52 AM) View Post[/div][div class=\'quotemain\'][!--quotec--]
You can't do that for more than one file.

include("domains.php");
include("rotate.php");
include("other.php");
etc.
[/quote]


Ok, got it. One include file per line. Thanks ober.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users