How to write stylesheets specifically for Internet Explorer

At different stages of development, we might have come across style issues associated with IE. It was always a problem for most of the HTML developers. How can we solve that issue, without causing problem in other browsers. The only way to do is, write stylesheets specifically for IE. We are ha... Read more

How can we count the likes of a facebook page using PHP code

We can easily count the likes of a facebook page. The only thing that we need to know is the page id of the facebook page. If you know the page id of the facebook page, then simply use the following code:

    funct... Read more

Responsiveness working in desktop browsers but not in mobile

Some of you might have came across a scenario like this. Your site may be responsive in browser but it will not be responsive a mobile devices. The website will behave as responsive when you minimize your desktop browsers. Why this happens? This is because you are missing some metaRead more

What does the term comes after question mark mean in the src attribute for Javascript

We might have noticed that while javascripts are included into an HTML, in the src attribute there might be portion towards the end which is separated by a question mark. For eg:  <script type="text/javascript" src="./js/score.js?r... Read more

How can we override third party CSS properties within our CSS file

In order to override third party CSS properties, we can make use of !important. Even though using !important is not encouraged, that is the only way to override the style using CSS.

eg: #name { col... Read more

How to center a div without specifying width

We can center a div without specifying width by using the following steps:

1) Put a wrapper div to the div which you are about to make centered.

2) Give the style text-align :center to the... Read more

Add and Substract operations of time using Javascript

The following is a working example for add and substract operations of time using Javascript. In the code what I have did is, accepted time input from the user and result is shown in a textbox. The date field has been kept as a constant here. Try the following code to see the working.

... Read more

Adding number of days to current date in Javascript dynamically

Here what we are doing is: Setting curent date to a textbox and making it readonly. Then we allow user to enter the number of days to be added to the current date. On change event, the number of  days entered is added to the current date. Try out the following code to see its working.

... Read more

How to get posts from a wordpress site to other sites hosted in same server

Try the following code:

    $db_username = '#######';
    $db_password = '#######';
    $db_database = '#######';
    $host =        '#######';

  ... Read more

How to hide database debug errors in CodeIgniter

There is a simple method to hide database errors in CodeIgniter. If such errors are diplayed, it may reveal the table name, field name etc of your database, which cause threat to your security. In order to hide such errors:
1)  Go to ROOT FOLDER/application/config/database.php
... Read more

 < 1 2 3 >