November 29th in Linux/Unix, PHP Scripts by .

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 …

November 26th in Linux/Unix, PHP Scripts by .

CPU Exceeded Error on a New Host

i recently faced a real problem because of this. I decided to move from bluehost because my site kept receiving “cpu exceeded error” page frequently. I moved to a new dedicated server host running cpanel. I did a SCP cpanel account restore and very strangely, when i type my domain …

November 13th in Linux/Unix, PHP Scripts by .

FIX->Fatal error: Maximum execution time of 300 seconds exceeded with phpMyAdmin

PHPMyAdmin will not work for uploading large mysql databases. If you attempt to upload a large mysql dataset you will often get this error

Fatal error: Maximum execution time of 300 seconds exceeded

Fix:

If you get this error you will need edit config.default.php inside phpmyadmin and look for this line

$cfg['ExecTimeLimit'] = …

November 12th in PHP Scripts by .

Fix-> Warning: ereg_replace(): REG_BADRPT in PHP

If you are a PHP programmer and if you are using regular expressions with ereg_replace then often with replacing particular characters you might encounter error like

Warning: ereg_replace(): REG_BADRPT

Here is a simple function that causes this error

function OrigURL($str)
{
$out = ereg_replace(‘+’,’ ‘,$str);
return $out;
}

Solution: Just escape the characters. Only then it will …

November 12th in PHP Scripts by .

How to remove GET variable within $_SERVER['QUERY_STRING'] in PHP

I was working on a mysql search script with paging where i had to pass the same GET parameters to page numbers like

search.php?q=what+europe+scripts&page=1

I used $_SERVER['QUERY_STRING'] to get the GET parameters. But the problem i got was when i was in page 2 it would show query string like

search.php?q=what+europe+scripts&page=1&page=2

and if i …

October 18th in PHP Scripts by .

How to unzip ZIP files with PHP

How to automatically unzip uploaded zip files with PHP

I wanted to upload a zip file with php script and unzip it within the server running PHP and linux. How to do it? i am documenting here about a solution to unpack uploaded zip files locally within the server with PHP. …

October 2nd in General, PHP Scripts, vBulletin by .

How to Fight Spam in Vbulletin

Until recently i have encountered a sudden new attacks of spam registrations and many many spam threads posted in my forum. I just cant figure out how as I have already enabled captcha in registration page and enabled email confirmation. Despite this somehow spammers managed to bypass the registration and …

September 12th in Design, PHP Scripts by .

How to design 3 Column Website Layout with Top Navigation Menu in CSS

CSS as we go deeper and deeper it gets harder and harder to understand, especially margins, padding and floats could be confusing at times as well. I am going to post here the tutorial to make a very simple CSS website layout (skeleton) with

- Container
- Header
-Top Navigation Menu
- Left …

August 8th in Linux/Unix, PHP Scripts, vBulletin by .

Your password is 180 days old, and has therefore expired

i was getting this message from vbulletin after logging as administrator. I wasnt able to find the setting in vbulletin control panel that would disable this 180 day password, until i finally figured out.

Your password is 180 days old, and has therefore expired.

Please change your password using this page.

To fix …

August 7th in General, PHP Scripts, vBulletin by .

Where to buy good vbulletin themes?

ok, you have bought a vbulletin license and looking to customize the look of the forum. Giving a good professional look to your forum can be well worth it to attract more users to signup. If you are willing to spend $20 – $50 there are number of places …