Change Class using Jquery

The power of jQuery offers many features to web developers. jQuery has addClass(), removeClass() and toggleClass() methods to change class.

//Add a class
$('#element').addClass('class_name');

//Remove a class
$('#element').removeClass('class_name');

//Remove old class and add new class
$('#element').removeClass('old_class').addClass('new_class');

//Or a short way to swap classes
$("#element").toggleClass('old_class new_class');

Read More

finding values in comma separated string using mysql

Generally, We give the various options of choices to choose on websites in form of checkbox and stores various values of choices in a column of MySQL database as a comma seperated . For example we store user’s preferred hobby in user table’s hobbies(varchar(250)) field(column). Value stored in this field may be like 1,2,5,6,1 or may be ‘sports’,’gardening’,’cooking’,’reading’.

Read More

last day of month in mysql

Sometimes we need to get the last day of the month on specific date in mysql becoz every month has different last day eg. FEB. may have 28 or 29, JAN has 31 and APR has 30.

Read More

disable fancybox after binding

I am having a strange issue, I have code that pulls content of wordpress posts that was using some plugin to bind fancybox to certain elements on the page. But now I want to implement that fancybox binding from some elements on that page.

Read More

Posts Viewed Recently

You can use Posts Viewed Recently Plugin to show the posts that are recently viewed by a visitor. This plugin supports custom post types and also provides shortcode to use the widget on any post or page.

You can know more and download this plugin via clicking the Continue Reading link given below:

Read More

Closing colorbox

Colorbox is a jQuery plugin, Nowadays jquery colorbox plugin is mostly used for displaying content in popup window. But there are still somethings where we stuck. Closing colorbox is one of them.

Read More

difference between cookie and session in PHP

Both cookies and sessions are available in any type of programming language like PHP, and both accomplish much the same task of storing data across pages on your site. However, there are differences between the two that will make each favourable in their own circumstance.

Read More

using PHP code into WordPress widget

Sometime we need to insert PHP code into Wordpress text widget but by default, Wordpress ignore PHP code into widget. People use plugin for getting this but we can achieve it by using below given code into theme’s function.php.

Read More

DAY in MySQL

DAY() in MySQL returns the day of the month for a specified date. The day returned will be within the range of 1 to 31. If the given date is ‘2013-03-13’, the function will return 13.

Read More

Author Recent Posts

Author Recent Posts Plugin shows the posts published by an author on a single post that also has written by the same author. This plugin is available with easy configurable options.

You can know more and download this plugin via clicking the Continue Reading link given below:

Read More

[ Page 24 of 27 ]