+ Reply to Thread
Results 1 to 2 of 2

Thread: PHP Values in Apache VHost

  1. #1
    The Debian Lover heymrdj is on a distinguished road heymrdj's Avatar
    Join Date
    Sep 2005
    Posts
    1,489
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    PHP Values in Apache VHost

    I'm not sure how it works, I did it years ago but can't remember. I am installing an app on my VPS that needs increased PHP privileges, but I cannot affect the server's entire php.ini file as I have another app running that is NOT compatible with some of the changes that have to be made.

    These are the values:
    Code:
     memory_limit  = 32M
    max_execution_time = 60
    register_globals = Off
    magic_quotes_gpc = Off
    magic_quotes_runtime = Off
    upload_max_filesize = 16M
    session.use_trans_sid = Off
    session.gc_probability = 1
    session.gc_divisor = 10
    mbstring.func_overload = 7
    I found an example but it only showed two funtions. The person added these lines between the </IfModule> and </VirtualHost> lines:
    Code:
     php_value max_execution_time 60 
    php_flag register_globals Off
    He used those to give it the special php settings.
    I'm using a vhost of application.eahome.org, with the appropriate A records ect. I just need to know how to get above into a Vhost configuration. Thanks for the help.
    <<No begging>>

  2. #2
    The Debian Lover heymrdj is on a distinguished road heymrdj's Avatar
    Join Date
    Sep 2005
    Posts
    1,489
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Ok I worked it out. I made my Vhost the following way:

    Code:
    <VirtualHost *:80>
    DocumentRoot "/var/www/vhosts/www.eahome.org/htdocs/egw/"
    ServerName egw.eahome.org
    <Directory "/var/www/vhosts/www.eahome.org/htdocs/egw/">
    allow from all
    Options +Indexes
    </Directory>
    php_value memory_limit 32M
    php_value max_execution_time 60
    php_flag register_globals Off
    php_admin_flag safe_mode off
    php_flag magic_quotes_gpc Off
    php_flag magic_quotes_runtime Off 
    php_value upload_max_filesize 16M 
    php_flag session.use_trans_sid Off
    php_value session.gc_probability 1
    php_value session.gc_divisor 10 
    php_value mbstring.func_overload 7 
    </VirtualHost>
    Verified by a phpinfo in that domain, it changed the local php functions and not the master server's. The only problem with this is it MUST be accessed via egw.eahome.org and cannot be eahome.ore/egw, if it's called the latter way the server's normal php.ini takes over and screws it up. Looks like I might be using .htaccess after all.
    <<No begging>>

+ Reply to Thread

Similar Threads

  1. Domain Values
    By lifebot in forum Domain Names
    Replies: 0
    Last Post: November 14th, 2007, 16:01
  2. REQ: free bnc or vhost for irc
    By unknown00 in forum Free Services
    Replies: 8
    Last Post: May 25th, 2004, 10:48
  3. domain values
    By Lil_Rob in forum Free Services
    Replies: 3
    Last Post: April 17th, 2002, 19:09
  4. shell for vhost
    By wct in forum Free Services
    Replies: 0
    Last Post: December 21st, 2001, 00:19

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts