November 29th in Linux/Unix, PHP Scripts by pbu .
Fix -> PHP files are downloading when viewed in Browser
i had a sudden wierd problem with my site running cpanel. when ever i click on the link in my website, the browser shows a download box for the php file instead of showing a webpage. I did use mod rewrite to make url friendly
How to Fix
I figured out later the problem is apache doesnt know to parse those files with php. You you have to create a file .htaccess in your site public_html folder and place the following line to fix the problem
AddHandler application/x-httpd-php .php .phtml
Then try to browse your site and soon the apache wont show the dialog box.
Similar Posts:
- how to change default homepage with htaccess?
- Implementing Secure File Upload in PHP
- Using htaccess to redirect domain without http://
- Affiliate Hide v1.0 – Free WordPress plugin to Hide & Redirect Affiliate Links
- How to unzip ZIP files with PHP
- Enabling ModRewrite in XAMPP Apache
- Implementing Secure File Upload in PHP
- How to post source code in WordPress posts?
- Easy way to setup CRON jobs in CPanel without Email output
- How to install a local copy and configure WordPress on Ubuntu


January 17, 2009
There are complete LAMP, WAMP Packages available like XAMPP, WAMP, EasyPHP. This helps us reducing the configuration time. Pls chk http://kathyravan.blogspot.com/2008/11/lamp-samp-wamp-apache-mysql-php-xampp.html for more information