Re: [PHP] Include problems

2008-04-14 Thread Daniel Brown
On Sat, Apr 12, 2008 at 11:06 PM, Bojan Tesanovic <[EMAIL PROTECTED]> wrote:
>
>  On Apr 12, 2008, at 8:28 AM, GoWtHaM NaRiSiPaLli wrote:
>
>
> > if(file_exists("../common/config.ini")) {
> >  $configData = parse_ini_file("../common/config.ini");
> > } else {
> >
>
>
>  Try changing above code so it reads
>
>
>  if(file_exists("common/config.ini")) {
>   $configData = parse_ini_file("common/config.ini");
>  } else {

In your primary file, you could also consider adding:



And then, all includes from within that file would be included as such:



Finally, on a different note, it may not be in your best interest
to keep a .ini extension on a configuration file, since this is
generally readable on the web.

-- 

Ask me about:
Dedicated servers starting @ $59.99/mo., VPS starting @ $19.99/mo.,
and shared hosting starting @ $2.50/mo.
Unmanaged, managed, and fully-managed!

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Include problems

2008-04-12 Thread Bojan Tesanovic


On Apr 12, 2008, at 8:28 AM, GoWtHaM NaRiSiPaLli wrote:


if(file_exists("../common/config.ini")) {
  $configData = parse_ini_file("../common/config.ini");
} else {



Try changing above code so it reads

if(file_exists("common/config.ini")) {
  $configData = parse_ini_file("common/config.ini");
} else {


As the xyz.php is in

/var/www/sites/project/  folder , and  that is the starting path of  
the script


so any script that needs to include
/var/www/sites/project/common/someFile.php
you need to specify relative path to '/var/www/sites/project/'  which  
is 'common/someFile.php'


this should work unless some of included files uses 'chdir'  function  
that changes current directory




Igor Jocic
http://www.carster.us/ Used Car Classifieds






[PHP] Include problems

2008-04-11 Thread GoWtHaM NaRiSiPaLli
Hi PHP Experts,

I am writing a wrapper over some existing code and when I hoped that I
almost successfully completed it, I ran into the wall.

The wrapper file is in /var/www/sites/project/ as xyz.php and the file
includes some of the files from various paths.
Starting with
==
// Importing Init.php for initializing the libraries
include_once("checkout/controller/Init.php");

and this Init.php in /var/www/sites/project/checkout/controller loads the
configuration file and code is as below.


if(file_exists("../common/config.ini")) {
  $configData = parse_ini_file("../common/config.ini");
} else {
  $configData = false;
}
if (!$configData) {
  die("An error occurred while trying to get ".
  "confidential config data. Please ensure that the ".
  "pathname to this file in Init.php ".
  "is correct.");
}


This config.php file is in /var/www/sites/project/common/ but there is some
messup in the path and its not setting to the right path as it must looking
for the file with include path set to /var/www/sites/project/ rather
/var/www/sites/project/checkout(it works if I keep the xyz.php file in
checkout folder. But I want this file to be in parent folder for various
other reasons and I cant figure out for nuts how to make this path thing
work.

Thanks,
Gowtham.N


Re: [PHP] include() problems

2003-10-06 Thread Burhan Khalid
Gustave Bernier wrote:

I'm new to PHP and I'm trying to use the include function but with no 
success... My server's ini file is  set as (allow_url_fopen, 0) so I'm 
having some trouble to pass different values for the php file I'm 
calling. The address is: http://mydomain.com/forums/ssi.php?a=active

The code I'm trying now is:
$_GET['a'] = 'active';
include('forums/ssi.php');
Well, since everyone has commented on the including-same-file idea, 
might I point that this : $_GET['a'] = 'active'; looks a bit strange.

--
Burhan Khalid
phplist[at]meidomus[dot]com
http://www.meidomus.com

Tip : In your replies, please trim out the signature of
person you are replying to. No need to see the same
disclaimer 5 times. Leads to bloat.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] include() problems

2003-10-02 Thread Chris Sherwood

<-- snip -->
From: "Chris W. Parker" <[EMAIL PROTECTED]>
> The address is: http://mydomain.com/forums/ssi.php?a=active
> 
> The code I'm trying now is:
> $_GET['a'] = 'active';
> include('forums/ssi.php');

You're including the parent file in itself. This could be the problem.
<--SNIP --> 


especially if the ssi.php is not a class

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] include() problems

2003-10-02 Thread Chris W. Parker
Gustave Bernier 
on Thursday, October 02, 2003 6:20 AM said:

> The address is: http://mydomain.com/forums/ssi.php?a=active
> 
> The code I'm trying now is:
> $_GET['a'] = 'active';
> include('forums/ssi.php');

You're including the parent file in itself. This could be the problem.



c.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] include() problems

2003-10-02 Thread Gustave Bernier
Hi everyone,

I'm new to PHP and I'm trying to use the include function but with no 
success... My server's ini file is  set as (allow_url_fopen, 0) so I'm 
having some trouble to pass different values for the php file I'm calling. 
The address is: http://mydomain.com/forums/ssi.php?a=active

The code I'm trying now is:
$_GET['a'] = 'active';
include('forums/ssi.php');
When I use this code I have no error, ssi.php is loaded but nothing is done 
(I believe the "a" value isn't passed to ssi.php) and the page where the 
include is stops loading just after the include().

What's the problem??? How can I pass values to a php file from another 
file???

Thanks,

 GuTa

_
MSN Messenger: instale grátis e converse com seus amigos. 
http://messenger.msn.com.br

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] include () problems

2003-08-25 Thread Jim Lucas
If you are having a problem that tells you that output was displayed on a
given line in a given file.  And you found this because after the output you
tried sending headers, then look in that file on that given line, and you
will see the problem.

It could be a simple as a

?>


To: <[EMAIL PROTECTED]>
Sent: Monday, August 25, 2003 12:56 AM
Subject: [PHP] include () problems


> Hi,
>
> When I run the line:
>
> include ("fnord.php");
>
> with the file looking like:
>
>  define ("fnord_included", true);
> function fnord ($arg = true) {
>
> // 450 lines
> return $msg;
>
> }
> ?>
>
> it prints out the return of fnord() (i.e. $msg).  I've checked, and
there's
> no echo or print statemetns anywhere...
>
> Oh, yeah, FYI, the pattern goes like this:
>
> file: index.php
> 
> file: standard.php
>  ("Content-type: text/html; encoding=utf-8"); ?>
>
> and it prints it right up the top of index.php, causing an error with the
> "header" statement (although it says the error is in fnord.php - which
> contains NO header statemtns).
>
> ideas?
>
> Regards,
>
> mjec
>
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] include () problems

2003-08-25 Thread Mjec
Hi,

When I run the line:

include ("fnord.php");

with the file looking like:



it prints out the return of fnord() (i.e. $msg).  I've checked, and there's
no echo or print statemetns anywhere...

Oh, yeah, FYI, the pattern goes like this:

file: index.php

file: standard.php


and it prints it right up the top of index.php, causing an error with the
"header" statement (although it says the error is in fnord.php - which
contains NO header statemtns).

ideas?

Regards,

mjec

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Include Problems

2003-07-25 Thread sven
hi eric,

as far as i can see, there is no definition for your '$subnav' in your
'incHeader.php'.

if you call your main script like this:
'http://example.com/index.php?subnav="home";', this should work with your
inclusion.

ciao SVEN

Eric Fleming wrote:
> Here is a snippet from the header file.  You can see that I am just
> trying to determine what the value of the subnav variable is set to
> in order to determine which navigational link is bold.  There are
> other places the variable is used, but you can get an idea based on
> what is below.  Thanks for any help.
>
> <-incHeader.php-->
>
> 
> 
> [Site Name]
> 
> 
> 
> 
> 
>  href="index.php">home
> 
> 
> 
>
> <-incHeader.php-->
>
>
> "Jennifer Goodie" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
>> Without seeing what you have in your includes, it will be hard to
>> determine where your scope is messed up.
>>
>>> >>  $subnav = "home";
>>>  include("incHeader.php");

>>>
>>> 
>>>
>>> The content would go here.
>>>
>>> 
>>>
>>> 
>>>
>>> Now, when I try to reference the subnav variable in the
>>> inHeader.php or incFooter.php files, it comes up blank.  I am
>>> basically trying to adjust the
>>> navigation on each page depending on the page I am on.  I am just
>>> learning PHP, have programmed in ColdFusion for years and in
>>> ColdFusion
>>> this was not
>>> a problem.  Any ideas?



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Include Problems

2003-07-24 Thread Eric Fleming
I figured out what was wrong with it, thanks for all your help.  I hate
syntax errors. I needed to echo the variable when trying to display it and
the double "=" helped resolve the other problem.  Thanks everyone.



"Chris W. Parker" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
Jay Blanchard 
on Thursday, July 24, 2003 1:12 PM said:

> I just cleaned it up some, used non deprecated formatting tags and sis
> it all in one shot.

Yeah but Jay, you didn't allow for an else. Your code should have an
else in there so that even if he's not at home it'll still print the
link, just not bold. ;)

Also, a ternary operator would be best for this.

echo ($subnav == "home") ? "Home" :
"Home";


Chris.



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Include Problems

2003-07-24 Thread Chris W. Parker
Jay Blanchard 
on Thursday, July 24, 2003 1:12 PM said:

> I just cleaned it up some, used non deprecated formatting tags and sis
> it all in one shot.

Yeah but Jay, you didn't allow for an else. Your code should have an
else in there so that even if he's not at home it'll still print the
link, just not bold. ;)

Also, a ternary operator would be best for this.

echo ($subnav == "home") ? "Home" :
"Home";


Chris.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Include Problems

2003-07-24 Thread Jay Blanchard
[snip]
What is different about the code that you wrote except that you have the
html being output by php?
[/snip]

I just cleaned it up some, used non deprecated formatting tags and sis
it all in one shot.

HTH

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Include Problems

2003-07-24 Thread Eric Fleming
I have ran it on my local machine and at my hosting company and it doesn't
work for me.  I even tried using  wrote in message
news:[EMAIL PROTECTED]
> Eric, I tried your code on my machine and it seems to print the name of
> the variable just fine.  The only change I had to make to your code was
> add the long PHP tags (i.e.  disabled.  Here's the header as I ran it.
>
> 
> 
> 
> [Site Name]
> 
> 
> 
> 
> 
> 
> 
> home
> 
> 
> 
> 
>

>
> It printed home twice once bolded and as a link.  I don't think the
> problem is your code maybe some weird php.ini setting is set, as to
> which one however I couldn't say.
>
> Jason
>
> On Thu, 2003-07-24 at 15:44, Eric Fleming wrote:
> > Yeah, that is a problem, but I can't even print out the value of the
subnav
> > variable.  It prints nothing when I try to print the variable.
> >
> >
> > "Jason Giangrande" <[EMAIL PROTECTED]> wrote in message
> > news:[EMAIL PROTECTED]
> > > Eric, If you want to check to see if $subnav is equal to "home" you
want
> > > to use == and not =.  Perhaps this is your problem.
> > >
> > > Jason
> > >
> > > On Thu, 2003-07-24 at 15:35, Eric Fleming wrote:
> > > > Here is a snippet from the header file.  You can see that I am just
> > trying
> > > > to determine what the value of the subnav variable is set to in
order to
> > > > determine which navigational link is bold.  There are other places
the
> > > > variable is used, but you can get an idea based on what is below.
> > Thanks
> > > > for any help.
> > > >
> > > > <-incHeader.php-->
> > > >
> > > > 
> > > > 
> > > > [Site Name]
> > > > 
> > > > 
> > > > 
> > > > 
> > > > 
> > > >  > > > href="index.php">home
> > > > 
> > > > 
> > > > 
> > > >
> > > > <-incHeader.php-->
> > >
> > >
> >
> >
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Include Problems

2003-07-24 Thread Jason Giangrande
Eric, I tried your code on my machine and it seems to print the name of
the variable just fine.  The only change I had to make to your code was
add the long PHP tags (i.e. 


[Site Name]







home






It printed home twice once bolded and as a link.  I don't think the
problem is your code maybe some weird php.ini setting is set, as to
which one however I couldn't say.

Jason

On Thu, 2003-07-24 at 15:44, Eric Fleming wrote:
> Yeah, that is a problem, but I can't even print out the value of the subnav
> variable.  It prints nothing when I try to print the variable.
> 
> 
> "Jason Giangrande" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
> > Eric, If you want to check to see if $subnav is equal to "home" you want
> > to use == and not =.  Perhaps this is your problem.
> >
> > Jason
> >
> > On Thu, 2003-07-24 at 15:35, Eric Fleming wrote:
> > > Here is a snippet from the header file.  You can see that I am just
> trying
> > > to determine what the value of the subnav variable is set to in order to
> > > determine which navigational link is bold.  There are other places the
> > > variable is used, but you can get an idea based on what is below.
> Thanks
> > > for any help.
> > >
> > > <-incHeader.php-->
> > >
> > > 
> > > 
> > > [Site Name]
> > > 
> > > 
> > > 
> > > 
> > > 
> > >  > > href="index.php">home
> > > 
> > > 
> > > 
> > >
> > > <-incHeader.php-->
> >
> >
> 
> 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Include Problems

2003-07-24 Thread Eric Fleming
What is different about the code that you wrote except that you have the
html being output by php?


"Jay Blanchard" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
[snip]
<-incHeader.php-->



[Site Name]





home




<-incHeader.php-->
[/snip]

home");
}
?>

HTH!



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Include Problems

2003-07-24 Thread Jay Blanchard
[snip]
<-incHeader.php-->



[Site Name]





home




<-incHeader.php-->
[/snip]

home");
}
?>

HTH!

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Include Problems

2003-07-24 Thread Eric Fleming
Here is a snippet from the header file.  You can see that I am just trying
to determine what the value of the subnav variable is set to in order to
determine which navigational link is bold.  There are other places the
variable is used, but you can get an idea based on what is below.  Thanks
for any help.

<-incHeader.php-->



[Site Name]





home




<-incHeader.php-->


"Jennifer Goodie" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Without seeing what you have in your includes, it will be hard to
determine
> where your scope is messed up.
>
> >  >  $subnav = "home";
> >  include("incHeader.php");
> > ?>
> >
> > 
> >
> > The content would go here.
> >
> > 
> >
> > 
> >
> > Now, when I try to reference the subnav variable in the inHeader.php or
> > incFooter.php files, it comes up blank.  I am basically trying to
> > adjust the
> > navigation on each page depending on the page I am on.  I am just
learning
> > PHP, have programmed in ColdFusion for years and in ColdFusion
> > this was not
> > a problem.  Any ideas?
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Include Problems

2003-07-24 Thread Eric Fleming
Yeah, that is a problem, but I can't even print out the value of the subnav
variable.  It prints nothing when I try to print the variable.


"Jason Giangrande" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Eric, If you want to check to see if $subnav is equal to "home" you want
> to use == and not =.  Perhaps this is your problem.
>
> Jason
>
> On Thu, 2003-07-24 at 15:35, Eric Fleming wrote:
> > Here is a snippet from the header file.  You can see that I am just
trying
> > to determine what the value of the subnav variable is set to in order to
> > determine which navigational link is bold.  There are other places the
> > variable is used, but you can get an idea based on what is below.
Thanks
> > for any help.
> >
> > <-incHeader.php-->
> >
> > 
> > 
> > [Site Name]
> > 
> > 
> > 
> > 
> > 
> >  > href="index.php">home
> > 
> > 
> > 
> >
> > <-incHeader.php-->
>
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Include Problems

2003-07-24 Thread Jason Giangrande
Eric, If you want to check to see if $subnav is equal to "home" you want
to use == and not =.  Perhaps this is your problem.

Jason

On Thu, 2003-07-24 at 15:35, Eric Fleming wrote:
> Here is a snippet from the header file.  You can see that I am just trying
> to determine what the value of the subnav variable is set to in order to
> determine which navigational link is bold.  There are other places the
> variable is used, but you can get an idea based on what is below.  Thanks
> for any help.
> 
> <-incHeader.php-->
> 
> 
> 
> [Site Name]
> 
> 
> 
> 
> 
>  href="index.php">home
> 
> 
> 
> 
> <-incHeader.php-->



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Include Problems

2003-07-24 Thread Eric Fleming
Here is a snippet from the header file.  You can see that I am just trying
to determine what the value of the subnav variable is set to in order to
determine which navigational link is bold.  There are other places the
variable is used, but you can get an idea based on what is below.  Thanks
for any help.

<-incHeader.php-->



[Site Name]





home




<-incHeader.php-->



"Jay Blanchard" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
[snip]




The content would go here.





Now, when I try to reference the subnav variable in the inHeader.php or
incFooter.php files, it comes up blank.  I am basically trying to adjust
the
navigation on each page depending on the page I am on.  I am just
learning
PHP, have programmed in ColdFusion for years and in ColdFusion this was
not
a problem.  Any ideas?
[/snip]

Can we see the incHeader.php and the incFooter.php code?



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Include Problems

2003-07-24 Thread Jason Giangrande
Is the code you are trying to call $subnav from inside a function?  If
so you will need to tell the function that by using the global keyword
(i.e. global $subnav;).  Other than that the code you've shown looks
right to me.

Jason

On Thu, 2003-07-24 at 13:55, Eric Fleming wrote:
> I am having some problems using variables in included files.  Can someone
> please look at my code below and see how I might accomplish what I am trying
> to do?
> 
>   $subnav = "home";
>  include("incHeader.php");
> ?>
> 
> 
> 
> The content would go here.
> 
> 
> 
> 
> 
> Now, when I try to reference the subnav variable in the inHeader.php or
> incFooter.php files, it comes up blank.  I am basically trying to adjust the
> navigation on each page depending on the page I am on.  I am just learning
> PHP, have programmed in ColdFusion for years and in ColdFusion this was not
> a problem.  Any ideas?
> 
> Eric Fleming
> 
> 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Include Problems

2003-07-24 Thread Jennifer Goodie
Without seeing what you have in your includes, it will be hard to determine
where your scope is messed up.

>   $subnav = "home";
>  include("incHeader.php");
> ?>
>
> 
>
> The content would go here.
>
> 
>
> 
>
> Now, when I try to reference the subnav variable in the inHeader.php or
> incFooter.php files, it comes up blank.  I am basically trying to
> adjust the
> navigation on each page depending on the page I am on.  I am just learning
> PHP, have programmed in ColdFusion for years and in ColdFusion
> this was not
> a problem.  Any ideas?


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Include Problems

2003-07-24 Thread Jay Blanchard
[snip]




The content would go here.





Now, when I try to reference the subnav variable in the inHeader.php or
incFooter.php files, it comes up blank.  I am basically trying to adjust
the
navigation on each page depending on the page I am on.  I am just
learning
PHP, have programmed in ColdFusion for years and in ColdFusion this was
not
a problem.  Any ideas?
[/snip]

Can we see the incHeader.php and the incFooter.php code?

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Include Problems

2003-07-24 Thread Jeff Harris
On Jul 24, 2003, "Eric Fleming" claimed that:

|I am having some problems using variables in included files.  Can someone
|please look at my code below and see how I might accomplish what I am trying
|to do?
[snip]
|Now, when I try to reference the subnav variable in the inHeader.php or
|incFooter.php files, it comes up blank.  I am basically trying to adjust the
|navigation on each page depending on the page I am on.  I am just learning
|PHP, have programmed in ColdFusion for years and in ColdFusion this was not
|a problem.  Any ideas?
|
|Eric Fleming
|

http://www.php.net/language.variables.scope
Jeff Harris
-- 
Registered Linux user #304026.
"lynx -source http://jharris.rallycentral.us/jharris.asc | gpg --import"
Key fingerprint = 52FC 20BD 025A 8C13 5FC6  68C6 9CF9 46C2 B089 0FED
Responses to this message should conform to RFC 1855.



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Include Problems

2003-07-24 Thread Eric Fleming
I am having some problems using variables in included files.  Can someone
please look at my code below and see how I might accomplish what I am trying
to do?





The content would go here.





Now, when I try to reference the subnav variable in the inHeader.php or
incFooter.php files, it comes up blank.  I am basically trying to adjust the
navigation on each page depending on the page I am on.  I am just learning
PHP, have programmed in ColdFusion for years and in ColdFusion this was not
a problem.  Any ideas?

Eric Fleming



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Include() problems IGNORE PARENT

2003-02-14 Thread Leo Spalteholz
Never mind.  Apparently I can't tell the difference between a capital 
and a lowercase B.  time to crash methinks.

leo

On February 13, 2003 11:59 pm, Leo Spalteholz wrote:
> I just ran into a somewhat strange problem with an include failing.
> I have the following in my script:
> include(dirname(__FILE__)."/LNScreens/LNScrMain.php");
> include(dirname(__FILE__)."/LNDataBase/LNDataBase.php");
>
> The first file is included just fine, but the LNDataBase file fails
> (Failed opening for inclusion).  My directory structure is:
>
> /LNDataBase
>   LNDataBase.php
> /LNScreens
>   LNScrMain.php
> index.php
>
> The file exists and it seems to be the exact same syntax as what I
> used to include the other file.  What else could possibly be wrong?
>
> Thanks for any help,
> Leo


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP] Include() problems

2003-02-13 Thread Leo Spalteholz
I just ran into a somewhat strange problem with an include failing.
I have the following in my script:
include(dirname(__FILE__)."/LNScreens/LNScrMain.php");
include(dirname(__FILE__)."/LNDataBase/LNDataBase.php");

The first file is included just fine, but the LNDataBase file fails 
(Failed opening for inclusion).  My directory structure is:

/LNDataBase
LNDataBase.php
/LNScreens
LNScrMain.php
index.php

The file exists and it seems to be the exact same syntax as what I 
used to include the other file.  What else could possibly be wrong?

Thanks for any help,
Leo

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Include Problems

2002-12-26 Thread Gerald Timothy Quimpo
On Thursday 26 December 2002 12:06 pm, Mike Bowers wrote:
> It's not permissions. The files to be read as well as folders are all
> CHMOD 777 as I thought it was this originally. 

don't use 777.  that makes the scripts writeable for everyone. any
other user who can run scripts on that server can delete those
scripts or replace them with something malicious.  if any scripts
on that server can be tricked into executing code as the webserver
user (nobody, apache, www, whatever) then those files of yours
can also be modified.

you're probably just testing on a private server, in which case 
777 is convenient (still a bad habit, but convenient).  but remember to 
fix the permissions when you upload to a real server.  better yet,
switch to saner permissions even if only testing on a private server.

> > *Warning*: Failed opening 'editable/meta.php' for inclusion
> > (include_path='') in
> > */home/groups/v/vw/vwportal/htdocs/includes/header.php* on line *52*

looks like include_path in your php.ini is empty.  if you have:



what does the include_path section say?  normally, you should have
entries in there corresponding to directories where include files can
be found.  e.g., a good minimal include_path might be:

include_path=".:..:/var/lib/www/standard_php_includes"

or something similar (i made up the last part, replace with wherever you
put standard includes that you use).  i like having the current directory
and .. in there for obvious reasons.

tiger

-- 
Gerald Timothy Quimpo  tiger*quimpo*org gquimpo*sni-inc.com tiger*sni*ph
Public Key: "gpg --keyserver pgp.mit.edu --recv-keys 672F4C78"
   Veritas liberabit vos.
   Doveryai no proveryai.

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




RE: [PHP] Include Problems

2002-12-26 Thread Mike Bowers
This has worked.
Thanks for your inout and help everybody.


-Original Message-
From: John Nichel [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, December 26, 2002 1:13 PM
To: Mike Bowers; [EMAIL PROTECTED]
Subject: Re: [PHP] Include Problems


You can try setting your include path in a .htaccess file in your web 
root, like this

php_value include_path ".:/path/to/include/directory"

Mike Bowers wrote:
> The includes are as follows:
> Include("editable/meta.php");
> Include("javascript.php");
> Include("editable/my_header.php");
> 
> 
> 
> -Original Message-
> From: John Nichel [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, December 26, 2002 12:58 PM
> To: Mike Bowers
> Cc: [EMAIL PROTECTED]
> Subject: Re: [PHP] Include Problems
> 
> 
> Post the include statements from your header.php file.
> 
> Mike Bowers wrote:
> 
>>Isnt this supposed to be a friendly place where people who are having
>>problem with PHP can ask questions without people like u throwing 
>>insults?
>> 
>> 
>>-Original Message-
>>From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
>>Sent: Thursday, December 26, 2002 12:47 PM
>>To: Mike Bowers
>>Subject: Re: [PHP] Include Problems
>>
>>
>>
>>Learn to quote GAMER
>>
>>- Original Message -
>>From: Mike Bowers <mailto:[EMAIL PROTECTED]>
>>To: [EMAIL PROTECTED] 
>>Sent: Thursday, December 26, 2002 8:42 PM
>>Subject: [PHP] Include Problems
>>
>>I have a file named header.php stored in the includes folder: Inside
>>includes is anohter folder called editable. When I open my page for 
>>the first time (before it is cached) or after I edit my header file I 
>>get these errors:
>>Warning: Failed opening 'editable/meta.php' for inclusion
>>(include_path='') in 
>>/home/groups/v/vw/vwportal/htdocs/includes/header.php on line 52
>>
>>Warning: Failed opening 'javascript.php' for inclusion
>>(include_path='') in 
>>/home/groups/v/vw/vwportal/htdocs/includes/header.php on line 53
>>
>>
>>Warning: Failed opening 'editable/my_header.php' for inclusion
>>(include_path='') in
>>/home/groups/v/vw/vwportal/htdocs/includes/header.php on line 56
>> 
>>Is there any other command I can run iside my header.php file instead
>>of include that will print the contents of the includes that the 
>>header has?
>> 
>>Mike Bowers
>>PlanetModz Gaming Network Webmaster
>>[EMAIL PROTECTED]
>>ViperWeb Hosting Server Manager [EMAIL PROTECTED] 
>>[EMAIL PROTECTED] All outgoing messages scanned for viruses
>>using Norton AV 2002
>>
>>
> 
> 
> 


-- 
By-Tor.com
It's all about the Rush
http://www.by-tor.com



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Include Problems

2002-12-26 Thread Chris Wesley
On Thu, 26 Dec 2002, Mike Bowers wrote:

> I have a file named header.php stored in the includes folder:
> Inside includes is anohter folder called editable.
> When I open my page for the first time (before it is cached) or after I
> edit my header file I get these errors:
> Warning: Failed opening 'editable/meta.php' for inclusion
> (include_path='') in

Your include_path in php.ini is null, as indicated by the line above.

What you're assuming will happen is that include will automatically look
in the "includes" dir for files, so you have to set this:
include_path="./includes"

I set mine:
include_path = ".:./:../:./include:../include"

g.luck,
~Chris


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Include Problems

2002-12-26 Thread John Nichel
You can try setting your include path in a .htaccess file in your web 
root, like this

php_value include_path ".:/path/to/include/directory"

Mike Bowers wrote:
The includes are as follows:
Include("editable/meta.php");
Include("javascript.php");
Include("editable/my_header.php");



-Original Message-
From: John Nichel [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, December 26, 2002 12:58 PM
To: Mike Bowers
Cc: [EMAIL PROTECTED]
Subject: Re: [PHP] Include Problems


Post the include statements from your header.php file.

Mike Bowers wrote:

Isnt this supposed to be a friendly place where people who are having 
problem with PHP can ask questions without people like u throwing 
insults?


-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Thursday, December 26, 2002 12:47 PM
To: Mike Bowers
Subject: Re: [PHP] Include Problems



Learn to quote GAMER

- Original Message -
From: Mike Bowers <mailto:[EMAIL PROTECTED]>  
To: [EMAIL PROTECTED] 
Sent: Thursday, December 26, 2002 8:42 PM
Subject: [PHP] Include Problems

I have a file named header.php stored in the includes folder: Inside 
includes is anohter folder called editable. When I open my page for 
the first time (before it is cached) or after I edit my header file I 
get these errors:
Warning: Failed opening 'editable/meta.php' for inclusion
(include_path='') in 
/home/groups/v/vw/vwportal/htdocs/includes/header.php on line 52

Warning: Failed opening 'javascript.php' for inclusion 
(include_path='') in 
/home/groups/v/vw/vwportal/htdocs/includes/header.php on line 53


Warning: Failed opening 'editable/my_header.php' for inclusion
(include_path='') in 
/home/groups/v/vw/vwportal/htdocs/includes/header.php on line 56

Is there any other command I can run iside my header.php file instead 
of include that will print the contents of the includes that the 
header has?

Mike Bowers
PlanetModz Gaming Network Webmaster
[EMAIL PROTECTED]
ViperWeb Hosting Server Manager [EMAIL PROTECTED]
[EMAIL PROTECTED]
All outgoing messages scanned for viruses
using Norton AV 2002








--
By-Tor.com
It's all about the Rush
http://www.by-tor.com


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




RE: [PHP] Include Problems

2002-12-26 Thread Mike Bowers
It's not permissions. The files to be read as well as folders are all
CHMOD 777 as I thought it was this originally. Thanks for your
suggestion though.


-Original Message-
From: Chris Hewitt [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, December 26, 2002 1:11 PM
To: Mike Bowers
Cc: [EMAIL PROTECTED]
Subject: Re: [PHP] Include Problems


Mike Bowers wrote:

> I have a file named header.php stored in the includes folder:
>
> Inside includes is anohter folder called editable.
>
> When I open my page for the first time (before it is cached) or after
> I edit my header file I get these errors:
>
> *Warning*: Failed opening 'editable/meta.php' for inclusion
> (include_path='') in 
> */home/groups/v/vw/vwportal/htdocs/includes/header.php* on line *52*
>
Perhaps it is a permissions problem, after editing it (as whatever user 
you use to edit files), is the file readable by the user the webserver 
runs as?

HTH
Chris
PS I'm sure it would be appreciated if you would be kind enough to post 
in plain text (not html), someone has to pay for archiving it.


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Include Problems

2002-12-26 Thread Chris Hewitt
Mike Bowers wrote:


I have a file named header.php stored in the includes folder:

Inside includes is anohter folder called editable.

When I open my page for the first time (before it is cached) or after 
I edit my header file I get these errors:

*Warning*: Failed opening 'editable/meta.php' for inclusion 
(include_path='') in 
*/home/groups/v/vw/vwportal/htdocs/includes/header.php* on line *52*

Perhaps it is a permissions problem, after editing it (as whatever user 
you use to edit files), is the file readable by the user the webserver 
runs as?

HTH
Chris
PS I'm sure it would be appreciated if you would be kind enough to post 
in plain text (not html), someone has to pay for archiving it.


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Include Problems

2002-12-26 Thread John Nichel
A couple of items which will help you get a better / friendlier response 
here.

Don't send mail to the list in HTML format, and don't request a return 
reciept.

HTH

Mike Bowers wrote:
Isnt this supposed to be a friendly place where people who are having
problem with PHP can ask questions without people like u throwing
insults?
 
 
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, December 26, 2002 12:47 PM
To: Mike Bowers
Subject: Re: [PHP] Include Problems



Learn to quote GAMER

- Original Message - 
From: Mike Bowers <mailto:[EMAIL PROTECTED]>  
To: [EMAIL PROTECTED] 
Sent: Thursday, December 26, 2002 8:42 PM
Subject: [PHP] Include Problems

I have a file named header.php stored in the includes folder:
Inside includes is anohter folder called editable.
When I open my page for the first time (before it is cached) or after I
edit my header file I get these errors:
Warning: Failed opening 'editable/meta.php' for inclusion
(include_path='') in
/home/groups/v/vw/vwportal/htdocs/includes/header.php on line 52

Warning: Failed opening 'javascript.php' for inclusion (include_path='')
in /home/groups/v/vw/vwportal/htdocs/includes/header.php on line 53


Warning: Failed opening 'editable/my_header.php' for inclusion
(include_path='') in
/home/groups/v/vw/vwportal/htdocs/includes/header.php on line 56
 
Is there any other command I can run iside my header.php file instead of
include that will print the contents of the includes that the header
has?
 
Mike Bowers
PlanetModz Gaming Network Webmaster
[EMAIL PROTECTED]
ViperWeb Hosting Server Manager
[EMAIL PROTECTED]
[EMAIL PROTECTED]
All outgoing messages scanned for viruses
using Norton AV 2002




--
By-Tor.com
It's all about the Rush
http://www.by-tor.com


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Include Problems

2002-12-26 Thread John Nichel
Post the include statements from your header.php file.

Mike Bowers wrote:

Isnt this supposed to be a friendly place where people who are having
problem with PHP can ask questions without people like u throwing
insults?
 
 
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, December 26, 2002 12:47 PM
To: Mike Bowers
Subject: Re: [PHP] Include Problems



Learn to quote GAMER

- Original Message - 
From: Mike Bowers <mailto:[EMAIL PROTECTED]>  
To: [EMAIL PROTECTED] 
Sent: Thursday, December 26, 2002 8:42 PM
Subject: [PHP] Include Problems

I have a file named header.php stored in the includes folder:
Inside includes is anohter folder called editable.
When I open my page for the first time (before it is cached) or after I
edit my header file I get these errors:
Warning: Failed opening 'editable/meta.php' for inclusion
(include_path='') in
/home/groups/v/vw/vwportal/htdocs/includes/header.php on line 52

Warning: Failed opening 'javascript.php' for inclusion (include_path='')
in /home/groups/v/vw/vwportal/htdocs/includes/header.php on line 53


Warning: Failed opening 'editable/my_header.php' for inclusion
(include_path='') in
/home/groups/v/vw/vwportal/htdocs/includes/header.php on line 56
 
Is there any other command I can run iside my header.php file instead of
include that will print the contents of the includes that the header
has?
 
Mike Bowers
PlanetModz Gaming Network Webmaster
[EMAIL PROTECTED]
ViperWeb Hosting Server Manager
[EMAIL PROTECTED]
[EMAIL PROTECTED]
All outgoing messages scanned for viruses
using Norton AV 2002




--
By-Tor.com
It's all about the Rush
http://www.by-tor.com


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




RE: [PHP] Include Problems

2002-12-26 Thread Mike Bowers
Isnt this supposed to be a friendly place where people who are having
problem with PHP can ask questions without people like u throwing
insults?
 
 
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, December 26, 2002 12:47 PM
To: Mike Bowers
Subject: Re: [PHP] Include Problems



Learn to quote GAMER

- Original Message - 
From: Mike Bowers <mailto:[EMAIL PROTECTED]>  
To: [EMAIL PROTECTED] 
Sent: Thursday, December 26, 2002 8:42 PM
Subject: [PHP] Include Problems

I have a file named header.php stored in the includes folder:
Inside includes is anohter folder called editable.
When I open my page for the first time (before it is cached) or after I
edit my header file I get these errors:
Warning: Failed opening 'editable/meta.php' for inclusion
(include_path='') in
/home/groups/v/vw/vwportal/htdocs/includes/header.php on line 52

Warning: Failed opening 'javascript.php' for inclusion (include_path='')
in /home/groups/v/vw/vwportal/htdocs/includes/header.php on line 53


Warning: Failed opening 'editable/my_header.php' for inclusion
(include_path='') in
/home/groups/v/vw/vwportal/htdocs/includes/header.php on line 56
 
Is there any other command I can run iside my header.php file instead of
include that will print the contents of the includes that the header
has?
 
Mike Bowers
PlanetModz Gaming Network Webmaster
[EMAIL PROTECTED]
ViperWeb Hosting Server Manager
[EMAIL PROTECTED]
[EMAIL PROTECTED]
All outgoing messages scanned for viruses
using Norton AV 2002




[PHP] Include Problems

2002-12-26 Thread Mike Bowers
Title: Message



I have a file named 
header.php stored in the includes folder:
Inside includes is 
anohter folder called editable.
When I open my page for the first time 
(before it is cached) or after I edit my header file I get these 
errors:
Warning: Failed opening 
'editable/meta.php' for inclusion (include_path='') in 
/home/groups/v/vw/vwportal/htdocs/includes/header.php on line 
52Warning: Failed opening 'javascript.php' for inclusion 
(include_path='') in 
/home/groups/v/vw/vwportal/htdocs/includes/header.php on line 
53Warning: Failed opening 'editable/my_header.php' for 
inclusion (include_path='') in 
/home/groups/v/vw/vwportal/htdocs/includes/header.php on line 
56
 
Is there any other 
command I can run iside my header.php file instead of include that will print 
the contents of the includes that the header has?
 
Mike Bowers
PlanetModz Gaming Network Webmaster
[EMAIL PROTECTED]
ViperWeb Hosting Server Manager
[EMAIL PROTECTED]
[EMAIL PROTECTED]
All outgoing messages scanned for 
viruses
using Norton AV 2002


Re: [PHP] Include problems

2002-08-03 Thread ::: Flavio Bastos Amiel::::::>

Thanks Maxim, it is good to know! :)

Flavio Bastos Amiel
"Maxim Maletsky" <[EMAIL PROTECTED]> wrote in message
000401c23b48$55266960$1113fe17@dominanta">news:000401c23b48$55266960$1113fe17@dominanta...
> Include and require are identical, except for their failure behavior -
> require() halts permanently ending execution of the script.
>
>
> Sincerely,
>
> Maxim Maletsky
>
> PHP Beginner
> www.phpbeginner.com
>
>
> > -Original Message-
> > From: ::: Flavio Bastos Amiel::> [mailto:[EMAIL PROTECTED]]
> > Sent: Wednesday, September 04, 2002 12:53 AM
> > To: [EMAIL PROTECTED]
> > Subject: Re: [PHP] Include problems
> >
> > does the "require" has something to be with "include" ?
> > Cause instead of using "include" im always usin "require"
> >
> >
> > Thanks,
> > Flavio Bastos Amiel
> >
> >
> > "Scott" <[EMAIL PROTECTED]> wrote in message
> > [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> > > Does this mean i have to do this to each site???
> > >
> > >
> > >
> > >
> > >
> > > "Daniel Kushner" <[EMAIL PROTECTED]> wrote in message
> > > [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> > > > include 'inc/test.inc' will work fine if you add your root
> directory
> > to
> > > your
> > > > include_path (in the c:\winnt\php.ini file).
> > > >
> > > >
> > > > Daniel Kushner
> > > > [EMAIL PROTECTED]
> > > >
> > > > Need hosting? http://www.TheHostingCompany.us/
> > > >
> > > > > -Original Message-
> > > > > From: Scott [mailto:[EMAIL PROTECTED]]
> > > > > Sent: Saturday, August 03, 2002 3:11 PM
> > > > > To: [EMAIL PROTECTED]
> > > > > Subject: [PHP] Include problems
> > > > >
> > > > >
> > > > > I have PHP4 on both a windows IIS server and a windows apache
> server.
> > > The
> > > > > include function only works in the same directory of the file I
> wish
> > to
> > > > > access.
> > > > >
> > > > > ex.  www.include.com/default.php
> > > > > all files in same directory (i guess the root)?
> > > > >  > > > > include 'test.inc'
> > > > > ?>
> > > > >
> > > > > everything works fine.  Here's where I have the problem.
> > > > >
> > > > > Now I want to store all my includes in one directory
> > > www.include.com/inc
> > > > >
> > > > >  > > > > include 'inc/test.inc'
> > > > > ?>
> > > > > that doesn't work>>>
> > > > > Warning: Failed opening 'test.inc' for inclusion
> (include_path='')
> > > > >
> > > > > Can anyone help me with this???
> > > > >
> > > > > Thanks
> > > > > scott
> > > > >
> > > > >
> > > > >
> > > > >
> > > > > --
> > > > > PHP General Mailing List (http://www.php.net/)
> > > > > To unsubscribe, visit: http://www.php.net/unsub.php
> > > > >
> > > > >
> > > >
> > >
> > >
> >
> >
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
>
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




RE: [PHP] Include problems

2002-08-03 Thread Maxim Maletsky

Include and require are identical, except for their failure behavior -
require() halts permanently ending execution of the script.


Sincerely,

Maxim Maletsky

PHP Beginner
www.phpbeginner.com


> -Original Message-
> From: ::: Flavio Bastos Amiel::> [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, September 04, 2002 12:53 AM
> To: [EMAIL PROTECTED]
> Subject: Re: [PHP] Include problems
> 
> does the "require" has something to be with "include" ?
> Cause instead of using "include" im always usin "require"
> 
> 
> Thanks,
> Flavio Bastos Amiel
> 
> 
> "Scott" <[EMAIL PROTECTED]> wrote in message
> [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> > Does this mean i have to do this to each site???
> >
> >
> >
> >
> >
> > "Daniel Kushner" <[EMAIL PROTECTED]> wrote in message
> > [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> > > include 'inc/test.inc' will work fine if you add your root
directory
> to
> > your
> > > include_path (in the c:\winnt\php.ini file).
> > >
> > >
> > > Daniel Kushner
> > > [EMAIL PROTECTED]
> > >
> > > Need hosting? http://www.TheHostingCompany.us/
> > >
> > > > -Original Message-
> > > > From: Scott [mailto:[EMAIL PROTECTED]]
> > > > Sent: Saturday, August 03, 2002 3:11 PM
> > > > To: [EMAIL PROTECTED]
> > > > Subject: [PHP] Include problems
> > > >
> > > >
> > > > I have PHP4 on both a windows IIS server and a windows apache
server.
> > The
> > > > include function only works in the same directory of the file I
wish
> to
> > > > access.
> > > >
> > > > ex.  www.include.com/default.php
> > > > all files in same directory (i guess the root)?
> > > >  > > > include 'test.inc'
> > > > ?>
> > > >
> > > > everything works fine.  Here's where I have the problem.
> > > >
> > > > Now I want to store all my includes in one directory
> > www.include.com/inc
> > > >
> > > >  > > > include 'inc/test.inc'
> > > > ?>
> > > > that doesn't work>>>
> > > > Warning: Failed opening 'test.inc' for inclusion
(include_path='')
> > > >
> > > > Can anyone help me with this???
> > > >
> > > > Thanks
> > > > scott
> > > >
> > > >
> > > >
> > > >
> > > > --
> > > > PHP General Mailing List (http://www.php.net/)
> > > > To unsubscribe, visit: http://www.php.net/unsub.php
> > > >
> > > >
> > >
> >
> >
> 
> 
> 
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Include problems

2002-08-03 Thread ::: Flavio Bastos Amiel::::::>

does the "require" has something to be with "include" ?
Cause instead of using "include" im always usin "require"


Thanks,
Flavio Bastos Amiel


"Scott" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Does this mean i have to do this to each site???
>
>
>
>
>
> "Daniel Kushner" <[EMAIL PROTECTED]> wrote in message
> [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> > include 'inc/test.inc' will work fine if you add your root directory to
> your
> > include_path (in the c:\winnt\php.ini file).
> >
> >
> > Daniel Kushner
> > [EMAIL PROTECTED]
> >
> > Need hosting? http://www.TheHostingCompany.us/
> >
> > > -Original Message-
> > > From: Scott [mailto:[EMAIL PROTECTED]]
> > > Sent: Saturday, August 03, 2002 3:11 PM
> > > To: [EMAIL PROTECTED]
> > > Subject: [PHP] Include problems
> > >
> > >
> > > I have PHP4 on both a windows IIS server and a windows apache server.
> The
> > > include function only works in the same directory of the file I wish
to
> > > access.
> > >
> > > ex.  www.include.com/default.php
> > > all files in same directory (i guess the root)?
> > >  > > include 'test.inc'
> > > ?>
> > >
> > > everything works fine.  Here's where I have the problem.
> > >
> > > Now I want to store all my includes in one directory
> www.include.com/inc
> > >
> > >  > > include 'inc/test.inc'
> > > ?>
> > > that doesn't work>>>
> > > Warning: Failed opening 'test.inc' for inclusion (include_path='')
> > >
> > > Can anyone help me with this???
> > >
> > > Thanks
> > > scott
> > >
> > >
> > >
> > >
> > > --
> > > PHP General Mailing List (http://www.php.net/)
> > > To unsubscribe, visit: http://www.php.net/unsub.php
> > >
> > >
> >
>
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Include problems

2002-08-03 Thread Scott

Does this mean i have to do this to each site???





"Daniel Kushner" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> include 'inc/test.inc' will work fine if you add your root directory to
your
> include_path (in the c:\winnt\php.ini file).
>
>
> Daniel Kushner
> [EMAIL PROTECTED]
>
> Need hosting? http://www.TheHostingCompany.us/
>
> > -Original Message-
> > From: Scott [mailto:[EMAIL PROTECTED]]
> > Sent: Saturday, August 03, 2002 3:11 PM
> > To: [EMAIL PROTECTED]
> > Subject: [PHP] Include problems
> >
> >
> > I have PHP4 on both a windows IIS server and a windows apache server.
The
> > include function only works in the same directory of the file I wish to
> > access.
> >
> > ex.  www.include.com/default.php
> > all files in same directory (i guess the root)?
> >  > include 'test.inc'
> > ?>
> >
> > everything works fine.  Here's where I have the problem.
> >
> > Now I want to store all my includes in one directory
www.include.com/inc
> >
> >  > include 'inc/test.inc'
> > ?>
> > that doesn't work>>>
> > Warning: Failed opening 'test.inc' for inclusion (include_path='')
> >
> > Can anyone help me with this???
> >
> > Thanks
> > scott
> >
> >
> >
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
> >
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




RE: [PHP] Include problems

2002-08-03 Thread Daniel Kushner

include 'inc/test.inc' will work fine if you add your root directory to your
include_path (in the c:\winnt\php.ini file).


Daniel Kushner
[EMAIL PROTECTED]

Need hosting? http://www.TheHostingCompany.us/

> -Original Message-
> From: Scott [mailto:[EMAIL PROTECTED]]
> Sent: Saturday, August 03, 2002 3:11 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] Include problems
>
>
> I have PHP4 on both a windows IIS server and a windows apache server.  The
> include function only works in the same directory of the file I wish to
> access.
>
> ex.  www.include.com/default.php
> all files in same directory (i guess the root)?
>  include 'test.inc'
> ?>
>
> everything works fine.  Here's where I have the problem.
>
> Now I want to store all my includes in one directory   www.include.com/inc
>
>  include 'inc/test.inc'
> ?>
> that doesn't work>>>
> Warning: Failed opening 'test.inc' for inclusion (include_path='')
>
> Can anyone help me with this???
>
> Thanks
> scott
>
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP] Include problems

2002-08-03 Thread Scott

I have PHP4 on both a windows IIS server and a windows apache server.  The
include function only works in the same directory of the file I wish to
access.

ex.  www.include.com/default.php
all files in same directory (i guess the root)?


everything works fine.  Here's where I have the problem.

Now I want to store all my includes in one directory   www.include.com/inc


that doesn't work>>>
Warning: Failed opening 'test.inc' for inclusion (include_path='')

Can anyone help me with this???

Thanks
scott




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php