Create components for Joomla! - The example component

How to write a component for Joomla!TM 1.5 with marco's! Component maker for Joomla!


Please note: this page is not up to date!
Contents here refer to previous version of Joomla! component builder, and contents are related to Joomla! 1.5 version..


Develop components with marco's Component maker is relatively easy because the program will build all the skeleton of the component in this way the components generator allows the programmer to focus only on business logic, or over which is his main task.

In order to explain how to act on a component generated by the components generator, we are writing this series of articles that explain how to create a simple component for managing content.

YES: I know Joomla! do it by himself...

But, really, do you need another 'Hello word'?

We will use  marco's! Component maker for Joomla!, for building a quick component using table already present in a database for Joomla! 1.5: jos_sections, jos_categories and jos_content

The presence in each table, of the three fields:

  • `Id` int (11) NOT NULL auto_increment
  • `Published` tinyint (1) NOT NULL default '1 '
  • `Ordering` int (11) NOT NULL default '100 '

are not required in version past 1.5.0, but indication of a numeric primary key is still mandatory.


Now create the component, according to the instructions, and using this data suggested...

1. set up & configuration files

Download and install mysql connector from Set right version of connector in marcoComponentMaker.exe.config. At the time of writing, the latest version of the mysql connector is 6.3.5

<bindingRedirect oldVersion="" newVersion=""/>

Add/modify connections string for data base access in <connectionStrings> section.


2. run the component creator for joomla!

First step/page: keep default values and press 'Next Step'


3. select db & tables

  1. select your db from drop down select and press 'Select Server'
  2. check these tables:
    • jos_sections
    • jos_categories
    • jos_content
  3. press 'Next Step'


4. configure fields

4.1 jos_sections

Select the jos_sections tab and edit the following fields:

  • title: set the 'Get Field Data' check box
  • description: select 'RTE' from 'Render As' drop down


4.2 jos_categories

Select the jos_categories tab and edit the following fields:

  • title: set the 'Get Field Data' check box
  • description: select 'RTE' from 'Render As' drop down


Please pay attention!
'Get Field Data' doesn't check if method name is valid. so if you select the field 'name' will be generated the getName() method overriding the  JModel->getName(). In doubt add a suffix to auto-generated method!


4.3 jos_content

Select the jos_content tab and edit the following fields:

  • introtext: select 'RTE' from 'Render As' drop down
  • fulltext: select 'RTE' from 'Render As' drop down
  • sectionid: select 'Select List' from 'Render As' drop down
  • catid: select 'Select List' from 'Render As' drop down
  • access: select 'Select List' from 'Render As' drop down

Press 'Next Step' twice and 'End Work'. The component in now ready to install (it is in com_mcm sub folder): install it!

Now you are ready to follow instructions for use profitably marco's Component maker in your work.

Manage the back end article

Manage the front end article


+2 #9 Guest 2013-08-21 09:29
Thanks for the complete information regarding to create components for joomla ,exactly am searching for the same info.
screenshots and the stepwise instruction guided me to know about this concept.
I refer to visit this website for joomla extensions:joom la scheduling extension
+2 #8 Guest 2013-02-02 07:23
hi, i have followed every step indicated but at step 2 when i selected the localhost server there are no tables to display. can you help? thanke you and here is the configuration i used:
my server is xampp 1.7.3!

did you change the configuration file as shown in step 2?

-3 #7 Guest 2012-07-18 05:10
I searching for the joomla component but here i got the complete info about that. this enough info for that.
-3 #6 Guest 2012-06-22 04:23
I am trying to find the pedigree componet for Joomla would you know where the link is?
-7 #5 Hassan 2011-10-30 13:26

I am trying to make this working since past few hours. I have downloaded and tried different mysql drivers. But i am unable to make it work. I am using Xampp version 1.6.8 and mysql-connector -net-6.2.5.msi at the moment. And here is my marcoComponentMaker.exe.config


hi Hassan,
if you want to submit code you should use the email at the end of the download page. for security reasons html/js/xml code is stripped out from comments.

anyway I suppose you forgot to update the bindingRedirect directive (see download page).

-3 #4 Sloan 2011-10-20 05:15
Never mind. I read the info in the file that was of the download -- it had the right download link for the MySQL connector

Sorry 'bout that!! >> blush
-2 #3 Sloan 2011-10-19 22:02

I'm having a bit of trouble connecting to the DB. I can get to it using phpAdmin, but when I start MCM, and on the 2nd form, I select the DB and click on the Select Server button, I get an error message:

System.IO.FileNotFoundException: Could not load file or assembly 'MySql.Data, Version= , Culture=neutral , PublicKeyToken= c5687fc88969c44 d' or one of its dependencies. The system cannot find the file specified.
File name: 'MySql.Data, Version= , Culture=neutral , PublicKeyToken= c5687fc88969c44 d'
at JoomlaComponentBuilder.joomlaComponentBui

I went to the link to get the MySQL connector, and downloaded the ODBC one. The PHP native didn't seem approriate.
Should I change the to something else like MySQL.odbc or similar?
I'm running XAMPP under window 7.

+1 #2 Guest 2010-04-11 19:56
Are known limitations, but I found acceptable for early versions of the program. in the future ...
0 #1 Guest 2010-04-10 14:05
The program is nice, but it fails with tables which primary key is not the default 'id', for example, 'id_brand'.

Moreover, the columns publish and order are somehow not really usefull in all components.

Aggiungi commento

Please note: URL in text are not linked and site address is only for internal use.

Comments are human checked. All spam will be removed, so don't waste your time!

Codice di sicurezza

L'estate si avvicina hai già trovato l'albergo per le vacanze? cerca un albergo al mare o un hotel in montagna ove trascorrere le tue vacanze.