Archive

Author Archive

Find the number of child elements using jQuery

November 24th, 2011 No comments

Hi guys, sometimes we may need to count the number of elements under a particular element. jQuery helps us to find the number of elements very easily, consider the following HTML

Read more…

Categories: jQuery Tags:

How to override module layout in joomla

November 10th, 2011 No comments

Joomla is a popular CMS application, now I am using Joomla 1.7.  A lot of modules are available to download and each module has its own layout. Sometimes we may need to override the existing layout of a module. In order to override a module’s layout, we don’t need to update the module’s own layout files, instead we can create our own layout files to override the existing layout.

Read more…

Categories: Joomla, PHP Tags:

URL shortening using PHP

October 31st, 2011 No comments

to.ly and tinyurl.com are the most wanted URL shortening service providers. We can make urls short from their sites also we can use their services through PHP code.

Read more…

Categories: PHP Tags:

Connect to an external database from a Joomla extension

October 28th, 2011 No comments

Hello guys, sometimes we may need to connect to an external database from a custom made joomla extension. It is possible to connect to an external database with the help of JDatabase class. The following sample function connects to an external database and execute a query in the database and returns the result

Read more…

Categories: Joomla, PHP Tags:

Directory indexing options using .htaccess file

October 27th, 2011 No comments

Hi guys, in this post I am trying to describe various directory indexing options available through an htaccess file.

htaccess stands for “Hypertext Access” and according to Apache .htaccess files (or “distributed configuration files”) provide a way to make configuration changes on a per-directory basis. A file, containing one or more configuration directives, is placed in a particular directory, and the directives apply to that directory, and all subdirectories thereof.

Read more…

Categories: htaccess Tags:

Joomla – How printing $app object in index.php display the whole site contents

September 20th, 2011 No comments

Joomla is the most wanted CMS application I have ever seen. Currently I am using Joomla 1.6.  If you notice the index.php located at the root of joomla installation, you can see an object $app playing an important role in making the site contents. $app is an object of the class Jsite, class Jsite is defined in /includes/application.php. The class Jsite is extended from the class JApplication which is defined in libraries/joomla/application/application.php. Object $app calling several methods and finally print out the entire contents by the code echo $app; Its understood that an object cant print out any contents just by an echo statement. then how the code echo $app prints out the entire site contents ? here is the magic of the magic method __toString()Read more…

Categories: Joomla, PHP Tags: