htaccess tutorial

Summary In this tutorial you will find out about the .htaccess file and the power it has to improve your website. Creating a .htaccess File Alternative Index Files Custom Error Pages Stop a Directory Index From Being Shown Deny/Allow Certian IP Addresses Redirection Password Protection   Creating a .htaccess File You can create a .htaccess […]

5 Common SEO Mistakes to Avoid

Whether you’ve been optimizing your web pages for quite some time or are new to the strategy, everyone makes mistakes. While the bad news is that these mistakes can have a significant effect on your page ranking, the good news is, they’re reversible. Here are five SEO mistakes to avoid (And if you’ve already made […]

Very useful Google Search Tricks

In addition to providing easy access to billions of web pages, Google has many special features to help you to find exactly what you’re looking for. Some of our most popular features are listed below. Weather – To see the weather for many U.S. and worldwide cities, type “weather” followed by the city and state, […]

Show custom message to user from google or any other site

Welcome your users with a custom message when they come from a special site. This way, you’ll have a more interactive & personal site. Surely your user will like it & you can make your site more user friendly like give you a digg when they came from or display some related links of […]

Random Number String & Password generator function

Random Number String generator function function r($len){ $keyset = “abcdefghijklmnopqrstuvwxyz0123456789”; $randkey = “”; for ($i=0; $i<$len; $i++) { $randkey = $randkey . $keyset[mt_rand(0, strlen($keyset)-1)]; } return $randkey; } Strong Password generator function function generatePassword($length=9, $strength=0) { $vowels = ‘aeuy’; $consonants = ‘bdghjmnpqrstvz’; if ($strength & 1) { $consonants .= ‘BDGHJLMNPQRSTVWXZ’; } if ($strength & 2) […]

Display page execution time in PHP

Use this tiny code to check the execution time of your script. <?php // Write this line at the top of script $start = (float) array_sum(explode(‘ ‘,microtime())); /* your code here */ // Write these lines at the bottom of script $end = (float) array_sum(explode(‘ ‘,microtime())); echo sprintf(“%.4f”, ($end-$start)); ?> If you want to increase […]

How to hide HTTP_REFERER value from landing page

Sometimes we have to hide referer value to landing page. This is also called Link Masking or Link cloaking. Suppose we have Page A & a page B. Page A contains a link to page B. When we click on the link Page B has knowledge that from where user is coming. But if want […]

Gmail’s brand new look – What’s new

Google has luanched new look & enhanced functionality to Gmail. You will automatically get upgraded to the new look soon. If you don’t want to wait, you can switch to it today by logging into Gmail and clicking Switch to the new look. You can check the new look by clicking a link in bottom […]

Say Good Bye to Google Buzz!!!

Google is now alerting Gmail users about the impending retirement of its Buzz service. The notification in a yellow box reads, “Google Buzz is going away, but your posts are yours to keep” and directs users to a page that provides further information on how users can port their Google Buzz data. Google had, about […]

How to Find & Replace String in MySQL

To find a string in a certain field and replace it with another string: update [table_name] set [field_name] = replace([field_name],'[string_to_find]’,'[string_to_replace]’); like update user set name = replace(name,’Dr.’,’Mr.’); If you like the post & want to get more then Subscribe our blog posts. Subscribe RSS Feed • Facebook • Twitter • Email

Copyright © Sunware Technologies - Your web partner