All posts in PHP

Support multiple languages in php

If your website has an international audience, it’s important that you also have a plan for how to support the multiple languages that your users might speak. Depending on how big a part of your site that needs to support multiple languages, different strategies can be suitable.

In this post you’ll learn how to make your php site support multiple languages.

Read more…

Share and Enjoy

  • Facebook
  • Twitter
  • Delicious
  • LinkedIn
  • StumbleUpon
  • Add to favorites
  • Email
  • RSS

Create your own fulltext searchengine with PHP and MySQL

Do you want to search the text stored in your MySQL database, but hasn’t figured out how to do it efficiently? Then a  full-text search engine is the perfect solution for you. From version 4.0 MySQL has been supporting full-text search, which makes it very easy to build a good performing, robust and very accurate search engine.

In this post you’ll learn how to build a basic full-text search engine using PHP and MySQL.
Read more…

Share and Enjoy

  • Facebook
  • Twitter
  • Delicious
  • LinkedIn
  • StumbleUpon
  • Add to favorites
  • Email
  • RSS

Post to Twitter from PHP script

Twitter is a great platform for publishing news, and interacting with your users. However publishing content on multiple platforms can be very time consuming unless you have some tools for optimizing the workflows.

In this post you’ll learn how to create a php script that can automatically publish  your website content on Twitter, and automatically optimizes content within the 140 character limit per Twitter post.

Important update! – Twitter don’t support http authentication anymore, which makes this script obsolete. See the new OAuth Post to Twitter script here

Read more…

Share and Enjoy

  • Facebook
  • Twitter
  • Delicious
  • LinkedIn
  • StumbleUpon
  • Add to favorites
  • Email
  • RSS

Tips for adding website thumbnails to your site

Adding website thumbnails on your website, can make your website stand out from the crowd and give your users the advantage of getting a sneak preview of other websites before the user has even clicked on the link, which typically results in more clickthroughs.

In this post you will get links some of the different services that delivers thumbnail services, and tips to the integration on your php based site.

Read more…

Share and Enjoy

  • Facebook
  • Twitter
  • Delicious
  • LinkedIn
  • StumbleUpon
  • Add to favorites
  • Email
  • RSS

Faster Google Analytics

Google Analytics is a great tool for getting detailed insights on user behavior and traffic on your site.  Normally the standard implementation from Google Analytics works fine but if you’re looking for opportunities for optimizing site speed, the possibility to store the Google Analytics javascript file locally might be something to consider. The main  benefit of hosting the javascript file locally is one less external dependency, and often faster download times.

Read more…

Share and Enjoy

  • Facebook
  • Twitter
  • Delicious
  • LinkedIn
  • StumbleUpon
  • Add to favorites
  • Email
  • RSS

Adding special characters to MySQL

When you’re adding data to MySQL, you might experience that MySQL sometimes gives a SQL error in a code that normally works fine.

Typically this is caused by special characters like ‘ ” % in the new data, that conflicts with the SQL used to insert the data into the database. This post gives you some useful tips for handling this situation.

Read more…

Share and Enjoy

  • Facebook
  • Twitter
  • Delicious
  • LinkedIn
  • StumbleUpon
  • Add to favorites
  • Email
  • RSS