Re: functions in a external file [message #173971 is a reply to message #173968] |
Mon, 16 May 2011 11:00 |
Jerry Stuckle
Messages: 2598 Registered: September 2010
Karma:
|
Senior Member |
|
|
On 5/15/2011 11:42 PM, bruceaj wrote:
> On May 15, 10:13 pm, Jerry Stuckle<jstuck...@attglobal.net> wrote:
>> On 5/15/2011 9:18 PM, bruceaj wrote:
>>
>>
>>
>>> On May 15, 8:48 pm, Jerry Stuckle<jstuck...@attglobal.net> wrote:
>>>> On 5/15/2011 8:35 PM, bruceaj wrote:
>>
>>>> > Is there a maximum number of functions that can be contained in
>>>> > "require_once" php file?
>>
>>>> > I have this simple function (for testing this problem).
>>
>>>> > function GetTelephoneNumber () {
>>
>>>> > return "123 456-6789";
>>>> > }
>>
>>>> > If this function is in my main routine. No problem.
>>>> > If this function is in it's own file. No problem.
>>>> > If this function is in my main "function.php" file, I get the php
>>>> > blank. screen. l am using firefox and don't know how to get errors.
>>
>>>> > Appreciate help and suggestions....
>>
>>>> > Thanks...
>>
>>>> > Bruce
>>
>>>> No limit, other than the amount of code which has to be parsed.
>>
>>>> You have another problem. Enable error reporting and see what you get
>>>> for an error. You probably are not including the file properly.
>>
>>>> --
>>>> ==================
>>>> Remove the "x" from my email address
>>>> Jerry Stuckle
>>>> JDS Computer Training Corp.
>>>> jstuck...@attglobal.net
>>>> ==================
>>
>>> Thanks for the response.
>>
>>> I just checked the FIreFox menu items and didn't find where to enable
>>> error reporting. Where do I find the option to enable error
>>> reporting??
>>
>>> My main included file (functions.php} works perfectly when the above
>>> routine NOT in it. So I would think my require_once set up must be
>>> correct???
>>> If I put it in another file, and include that file, the routine works.
>>
>>> What does your statement "No limit, other than the amount of code
>>> which has to be parsed. " mean? Does it mean there is file byte size
>>> limitation??
>>
>>> Thanks..
>>
>>> Bruce
>>
>> It's in your php.ini file - the browser can't do anything to control
>> server-side errors.
>>
>> Ensure they are actually on - set up a file with just:
>>
>> <?php
>> phpinfo();
>> ?>
>>
>> And see if your error reporting and display are really on. They may be
>> overridden - or you may be using an entirely different php.ini file than
>> you think.
>>
>
> I thought I had changed the values but they didn't take. I had to
> restart Windows to make them take effect unless restarting was
> overkill..
>
> I had some errors in use date() which I fixed and my original error
> went away.
>
> Thanks all for the help...
>
> Bruce
You don't need to restart Windows, but you do need to restart the web
server. Your php.ini is only read on web server startup, not every request.
--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex(at)attglobal(dot)net
==================
|
|
|