Solved

include_path ?? Need an explaination.. (PHP)

Posted on 2007-03-19
7
167 Views
Last Modified: 2010-04-20
In php ini - does the "include_path" nned to be set -i s it necessary and what is the propose of it?

Thanks in advance
0
Comment
Question by:whatisthesolution
  • 3
  • 2
  • 2
7 Comments
 
LVL 11

Expert Comment

by:AnthonyP9618
Comment Utility
I'm not sure there are flags needed with the include_path.

In any case, this link gives 2 ways of doing... 1 through the CONF and the second at runtime in your PHP code.

http://www.modwest.com/help/kb5-98.html
0
 
LVL 1

Author Comment

by:whatisthesolution
Comment Utility
Hmm anoying -  the mysql extensions refuses to turn on....
0
 
LVL 8

Accepted Solution

by:
nedfine earned 250 total points
Comment Utility
include_path:
Specifies a list of directories where the require(), include(), fopen(), file(), readfile() and file_get_contents() functions look for files. The format is like the system's PATH environment variable: a list of directories separated with a colon in Unix or semicolon in Windows.

Example H.1. Unix include_path
include_path=".:/php/includes"

Example H.2. Windows include_path
include_path=".;c:\php\includes"

Using a . in the include path allows for relative includes as it means the current directory.

0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 1

Author Comment

by:whatisthesolution
Comment Utility
So it's essential to set the path to get PHP to work properly?
0
 
LVL 8

Expert Comment

by:nedfine
Comment Utility
I think ,If you dont set it up, you have  to specify paths in your include statements to make it work.
0
 
LVL 11

Assisted Solution

by:AnthonyP9618
AnthonyP9618 earned 250 total points
Comment Utility
This is the only difference:

With: include("functions.php");
Without" include("..\..\functions.php")

0
 
LVL 1

Author Comment

by:whatisthesolution
Comment Utility
K..  thanks guys!
I'l make a split!

cheers!
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

If you don't have the right permissions set for your WordPress location in IIS, you won't be able to perform automatic updates. Here's how to fix the problem.
Envision that you are chipping away at another e-business site with a team of pundit developers and designers. Everything seems, by all accounts, to be going easily.
Viewers will get an overview of the benefits and risks of using Bitcoin to accept payments. What Bitcoin is: Legality: Risks: Benefits: Which businesses are best suited?: Other things you should know: How to get started:
The viewer will learn how to count occurrences of each item in an array.

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now