cloksin Posted November 29, 2010 Share Posted November 29, 2010 I'm running CentOS with Apache and MySQL, I've installed PHP but it doesn't seem to be working. I've created a phpinfo.php file and placed it in the appropriate directory, but when I try to pull it up in a browser I just get plain text, its not executing. I am running on a remote server, and have no access to the desktop, so testing with localhost is not an option, it is all live on the web. My static test page for my URL is working, so I know Apache is working in regards to that. What am I missing to get PHP to function properly? Quote Link to comment https://forums.phpfreaks.com/topic/220128-trouble-with-initial-installation/ Share on other sites More sharing options...
trq Posted November 29, 2010 Share Posted November 29, 2010 I am running on a remote server, and have no access to the desktop, so testing with localhost is not an option, You can use command line browsers such as links or lynx, but its not likely to work locally and not from remotely. What am I missing to get PHP to function properly? How exactly did you go about installing php? Quote Link to comment https://forums.phpfreaks.com/topic/220128-trouble-with-initial-installation/#findComment-1140875 Share on other sites More sharing options...
PFMaBiSmAd Posted November 29, 2010 Share Posted November 29, 2010 What exactly is in your phpinfo.php page, including what the php tags are? Quote Link to comment https://forums.phpfreaks.com/topic/220128-trouble-with-initial-installation/#findComment-1140877 Share on other sites More sharing options...
cloksin Posted November 29, 2010 Author Share Posted November 29, 2010 You can use command line browsers such as links or lynx, but its not likely to work locally and not from remotely. I only mentioned this because most of what I have found online suggests testing in a browser and pointing to localhost. How exactly did you go about installing php? I grabbed the PHP_5.2.14.tar.gz file from a mirror from PHP.net and placed it on my server, then I unpacked it and ran the following commands from within the source directory. ./configure \ --with-apxs=/usr/local/apache/bin/apxs \ --disable-debug \ --enable-ftp \ --enable-inline-optimization \ --enable-magic-quotes \ --enable-mbstring \ --enable-mm=shared \ --enable-safe-mode \ --enable-track-vars \ --enable-trans-sid \ --enable-wddx=shared \ --enable-xml \ --with-dom \ --with-gd \ --with-gettext \ --with-mysql=/usr/local/mysql \ --with-regex=system \ --with-xml \ --with-zlib-dir=/usr/lib make && make install cp php.ini-dist /usr/local/lib/php.ini ln -s /usr/local/lib/php.ini /etc/php.ini What exactly is in your phpinfo.php page, including what the php tags are? This is the contents of my phpinfo.php page. <?php phpinfo(); ?> Quote Link to comment https://forums.phpfreaks.com/topic/220128-trouble-with-initial-installation/#findComment-1140883 Share on other sites More sharing options...
trq Posted November 29, 2010 Share Posted November 29, 2010 Is there a particular reason your not using CentOS's package manager to install php? Quote Link to comment https://forums.phpfreaks.com/topic/220128-trouble-with-initial-installation/#findComment-1141059 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.