Welcome visitor
* Login
* Register
It is currently July 20th, 2019, 5:09 am
All times are UTC [ DST ]
* Search
View unanswered posts - View active topics

FORUMS » Server Side » PHP



Post new topic Reply to topic  [ 2 posts ] 
Author Message
  Include command
PostPosted: February 4th, 2009, 10:50 pm 
User avatar

Posts: 37
Hello everyone, I'd been reading some PHP codes and found that many of them include the 'include' command and now im a little confused about it, can someone explain it to me please?


Top
 Profile  
 
  Re: Include command
PostPosted: February 4th, 2009, 11:04 pm 
User avatar

Posts: 27
:lol: no problem bro!

See it is a very useful comand that helps you keep each file short, or shorter, and organized.Let say that you have a file with all your functions, and you call it 'functions.php'. Also you have another file with the configuration stuff so you call it 'config.php'. Now, you can bring the content of those files, by simply adding them by
include('functions.php');
include('config.php');

By doing this you dont need to rewrite the whole thing again. Also you can easily use those files' content on other files. You can use the same to add a html file or wathever, just have in mind that, for example, an htm file will display a window on the screen, etc...


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

FORUMS » Server Side » PHP


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron