[FX.php List] PHP.ini question

Steve Winter steve at bluecrocodile.co.nz
Thu Nov 1 15:23:58 MDT 2007


Okay,

So you may in fact be on to something with it being a php.ini issue...
what's the function that's causing the issue...? are there any uncommon
looking methods being used within that function...? I don't recall which
version are on which box that you're working with, it may be that there's a
function in there which isn't supported yet/any longer, on the version of
php on the production box...

Send us the code of the function that's breaking things and we'll see if we
can spot anything...

Cheers
Steve

-----Original Message-----
From: fx.php_list-bounces at mail.iviking.org
[mailto:fx.php_list-bounces at mail.iviking.org] On Behalf Of John Funk
Sent: Thursday, 1 November 2007 9:18 p.m.
To: FX.php Discussion List
Subject: Re: [FX.php List] PHP.ini question

Steve,
I discovered that my problem is NOT the required_once function but rather
the include file it's self. I have isolated the problem to one function
inside the include file, When I take that out, things start to work.
Like I said before, I inherited this web site so I need to do some code
sloothing. But still what could be the difference between the servers that
might cause this.
John

On 11/1/07 12:54 PM, "Steve Winter" <steve at bluecrocodile.co.nz> wrote:

> John,
> 
> And what happens when you try to load
>    http://servername/includes/wi_form_lib.php
> Does the php page get loaded...? (make sure there's at least an echo
> 'hello'; or something right at the top of the file so that you can tell if
> it's been loaded...
> 
> This all seems really strange... it shouldn't be this hard...!!
> 
> Cheers
> Steve
> 
> -----Original Message-----
> From: fx.php_list-bounces at mail.iviking.org
> [mailto:fx.php_list-bounces at mail.iviking.org] On Behalf Of John Funk
> Sent: Thursday, 1 November 2007 5:35 p.m.
> To: FX.php Discussion List
> Subject: Re: [FX.php List] PHP.ini question
> 
> Steve, thanks for the explanation.
> Removal of the "/" does not work.
> The initial file, index.php is in the root directory and the
wi_form_lib.php
> is in the includes directory (one level above root)
> 
> 
> 
> On 11/1/07 11:39 AM, "Steve Winter" <steve at bluecrocodile.co.nz> wrote:
> 
>> John,
>> 
>> That's because of the fundamental difference between require and include,
>> the include is presumably still failing, however because it's only an
>> include the rest of the script will run... require says exactly that,
it's
>> required so if it can't be found, stop...!
>> 
>> Have you tried 
>>   require_once("includes/wi_form_lib.php");
>> 
>> (note the removal of the initial /)
>> 
>> Can you tell us more about the structure of the files..? what is the name
> of
>> the file that is trying to include wi_form_lib.php...? and where is that
>> file actually located relative to the file that's doing the calling...??
>> 
>> Cheers
>> Steve
>> 
>> -----Original Message-----
>> From: fx.php_list-bounces at mail.iviking.org
>> [mailto:fx.php_list-bounces at mail.iviking.org] On Behalf Of John Funk
>> Sent: Thursday, 1 November 2007 4:25 p.m.
>> To: FX.php Discussion List
>> Subject: Re: [FX.php List] PHP.ini question
>> 
>> Steve,
>> When I replace:
>> require_once($_SERVER['DOCUMENT_ROOT'] ."/includes/wi_form_lib.php"
>> With
>> require_once("/includes/wi_form_lib.php"
>> 
>> It still stops but I did find out that it is the require_once that is not
>> working because include_once DOES NOT stop the script.
>> I am checking the two PHP.ini files.
>> Any more ideas?
>> John
>> 
>> 
>> On 11/1/07 7:56 AM, "John Funk" <csinfo at comcast.net> wrote:
>> 
>>> Thanks Steve,
>>> At one time or another yesterday I tried echoing the path and it did
>> return
>>> the machine path (not URL) it seems ok but I will try the relative
method
>>> and let you know.
>>> John
>>> 
>>> 
>>> On 11/1/07 7:36 AM, "Steve Winter" <steve at bluecrocodile.co.nz> wrote:
>>> 
>>>> Hi John,
>>>> 
>>>> What do you see if you try;
>>>> 
>>>> echo $_SERVER['DOCUMENT_ROOT'].'<br />';
>>>> 
>>>> Is the returned path correct...??
>>>> 
>>>> Have you just tried calling the include without that...? I tend to use
>>>> relative references for includes, so in my instance I would have just
>> put;
>>>> 
>>>> <?php require_once("includes/wi_form_lib.php"); ?>
>>>> 
>>>> Assuming that the file doing the calling is in the root, and
>> wi_form_lib.php
>>>> is in a sub folder of that called includes...
>>>> 
>>>> Try those, see if you can get as far as getting wi_form_lib.php to
>> load...
>>>> stick an echo 'I loaded<br />'; as the first line so that you know that
>> it
>>>> is...
>>>> 
>>>> Once you get that loading, then you can look to replicate the same
tests
>> in
>>>> that file to determine what (if anything) is going wrong with including
>> the
>>>> FX.php files...
>>>> 
>>>> Let us know how you get on...
>>>> 
>>>> Cheers
>>>> Steve
>>>> 
>>>> -----Original Message-----
>>>> From: fx.php_list-bounces at mail.iviking.org
>>>> [mailto:fx.php_list-bounces at mail.iviking.org] On Behalf Of John Funk
>>>> Sent: Thursday, 1 November 2007 12:20 p.m.
>>>> To: FX.php Discussion List
>>>> Subject: Re: [FX.php List] PHP.ini question
>>>> 
>>>> We set up the test server before we knew about the environment at the
>>>> production ISP. The ISP's machine is shared by multiple sites, some PHP
>> so
>>>> the version cannot be changed.
>>>> Here is the code that is casueing problems:
>>>> <?php require_once($_SERVER['DOCUMENT_ROOT'] .
>> "/includes/wi_form_lib.php");
>>>> ?>
>>>> 
>>>> wi_form_lib.php is a script that does the form processing for
FileMaker.
>> And
>>>> wi_form_lib.php calls FX.php.
>>>>  (I inherited this project so some of this was out of my control.
>>>> Thanks
>>>> John
>>>> 
>>>> On 11/1/07 1:55 AM, "Gjermund Gusland Thorsen" <ggt667 at gmail.com>
wrote:
>>>> 
>>>>> And why are you running different versions?
>>>>> 
>>>>> A real test environment should always be identical to the production
>>>>> environment
>>>>> 
>>>>> ggt
>>>>> 
>>>>> On 11/1/07, Dale Bengston <dbengston at preservationstudio.com> wrote:
>>>>>> Hi John,
>>>>>> 
>>>>>> I'm putting my money on paths. Can you post the code that produces
>>>>>> different results on the different servers?
>>>>>> 
>>>>>> Thanks,
>>>>>> Dale
>>>>>> 
>>>>>> On Oct 31, 2007, at 9:41 PM, John Funk wrote:
>>>>>> 
>>>>>>> This may not be the place but I need to find out why on my Apache
> test
>>>>>>> server (Mac OS), can I use the PHP function (Require_Once) /
>>>>>>> (Include_once)
>>>>>>> just fine but on my production s Apache server (Unix) the PHP script
>>>>>>> just
>>>>>>> stalls right at the first occurance of this function.
>>>>>>> My server guy told me to compare PHP.ini files to see what is
>>>>>>> different.
>>>>>>> The PHP versions are 4.1.2 (test server) and 4.2.1 (Production).
>>>>>>> 
>>>>>>> Any more ideas out there?
>>>>>>> 
>>>>>>> Thanks
>>>>>>> John Funk
>>>>>>> 
>>>>>>> 
>>>>>>> _______________________________________________
>>>>>>> FX.php_List mailing list
>>>>>>> FX.php_List at mail.iviking.org
>>>>>>> http://www.iviking.org/mailman/listinfo/fx.php_list
>>>>>> 
>>>>>> _______________________________________________
>>>>>> FX.php_List mailing list
>>>>>> FX.php_List at mail.iviking.org
>>>>>> http://www.iviking.org/mailman/listinfo/fx.php_list
>>>>>> 
>>>>> _______________________________________________
>>>>> FX.php_List mailing list
>>>>> FX.php_List at mail.iviking.org
>>>>> http://www.iviking.org/mailman/listinfo/fx.php_list
>>>> 
>>>> 
>>>> _______________________________________________
>>>> FX.php_List mailing list
>>>> FX.php_List at mail.iviking.org
>>>> http://www.iviking.org/mailman/listinfo/fx.php_list
>>>> 
>>>> No virus found in this incoming message.
>>>> Checked by AVG Free Edition.
>>>> Version: 7.5.503 / Virus Database: 269.15.17/1103 - Release Date:
>> 1/11/2007
>>>> 6:01 a.m.
>>>>  
>>>> 
>>>> No virus found in this outgoing message.
>>>> Checked by AVG Free Edition.
>>>> Version: 7.5.503 / Virus Database: 269.15.17/1103 - Release Date:
>> 1/11/2007
>>>> 6:01 a.m.
>>>>  
>>>> 
>>>> 
>>>> _______________________________________________
>>>> FX.php_List mailing list
>>>> FX.php_List at mail.iviking.org
>>>> http://www.iviking.org/mailman/listinfo/fx.php_list
>>> 
>>> 
>>> _______________________________________________
>>> FX.php_List mailing list
>>> FX.php_List at mail.iviking.org
>>> http://www.iviking.org/mailman/listinfo/fx.php_list
>> 
>> 
>> _______________________________________________
>> FX.php_List mailing list
>> FX.php_List at mail.iviking.org
>> http://www.iviking.org/mailman/listinfo/fx.php_list
>> 
>> No virus found in this incoming message.
>> Checked by AVG Free Edition.
>> Version: 7.5.503 / Virus Database: 269.15.17/1103 - Release Date:
> 1/11/2007
>> 6:01 a.m.
>>  
>> 
>> No virus found in this outgoing message.
>> Checked by AVG Free Edition.
>> Version: 7.5.503 / Virus Database: 269.15.17/1103 - Release Date:
> 1/11/2007
>> 6:01 a.m.
>>  
>> 
>> 
>> _______________________________________________
>> FX.php_List mailing list
>> FX.php_List at mail.iviking.org
>> http://www.iviking.org/mailman/listinfo/fx.php_list
> 
> 
> _______________________________________________
> FX.php_List mailing list
> FX.php_List at mail.iviking.org
> http://www.iviking.org/mailman/listinfo/fx.php_list
> 
> No virus found in this incoming message.
> Checked by AVG Free Edition.
> Version: 7.5.503 / Virus Database: 269.15.17/1103 - Release Date:
1/11/2007
> 6:01 a.m.
>  
> 
> No virus found in this outgoing message.
> Checked by AVG Free Edition.
> Version: 7.5.503 / Virus Database: 269.15.17/1103 - Release Date:
1/11/2007
> 6:01 a.m.
>  
> 
> 
> _______________________________________________
> FX.php_List mailing list
> FX.php_List at mail.iviking.org
> http://www.iviking.org/mailman/listinfo/fx.php_list


_______________________________________________
FX.php_List mailing list
FX.php_List at mail.iviking.org
http://www.iviking.org/mailman/listinfo/fx.php_list

No virus found in this incoming message.
Checked by AVG Free Edition. 
Version: 7.5.503 / Virus Database: 269.15.17/1103 - Release Date: 1/11/2007
6:01 a.m.
 

No virus found in this outgoing message.
Checked by AVG Free Edition. 
Version: 7.5.503 / Virus Database: 269.15.17/1103 - Release Date: 1/11/2007
6:01 a.m.
 




More information about the FX.php_List mailing list