How to Highlight PHP Source Code in WordPress Post

PHP Source Code Highlighter (syntaxhighlighter) Wordpress plugin allow you to post php code inside your wordpress post with syntax highlight and line number. The plugin preserve code formatting and do not encode character until you do manually. Supports the following languages: * C++ -- `cpp`, `c`, `c++` * C# --…continue reading →

How To Clean Special Characters From PHP String

If you are looking for the PHP special characters clean function then this post might be useful for you. This function can used to remove special character as well as able to replace specific character with other equivalent character or string. Here is detailed explanation of function: $specialCharacters Array: This array used to replace special character with other character or string. if you want to interchange (+) with (plus) then you need to specify in the array. You can add/remove array element according to your requirement. strtr function: This function used to replace other language special characters to plain English character. You can remove this line safely but ensure before that these characters not in your string and you don't need to remove them. Last 4 line used to remove other unknown unwanted special characters. [sourcecode language='php'] function just_clean($string) { // Replace other special chars $specialCharacters = array( '#' => '', '$' => '', '%' => '', '&' => '', '@' => '', '.' => '', '€' => '', '+' => '', '=' => '', '§' => '', '\\' => '', '/' => '', ); while (list($character, $replacement) = each($specialCharacters)) { $string = str_replace($character, '-' . $replacement . '-', $string); } $string = strtr($string, "ÀÁÂÃÄÅ? áâãäåÒÓÔÕÖØòóôõöøÈÉÊËèéêëÇçÌÍÎÏìíîïÙÚÛÜùúûüÿÑñ", "AAAAAAaaaaaaOOOOOOooooooEEEEeeeeCcIIIIiiiiUUUUuuuuyNn" ); // Remove all remaining other unknown characters $string = preg_replace('/[^a-zA-Z0-9\-]/', ' ', $string); $string = preg_replace('/^[\-]+/', '', $string); $string = preg_replace('/[\-]+$/', '', $string); $string = preg_replace('/[\-]{2,}/', ' ', $string); return $string; } [/sourcecode]
SECUNIA Personal Software Inspector

SECUNIA Personal Software Inspector

SECUNIA is popular security agency that expose vulnerabilities against various software and web applications. SECUNIA is managed company work dedicately for higher levels of security. Vulnerabilities published on SECUNIA either exposed by Secunia security professionals or contributed by Secunia users. A software vulnerability is basically a programming error/flaw in a…continue reading →
WordPress 406 Not Acceptable Error Fix

WordPress 406 Not Acceptable Error Fix

I just received "Not Acceptable Error while i tried to edit post in Word Press 2.5. Earlier, It was working fine but in the previous post i get annoying error when i tried to save and continue my article. But soon i realize cause of the error. Again, the error…continue reading →

No Banner, No Ads, Free CPanel Web Hosting

If you are looking for free cpanel php/mysql hosting then 000WebHost.com is ideal choice for you. 000WebHost offering features that no other web host offering in the free web hosting industry. 000WebHost providing most reliable and feature-rich web hosting service without advertising and fast website loading speed. They claim they…continue reading →