Open Source

Introducing jSlider: A Content Slider plugin for JQuery

Posted on

jSlider is a light weight JQuery plugin for content sliding. By content we mean everything: HTML code, Images, Advertisements etc etc. jSlider allows to put our content in simple <div>‘s, and then it automatically generates a content slider for you, which one can customize using various options provided. Screenshot Below is a screen shot of a content slider using jSlider: Download and Demo jSlider is hosted at google code. Use the following links for demo and downloads: Download the source code. Click for a demo of jSlider Using jslider.jquery.js Below is a sample html code which will be processed by […]

PHP

Building a Custom PHP Framework with a custom template caching engine using Output Control functions

Posted on

In past 1 year or so, I had opportunities of using a lot of php frameworks including zend, symfony, cakephp, codeigniter. All frameworks have their pros and cons, however that is out of scope of this blog post. You may want to checkout this comparison list of php frameworks here. In this blog post I will build a custom PHP framework (MVC Architecture). Then go on to discuss in brief about the output control functions and finally show how to build a custom template caching engine using these functions for our framework. Source Code You may want to download the […]

Web Development

fixed.js – Solution to IE6 “position:fixed” Bug

Posted on

IE6 has been a bane for all frontend developers for years. An element can be positioned relative to the browser window using the style position:fixed, it does not move when the page is scrolled. You can do nice layout things (e.g. facebook chat bar) with this in most modern browsers but not for IE6 in windows until you use fixed.js Sample Code for Facebook Type Chat Bar <html> <head> <style type=”text/css”> body { margin:0px; padding:0px; height:1600px; position:relative; } #shoutbox { position:fixed; background-color:#F2F2F2; border-top:1px solid #CCCCCC; bottom:0px; left:0px; width:100%; height:25px; } </style> <script type=”text/javascript” src=”fixed.js”></script> </head> <body> <div id=”shoutbox”> <!– Our […]

WordPress

How to generate random password like WordPress using PHP?

Posted on

WordPress Blogging Engine is a champion in a lot of way. One of the unique thing which you might have noticed is the random password generated by the wordpress, in case you try to generate a new password. Here are a few examples: j0LH(WM9b_-q wr^sqct1cmff )P4-e531#-aL Lets have a look at the code which can generate such random passwords for us. Later on we will dig deep into the code to understand each and every bit of it: <?php class utility { static $random = ”; // generates a random password // By default of length 12 having special characters […]

Web Development

Getting started with Autotools – GNU Build System on Debian

Posted on

If you eat and drink open source, chances are high that you might have downloaded an open source project code, only to see files like: aclocal.m4, configure.ac, Makefile.am, Makefile.in and what not. You might have also used commands like ./configure, make etc but what are these files? Does they really belong to the project you download? Do I need to understand them? In this blog post I look forward to answer all your question, as well as introduce you to not so popular Autotools – A GNU Build System. Setting up Autotools on Debian? Before we go ahead and understand […]