If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Data Access, Manipulation & Batch Languages > PHP > Getting Apache to work with PHP

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 02-02-10, 20:02
RRT RRT is offline
Registered User
 
Join Date: Jan 2010
Posts: 5
Question Getting Apache to work with PHP

Can you tell me what I need to change in either my httpd.conf file or my php.ini file to get PHP to work with Apache version 2.2.11. I'm using PHP version 5.2.9, however whenever I create a PHP file in my /var/www/html/ directory and then browse to it, my browser tries to download the php file instead of executing/displaying it as it should do. I have these httpd.conf and php.ini files on my server, and at these different locations: (I'm running Fedora)

/etc/httpd/conf/httpd.conf

/usr/local/lib/php.ini
/usr/local/php/php-5.2.9/php.ini
/etc/php.d/php.ini
Reply With Quote
  #2 (permalink)  
Old 02-03-10, 03:32
healdem healdem is online now
Jaded Developer
 
Join Date: Nov 2004
Location: out on a limb
Posts: 8,768
so Apache isn't recognising the PHP module.
you need to look at the apache and/or php logs and try to see if there is an error message there
if this is a development machine, personally I'd be tempted to download a copy of XAMPP and install that.
__________________
I'd rather be riding my Versys or my Tiger 800 let alone the Norton
Reply With Quote
  #3 (permalink)  
Old 02-03-10, 18:00
RRT RRT is offline
Registered User
 
Join Date: Jan 2010
Posts: 5
Question undefined symbol: sqlite3ExprDelete

Thanks. This is what it spits out at the command line when I start Apache. I don't even know where its referencing sqlite3 from??? Any ideas?

-----
# apachectl start
httpd: Syntax error on line 234 of /usr/local/apache2/conf/httpd.conf: Cannot load /usr/local/apache2/modules/libphp5.so into server: /usr/local/apache2/modules/libphp5.so: undefined symbol: sqlite3ExprDelete
-----

Here is a list of all the modules being loaded (none of them say sqlite...)

-----
# more httpd.conf | grep LoadModule

# have to place corresponding `LoadModule' lines at this location so the
# LoadModule foo_module modules/mod_foo.so
LoadModule access_module modules/mod_access.so
LoadModule auth_module modules/mod_auth.so
LoadModule auth_anon_module modules/mod_auth_anon.so
LoadModule auth_dbm_module modules/mod_auth_dbm.so
LoadModule auth_digest_module modules/mod_auth_digest.so
LoadModule ldap_module modules/mod_ldap.so
LoadModule auth_ldap_module modules/mod_auth_ldap.so
LoadModule include_module modules/mod_include.so
LoadModule log_config_module modules/mod_log_config.so
LoadModule logio_module modules/mod_logio.so
LoadModule env_module modules/mod_env.so
LoadModule mime_magic_module modules/mod_mime_magic.so
LoadModule mime_magic_module modules/mod_mime_magic.so
LoadModule cern_meta_module modules/mod_cern_meta.so
LoadModule expires_module modules/mod_expires.so
LoadModule deflate_module modules/mod_deflate.so
LoadModule headers_module modules/mod_headers.so
LoadModule usertrack_module modules/mod_usertrack.so
LoadModule setenvif_module modules/mod_setenvif.so
LoadModule mime_module modules/mod_mime.so
LoadModule dav_module modules/mod_dav.so
LoadModule status_module modules/mod_status.so
LoadModule autoindex_module modules/mod_autoindex.so
LoadModule asis_module modules/mod_asis.so
LoadModule info_module modules/mod_info.so
LoadModule dav_fs_module modules/mod_dav_fs.so
LoadModule vhost_alias_module modules/mod_vhost_alias.so
LoadModule negotiation_module modules/mod_negotiation.so
LoadModule dir_module modules/mod_dir.so
LoadModule actions_module modules/mod_actions.so
LoadModule speling_module modules/mod_speling.so
LoadModule userdir_module modules/mod_userdir.so
LoadModule alias_module modules/mod_alias.so
LoadModule rewrite_module modules/mod_rewrite.so
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_ftp_module modules/mod_proxy_ftp.so
LoadModule proxy_http_module modules/mod_proxy_http.so
LoadModule proxy_connect_module modules/mod_proxy_connect.so
LoadModule cache_module modules/mod_cache.so
LoadModule suexec_module modules/mod_suexec.so
LoadModule disk_cache_module modules/mod_disk_cache.so
LoadModule file_cache_module modules/mod_file_cache.so
LoadModule mem_cache_module modules/mod_mem_cache.so
LoadModule cgi_module modules/mod_cgi.so
LoadModule php5_module /usr/local/php-5.2.9/modules/libphp5.so

-----
Reply With Quote
  #4 (permalink)  
Old 02-04-10, 02:22
healdem healdem is online now
Jaded Developer
 
Join Date: Nov 2004
Location: out on a limb
Posts: 8,768
so your problem is in the apache config file
you need to investigate why it...
Quote:
Cannot load /usr/local/apache2/modules/libphp5
off hand it looks like its missing the sqllite files, which IIRC are now part of the standard PHP build
it could be that there is a parameter on line 234 of /usr/local/apache2/conf/httpd.conf
you need to investigate what that line says

you could try reinstalling PHP
you could try removing PHP and then reinstalling
you could try installing a more recent version of PHP
you could try removing apache and then reinstalling
you could try installing XAMPP
__________________
I'd rather be riding my Versys or my Tiger 800 let alone the Norton
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On