Author name: Yang Yang

Hello, I'm Yang. I build online businesses that please people. Want to join in and post some useful articles on Kavoir.com? Shoot me a message.

Remove Gmail via Field and Add mailed-by & signed-by with PHP mail()

PHP mail() is a great function to easily send emails from your website server. If you have ever used it before in action, or are currently using mail() to send out emails from your website or application, chances are you would find Gmail to be very persistent in attaching a ‘via’ field to the from …

Remove Gmail via Field and Add mailed-by & signed-by with PHP mail() Read More »

Disable Source > Format (Ctrl + Shift + F) in Zend Eclipse PDT

It became a total mess when I selected the entire root directory of my project and accidentally clicked Source > Format in Zend Eclipse PDT. All the files were instantly re-formatted and saved in a manner I wasn’t comfortable with and there didn’t seem any easy way to undo these changes that had been applied …

Disable Source > Format (Ctrl + Shift + F) in Zend Eclipse PDT Read More »

PHP: Round to the Nearest 0.5 (1.0, 1.5, 2.0, 2.5, etc.)

The common practice of rounding, namely the round() function in PHP, is to round to the nearest decimal point, that is, 1.0, 2.0, 3.0, etc. or, 10, 20, 30, etc. For example, echo round(4.25, 0); // 4 echo round(3.1415926, 2); // 3.14 echo round(299792, -3); // 300000 When I’m trying to aggregate all the customer …

PHP: Round to the Nearest 0.5 (1.0, 1.5, 2.0, 2.5, etc.) Read More »

Change array() indentation and wrapped line indentation in Eclipse for PHP Developers

The default array() indentation of Eclipse for PHP Developers when you create an array seems to be 2 tabs which I think are too much. To reduce it to just 1 tab: Window => Preferences => PHP => Editor => Typing => formatter preference page => Edit… => Indentation => Default indentation of array initializers Or Window => …

Change array() indentation and wrapped line indentation in Eclipse for PHP Developers Read More »

500 Internet Server Error for Incorrect Permissions after Installing suPHP and Uploading PHP Script

Many’s the time after you have uploaded some PHP script to your server and point the web browser to the address it gives 500 Internet Server Error. If you have suPHP installed this is very likely because the uploaded PHP script (files and directories) have wrong permissions set to them. With regards to Linux permissions, …

500 Internet Server Error for Incorrect Permissions after Installing suPHP and Uploading PHP Script Read More »

vBulletin: Paid Subscription Not Showing Up

I was trying to start a premium membership for Kavoir Backyard and after I have created a Paid Subscription profile, nothing shows up in user control panel nor at /backyard/payments.php. As you can see from the thread I started in the official vBulletin forum for help, I have done everything necessary to create the subscription …

vBulletin: Paid Subscription Not Showing Up Read More »

Make Firefox to Not Send HTTP Referer (or On a Per-Site Basis)

By default browsers such as Firefox sends the Referer information to the target URL in the HTTP header, as defined by HTTP protocol, so the destination URL / website knows where you have come from. For instance, when you click this link to one of my friends’ sites, it would know you have arrived at …

Make Firefox to Not Send HTTP Referer (or On a Per-Site Basis) Read More »

MySQL: Incorrect key file error AND InnoDB: Error: unable to create temporary file; errno: 2

When I encounter the incorrect key file for table error, it’s almost certainly because the disk is full and MySQL can’t write to the tmpdir. The solution is simple, just move tmpdir to another partition with enough disk space. Open my.ini and change tmpdir to another directory with enough disk space. Restart MySQL and that …

MySQL: Incorrect key file error AND InnoDB: Error: unable to create temporary file; errno: 2 Read More »

Make phpMyAdmin Show Exact Number of Records for InnoDB Tables

By default, phpMyAdmin shows an estimated number of records for InnoDB tables that have more than 20,000 rows. It can vary by every fresh as much as 50% or even more. Makes it hard to get an exact number of records for the tables as we have to explicitly run an SQL query to do …

Make phpMyAdmin Show Exact Number of Records for InnoDB Tables Read More »

Amazing Science – Photons and Optical Fiber Cable

Today, most of our online data transmissions pass through fiber-optic cables. And as most of us know, fiber-optic cables are simply long, thin strands of glass which allow light to bounce and refract from one-end to the other without leaving the cable. It’s a bit like shining a flashlight down a long, mirrored tube. One …

Amazing Science – Photons and Optical Fiber Cable Read More »

How to Free C:\ Drive Disk Space in Windows 7 and Reduce System Size?

Windows 7 is a beast in consuming hard drive disk spaces, especially the system drive, C, which is constantly being filled up. After a while it will keep annoying you with low disk space warnings because C drive is running out of space and almost full. So how can I safely free up all the …

How to Free C:\ Drive Disk Space in Windows 7 and Reduce System Size? Read More »

New LHC Data Hints Strongly at Higgs Boson

What gives matter mass? This seemingly simple question has had physicists around the world working to detect and identify the Higgs boson, known in popular media as the “God particle,” the physical constituent that has long been thought to interact with other forms of matter, giving it mass. The search has lasted since 1964, the …

New LHC Data Hints Strongly at Higgs Boson Read More »

Register.com Scam Review – Considering Them? Stop!

Update: After some communications with Register.com, I was able to acquire the transfer authorization code via their live chat support. For people who are considering Register.com, I’ve got something new. Well probably not new but I just found it out myself the hard way how Register.com is a SCAM. Sneaky Pricing at Register.com I registered a .com …

Register.com Scam Review – Considering Them? Stop! Read More »

Scroll to Top