Wednesday, December 28, 2011

Creating Preload Images with jQuery in WordPress


Creating Preload Images with jQuery in WordPress
Marvin



This is a lightweight and user-friendly jQuery tutorials plugin that makes page loading faster. DynamicWP.net (http://www.dynamicwp.net/) PR and editor Eko Setiawan created it exclusively for WordPress’s TwentyTen Theme (http://wordpress.org/extend/themes/twentyten).
Check out this plugin’s demo here:
This tutorial will teach us how to preload images with jQuery.
Step 1:

Step 2:
Upload the loading image folder you have just downloaded to the themes file.
Step 3:
This code should be on your file header.php of your TwentyTen Theme as it serves to call the jQuery function.
<?php wp_enqueue_script('jquery'); ?>


Step 4:

Below the wp_head(); insert this jQuery preload function


<script type="text/javascript">
 
               jQuery(function () {
                       jQuery('.post-thumbnail-title img').hide(); //hide all the images on the page
               });
 
               var i = 0; //initialize
               var int=0; //Internet Explorer Fix
               jQuery(window).bind("load", function() { //The load event will only fire if the entire page or document is fully loaded
                       var int = setInterval("doThis(i)",500); //500 is the fade in speed in milliseconds
               });
 
               function doThis() {
                       var imgs = jQuery('.post-thumbnail-title img').length; //count the number of images on the page
                       if (i >= imgs) { //Loop the images
                               clearInterval(int); //When it reaches the last image the loop ends
                       }
                       jQuery('img:hidden').eq(0).fadeIn(500); //fades in the hidden images one by one
                       i++; //add 1 to the count
               }
</script>
                      

Step 5:        

For styling the CSS, open the style.css and add this below on class .post-thumbnail-title

background: url(images/loading.gif) no-repeat 50% 50% scroll transparent;
 
 
It should look like this:
 
.post-thumbnail-title {
        border: 1px solid #ccc;
        height: 150px;
        padding: 4px;
        width: 600px;
        position: relative;
        background: url(images/loading.gif) no-repeat 50% 50% scroll transparent;
        }

Monday, December 26, 2011

Plax - Parallax Effect Plugin For jQuery | blogfreakz.com

Plax - Parallax Effect Plugin For jQuery | blogfreakz.com

Plax is a jQuery plugin that makes it super easy to parallax elements in your site based on mouse position. You can see it implemented in many places throughout GitHub, including the 404 page, the 500 page, and the about page.

7 jQuery Plugins For A More Eye-Catching Website


7 jQuery Plugins For A More Eye-Catching Website
by: Keith

Here are 7 cool jQuery tutorials plugins for event management, animation and Ajax interactions that will surely turn your website into eye-candy. Enjoy trying out their demo!

1.       Ninja UI – This plugin is one big pack of web interface:  it has buttons, icons, tooltips, sliders, and more!  As everyone keeps saying about Ninja UI, its design is beautiful, efficient and unobtrusive. 


2.       Mobiscroll – Here’s a jQuery plugin that’s optimized for touchscreen devices. Perfect as a date picker, it can also be used for any other values (including images!). It is also a great alternative for dropdown list.



3.       Elycharts - A pure Javascript charting library, it is easy to use and completely customizable. It helps you create good-looking interactive charts with a lot of useful features such as legend and label support, mouse tracking, tooltips, and animations. It doesn’t require any client side plugins like Flash or Java. It runs on the client browsers so you don’t need to install anything on your server.



4.       Timelinr - This plugin helps give more life to boring timelines. It supports horizontal and vertical layouts, and you can specify parameters for most attributes like speed, transparency, etc.



5.       jQuery.fracs – This is an impressive jQuery plugin that helps determine the visible fractions of an element that is currently in the viewport. It lets users jump to different sections of a website easier so it's suitable for one-page websites.



6.       Blueberry -  This is a simple and fluid jQuery image slider plugin which was written specifically to work with responsive web layouts. Try out the demo to see and appreciate how well it lets the page adapt to the current window size.


7.       PikaChoose – this is a very lightweight jQuery slideshow plugin with lots of features. It integrates smoothly with jCarousel and has API hooks for lightbox and Fancybox integration too.


Indent Text Using Tab Key In Text Area With jQuery


Indent Text Using Tab Key In Text Area With jQuery
Keith

Have you ever had one of those times when you just wish that you could just use the Tab key to indent your text instead of having it move your cursor onto the next form element? Well, now you won't have to worry about it because this jQuery tutorials snippet will fix that.

<!DOCTYPE html>
<html>
<head>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.2/jquery.min.js"></script>
</head>
<body>

<script language="javascript">
$(document).ready(function(e) {

  // Using the <TAB>
  $('textarea.tab').keydown(function(e) {
    if(e.keyCode == 9) {
      var start = $(this).get(0).selectionStart;
      $(this).val($(this).val().substring(0, start) + "\t" + $(this).val().substring($(this).get(0).selectionEnd));
      $(this).get(0).selectionStart = $(this).get(0).selectionEnd = start + 1;
      return false;
    }
  });

  // Using Spaces
  $('textarea.space').keydown(function(e) {
    if(e.keyCode == 9) {
      var start = $(this).get(0).selectionStart;
      $(this).val($(this).val().substring(0, start) + "    " + $(this).val().substring($(this).get(0).selectionEnd));
      $(this).get(0).selectionStart = $(this).get(0).selectionEnd = start + 4;
      return false;
    }
  });
});
</script>

<h5>Using the &lt;TAB&gt;</h5>
<textarea cols="40" rows="10" class="tab"></textarea>
<h5>Using Spaces</h5>
<textarea cols="40" rows="10" class="space"></textarea>

</body>
</html>

============
KEITH FRIAS sees himself as an artist whose talent is in a state of coma, and a tech gadget freak who also loves to dabble in photography.

jQuery Falling Leaves Plugin for WordPress


jQuery Falling Leaves Plugin for WordPress
by: Marvin



Here's the jQuery tutorials plugins are wonderful tools to use for one’s web site, so I’m going to share to you a cool free plugin created by the web developers at PremiumCoding (http://premiumcoding.com). The Falling Leaves plugin for WordPress is a full-screen animation of leaves falling from the top area of your site. It has three available types, which you can see these on the preview links below. You can easily customize it by altering the animation parameters within the javascript file, such as the leaf type, number, size, its rotation, and falling speed.


How to Install:

1. Download the file here: http://premiumcoding.com/wp-content/plugins/download-monitor/download.php?id=107  
2. Unzip the files and look for wp-leaves.zip file. 
          3. Go to your WordPress admin panel then select ‘Plugins’.
      4. Click ‘Add new’ button and on the next page, click upload.
      5. Browse for the zip file you have unzipped (step 2) and click ‘Install now’
6. Activate the plugin.
      7. The settings for the plugin is found under the main settings of WordPress named WP-leaves.

Editing:                                

      For width and height, set your desired width and height of your banner.
      For number of leaves, set how many leaves you want them to appear on your banner.
      For type of animation, you can set it to 2D.

Note: If you want to use this in your post or page use following Shortcode, remove apostrophes when you use it.

 ["leaves id=1 custom=1 width=570 height=280 upload_image=http://yourdomain.com/image.jpg number_leaves=40 rotationtype=2D"]

10 jQuery Slider Tutorials


10 jQuery Slider Tutorials         
Marvin
As an essential web development tool, jQuery tutorials is used in creating a wide range of apps, plugins, and programs designed to help maximize your website. When used in sliders, jQuery helps produce a lightweight yet extensive and highly useful application.

Here are 10 tutorial sites I’ve gathered on how to create awesome jQuery sliders which you can integrate in your WordPress blog.

TN3 Gallery

This great slideshow is compatible with all modern desktop and mobile browsers. It is highly customizable and has multiple effects and transitions, full-screen and slideshow options, CSS skinning, and more.



Mosaic Slideshow

This Mosaic slideshow tutorial shows you how to make a jQuery mosaic gallery, with a tile transition effect when you move the images from one slide to another.


http://tutorialzine.com/2010/03/mosaic-slideshow-jquery-css/

Elastic Image Slideshow with Thumbnail Preview                  

This tutorial will teach you how to create an elastic slideshow with thumbnail preview. The slideshow automatically adjusts to its container, where you can navigate through the slides with the autoplay option.
 


http://tympanus.net/Tutorials/ElasticSlideshow/


Rotating Slideshow                       

This tutorial shows us how to use jQuery and CSS rotations that could spice up your pages with featured content.





MopSlider Content Slider

This MopSlider plugin is generated with PHP, and as a data source for the configurations, we are going to use plain txt file. Icons used on this tutorial are from tonev.deviantart.com.



http://tutorialzine.com/2009/10/slick-content-slider-jquery/

Apple-Style Slideshow Gallery

Learn how to create an Apple-style slideshow gallery, with the same effect that Apple uses to display their products on their website. It is entirely front-end based and no database or PHP required.




http://tutorialzine.com/2009/11/beautiful-apple-gallery-slideshow/

Automatic Image Slider

This tutorial shows how to create simple widgets such as this image slider using HTML/CSS/Javascript. Because it’s based on HTML, it allows you to incorporate SEO into your website and adjusts accordingly to sites without Javascript.





                            
Minimalist jQuery slider 

This is a step-by-step tutorial on how you can create this jQuery slider with image description and name.





Panning Slideshow with jQuery                          

In this tutorial, you’ll make a slideshow with a twist, using a different type of transition to animate between sliding effects. 

                                                                 


Basic Slideshow with Transparent PNG Frame

This tutorial is for those who are relatively inexperienced because it shows you the basics, and focuses more on working with layered PNG’s in web layouts.



http://buildinternet.com/2009/06/how-to-make-a-slideshow-with-a-transparent-png-frame/