php-general Digest 20 Nov 2011 10:36:19 -0000 Issue 7577

Topics (messages 315771 through 315772):

Re: Impossibility of reading php.ini
        315771 by: Alain Chautar

Re: include
        315772 by: Tommy Pham

Administrivia:

To subscribe to the digest, e-mail:
        php-general-digest-subscr...@lists.php.net

To unsubscribe from the digest, e-mail:
        php-general-digest-unsubscr...@lists.php.net

To post to the list, e-mail:
        php-gene...@lists.php.net


----------------------------------------------------------------------
--- Begin Message ---
A look at the Apache log would have avoid opening this thread.
- a syntax error in php.ini : an uncommented comment line !!
- an older version of the ZendDebugger
Now everything is fine. It's work !!

Le 19/11/2011 20:55, Alain Chautar a écrit :
Yes I change the right one : /etc/php5/apache2/php.ini .It fit with "Loaded Configuration File" in phpinfo(). This the reason I get confused.

Le 19/11/2011 20:26, Matijn Woudt a écrit :
On Sat, Nov 19, 2011 at 7:23 PM, Alain Chautar<achau...@nerim.net> wrote:
Hello
I am a newbie of this list. So if this topic as a known answer, I apologize.

I use a brand new Debian Squeeze with PHP5.3.3-7+Squeeze3 as a web server.
All my web sites are OK.
For my needs I have to change values in the php.ini .
The way I proceed : I change values -> I save php.ini -> I restart Apache2
->  I verify with phpinfo() or ini_get
...
My phpinfo() can be read at 213.41.212.98/test.php
and my php.ini is join to this mail.

If somebody have an idea ???
Thanks.

Are you sure you changed the correct php.ini file? In my debian there
is one for the CLI and one for Apache, eg:

cd /etc&&  find -iname "php.ini"

./php5/cli/php.ini
./php5/apache2/php.ini

where ofcourse only the last one affects your website.

Matijn



--- End Message ---
--- Begin Message ---
On Sat, Nov 19, 2011 at 2:16 PM, Tim Streater <t...@clothears.org.uk> wrote:
> At the moment I'm using an instance of apache to run PHP scripts, as and when 
> required via AJAX. Having got some understanding of web sockets, I'm minded 
> to look at having a small server to execute these functions as required. The 
> scripts, some 50 or so, are only about 300kbytes of source code, which seems 
> small enough that it could all be loaded with include, as in:
>
> <?php
> $fn = 'wiggy.php';
> include $fn;
> ?>
>
> This appears to work although I couldn't see it documented.
>
> I'd also like to be able to replace a module without restarting the server. I 
> couldn't see a way to drop an included file, do I therefore take it that 
> there is none? Failing that, is there a good way to dynamically replace parts 
> of a PHP program, possibly using runkit?
>
> --
> Cheers  --  Tim
>
>

Tim,

I think you're approaching this the wrong way.
1) have a clear understanding of PHP - syntax, capabilities, etc.
2) have a clear understand of what you're intending to do -
application's function/purpose, features, manageability,
expandability, portability, etc...
3) understand design patterns

What your asking is practically impossible in any programming language
akin to 'how to un-import packages in Java' or 'how to un-using
namespace in C#'.  If you don't want to use it, don't include it ;)
If this is running as web app, you can use header [1] and pass the
criteria for next phase of the operation as URL parameters.  But doing
this is going to kill the server side with too many unnecessary round
trips.  Which clearly demonstrates point 2 and 3.  You should look
into Interfaces, and Abstract under OOP [2].

HTH,
Tommy

[1] http://php.net/function.header
[2] http://php.net/language.oop5

--- End Message ---

Reply via email to