<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://docs.sandbox.joomla.org/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Nenomaz</id>
	<title>Joomla! Documentation - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://docs.sandbox.joomla.org/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Nenomaz"/>
	<link rel="alternate" type="text/html" href="https://docs.sandbox.joomla.org/Special:Contributions/Nenomaz"/>
	<updated>2026-05-25T03:26:03Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.43.0</generator>
	<entry>
		<id>https://docs.sandbox.joomla.org/index.php?title=User_talk:Scionescire&amp;diff=160197</id>
		<title>User talk:Scionescire</title>
		<link rel="alternate" type="text/html" href="https://docs.sandbox.joomla.org/index.php?title=User_talk:Scionescire&amp;diff=160197"/>
		<updated>2015-02-25T15:26:01Z</updated>

		<summary type="html">&lt;p&gt;Nenomaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Hello!==&lt;br /&gt;
Why you have undone statements added by me in the two lessons of &amp;quot;Adding a Model to the site part&amp;quot; and &amp;quot;Adding a view&amp;quot; in the Component Development Tutorial? --[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 04:48, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Hello!! ==&lt;br /&gt;
&lt;br /&gt;
Which statements are you talking about?&lt;br /&gt;
&lt;br /&gt;
I updated the guide parts 1 to 11 following the github updated code from the lesson 10 step.&lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 05:01, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Contribution==&lt;br /&gt;
If you watch the history of these two lessons:&lt;br /&gt;
*[[J3.x:Developing a MVC Component/Adding a model to the site part]]&lt;br /&gt;
*[[J3.x:Developing a MVC Component/Adding a view to the site part]]&lt;br /&gt;
You can see my recent contribution, I had added some content important for make &amp;quot;View and Model&amp;quot; work in a component that before there wasn&#039;t... --[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 05:38, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Hello world meets coding standards ==&lt;br /&gt;
I haven&#039;t noticed your contribution before, sorry!&lt;br /&gt;
&lt;br /&gt;
I have followed the step-10 lesson github code.&lt;br /&gt;
That code removed some ininfluent parts, probably they were good for the 2.5 version of Joomla but not for the 3.x one.&lt;br /&gt;
I&#039;ve personally tested the whole code so I&#039;m sure that the parts I&#039;ve removed are irrilevant (e.g. some jimports, that in 3.x are automatically done).&lt;br /&gt;
&lt;br /&gt;
Once I&#039;ve updated the github code from 10 to 1 to follow that standard, I updated the guide too (that was quite a fast part, so that&#039;s why I missed other contributions).&lt;br /&gt;
&lt;br /&gt;
Hope it&#039;s clear now, but if it&#039;s not, don&#039;t esitate to ask ;)&lt;br /&gt;
&lt;br /&gt;
P.S. If I&#039;m correct, and you are italian too, we can answer in our language =D &lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 05:57, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Github code?==&lt;br /&gt;
&lt;br /&gt;
Could you explain me what is &amp;quot;github code&amp;quot;? I think GitHub is a server to share code, not wiki content.. but I don&#039;t know Joomla Policies... could you explain these to me?&lt;br /&gt;
&lt;br /&gt;
P.S. Si sono italiano :-) cerco di usare l&#039;inglese perchè voglio impararlo ;-)&lt;br /&gt;
&lt;br /&gt;
== Yes, github! ==&lt;br /&gt;
&lt;br /&gt;
Yes, github is exactly what you know, a server to share code!&lt;br /&gt;
But, as you know, its code can be forked, so you can provide corrections, improvements and so on, and that&#039;s what happened.&lt;br /&gt;
Someone corrected the code (that was the same as the wiki), but not the wiki, so the updated and correct version was only in the github code.&lt;br /&gt;
While revisiting it (I&#039;m trying to understand how to develop a 3.x Joomla MVC component) I stumbled upon that version so I decided to update the wiki too.&lt;br /&gt;
&lt;br /&gt;
As for now I&#039;m trying to update step 12 ;)&lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 12:06, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Sorry==&lt;br /&gt;
&lt;br /&gt;
Sorry but I&#039;m not able to understand this method of track the wiki development through GitHub... However, I will reinsert the content I&#039;d added before, I hope you help me to understand this approach of using github for the wiki by the Joomla Community.&lt;br /&gt;
--[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 04:23, 16 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Github ==&lt;br /&gt;
&lt;br /&gt;
The Joomla Wiki about the MVC in version 3.x was more like a copy of the one for the 2.5 version.&lt;br /&gt;
In fact some code was redundant or unnecessary.&lt;br /&gt;
For example a lot of jimport listed in the 2.5 guide are now automatically done in the 3.x one, so there is the need to remove them from the code.&lt;br /&gt;
Same thing for the overloading of the display method you posted.&lt;br /&gt;
If you notice the code works both ways, with and without the declaration of the display method (I guess those lines are now done by default following an exact name pattern (eg. HelloWorldMODEL, HelloWorldCONTROLLER, so if you are in a HelloWorld class and you need its controller the program will search for NAME+CONTROLLER thing.&lt;br /&gt;
&lt;br /&gt;
Hence in github someone with a more knowledge about the new version standars cleaned up the code.&lt;br /&gt;
&lt;br /&gt;
For this reason I followed those hints and rewrited the code in the guide to follow those standards. ;)&lt;br /&gt;
&lt;br /&gt;
P.S. I reverted your change ;)&lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 09:09, 16 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Sure?==&lt;br /&gt;
Meanwhile I needed to put those statements in the display method of the controller to trigger the view... because before didn&#039;t work!&lt;br /&gt;
I think this manner of explain developers the joomla framework is wrong, also keeping track of the wiki through GitHub is wrong... --[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 09:38, 16 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Sure! ==&lt;br /&gt;
&lt;br /&gt;
I tested each part of the guide I updated and it&#039;s working (I don&#039;t think the guy accepted the merge on github would rather accept it either).&lt;br /&gt;
Maybe some mispelled names or missing files?&lt;br /&gt;
Sometimes some lines missing from the main xml could give a really bad headache ;)&lt;br /&gt;
&lt;br /&gt;
I used github as a &#039;source&#039; but other than testing, I searched for the reasons of the editing, so I&#039;m pretty sure that code is good enough to be on the wiki =D&lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 10:08, 16 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Main xml ==&lt;br /&gt;
Could you give me some guidelines about the main xml? Thanks in advance!&lt;br /&gt;
--[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 04:53, 18 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Main ==&lt;br /&gt;
&lt;br /&gt;
Are you following the J3.x Guide?&lt;br /&gt;
&lt;br /&gt;
If you are following that guide you can use programs (on Windows I use &#039;&#039;Diffuse&#039;&#039;) or online tools (https://www.diffchecker.com) to compare the files you have with the new inserted to discover the changes.&lt;br /&gt;
&lt;br /&gt;
Sometimes I found myself in trouble because I have forgotten to update the helloworld.xml xD&lt;br /&gt;
&lt;br /&gt;
I suggest to read the step by step J3.x guide from the beginning using the diff program/site to see the changes.&lt;br /&gt;
&lt;br /&gt;
At step 14 I started to highlight in the guide code the new added lines, when I&#039;ll have some time I&#039;ll add this useful feature (I discovered recently as in the cheatsheet there is no word!) to the previous steps too!&lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 05:28, 18 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Solved ==&lt;br /&gt;
You are right! I&#039;ve solved being more careful with the main xml file. --[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 09:26, 25 February 2015 (CST)&lt;/div&gt;</summary>
		<author><name>Nenomaz</name></author>
	</entry>
	<entry>
		<id>https://docs.sandbox.joomla.org/index.php?title=User_talk:Scionescire&amp;diff=159147</id>
		<title>User talk:Scionescire</title>
		<link rel="alternate" type="text/html" href="https://docs.sandbox.joomla.org/index.php?title=User_talk:Scionescire&amp;diff=159147"/>
		<updated>2015-02-18T10:53:01Z</updated>

		<summary type="html">&lt;p&gt;Nenomaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Hello!==&lt;br /&gt;
Why you have undone statements added by me in the two lessons of &amp;quot;Adding a Model to the site part&amp;quot; and &amp;quot;Adding a view&amp;quot; in the Component Development Tutorial? --[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 04:48, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Hello!! ==&lt;br /&gt;
&lt;br /&gt;
Which statements are you talking about?&lt;br /&gt;
&lt;br /&gt;
I updated the guide parts 1 to 11 following the github updated code from the lesson 10 step.&lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 05:01, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Contribution==&lt;br /&gt;
If you watch the history of these two lessons:&lt;br /&gt;
*[[J3.x:Developing a MVC Component/Adding a model to the site part]]&lt;br /&gt;
*[[J3.x:Developing a MVC Component/Adding a view to the site part]]&lt;br /&gt;
You can see my recent contribution, I had added some content important for make &amp;quot;View and Model&amp;quot; work in a component that before there wasn&#039;t... --[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 05:38, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Hello world meets coding standards ==&lt;br /&gt;
I haven&#039;t noticed your contribution before, sorry!&lt;br /&gt;
&lt;br /&gt;
I have followed the step-10 lesson github code.&lt;br /&gt;
That code removed some ininfluent parts, probably they were good for the 2.5 version of Joomla but not for the 3.x one.&lt;br /&gt;
I&#039;ve personally tested the whole code so I&#039;m sure that the parts I&#039;ve removed are irrilevant (e.g. some jimports, that in 3.x are automatically done).&lt;br /&gt;
&lt;br /&gt;
Once I&#039;ve updated the github code from 10 to 1 to follow that standard, I updated the guide too (that was quite a fast part, so that&#039;s why I missed other contributions).&lt;br /&gt;
&lt;br /&gt;
Hope it&#039;s clear now, but if it&#039;s not, don&#039;t esitate to ask ;)&lt;br /&gt;
&lt;br /&gt;
P.S. If I&#039;m correct, and you are italian too, we can answer in our language =D &lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 05:57, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Github code?==&lt;br /&gt;
&lt;br /&gt;
Could you explain me what is &amp;quot;github code&amp;quot;? I think GitHub is a server to share code, not wiki content.. but I don&#039;t know Joomla Policies... could you explain these to me?&lt;br /&gt;
&lt;br /&gt;
P.S. Si sono italiano :-) cerco di usare l&#039;inglese perchè voglio impararlo ;-)&lt;br /&gt;
&lt;br /&gt;
== Yes, github! ==&lt;br /&gt;
&lt;br /&gt;
Yes, github is exactly what you know, a server to share code!&lt;br /&gt;
But, as you know, its code can be forked, so you can provide corrections, improvements and so on, and that&#039;s what happened.&lt;br /&gt;
Someone corrected the code (that was the same as the wiki), but not the wiki, so the updated and correct version was only in the github code.&lt;br /&gt;
While revisiting it (I&#039;m trying to understand how to develop a 3.x Joomla MVC component) I stumbled upon that version so I decided to update the wiki too.&lt;br /&gt;
&lt;br /&gt;
As for now I&#039;m trying to update step 12 ;)&lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 12:06, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Sorry==&lt;br /&gt;
&lt;br /&gt;
Sorry but I&#039;m not able to understand this method of track the wiki development through GitHub... However, I will reinsert the content I&#039;d added before, I hope you help me to understand this approach of using github for the wiki by the Joomla Community.&lt;br /&gt;
--[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 04:23, 16 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Github ==&lt;br /&gt;
&lt;br /&gt;
The Joomla Wiki about the MVC in version 3.x was more like a copy of the one for the 2.5 version.&lt;br /&gt;
In fact some code was redundant or unnecessary.&lt;br /&gt;
For example a lot of jimport listed in the 2.5 guide are now automatically done in the 3.x one, so there is the need to remove them from the code.&lt;br /&gt;
Same thing for the overloading of the display method you posted.&lt;br /&gt;
If you notice the code works both ways, with and without the declaration of the display method (I guess those lines are now done by default following an exact name pattern (eg. HelloWorldMODEL, HelloWorldCONTROLLER, so if you are in a HelloWorld class and you need its controller the program will search for NAME+CONTROLLER thing.&lt;br /&gt;
&lt;br /&gt;
Hence in github someone with a more knowledge about the new version standars cleaned up the code.&lt;br /&gt;
&lt;br /&gt;
For this reason I followed those hints and rewrited the code in the guide to follow those standards. ;)&lt;br /&gt;
&lt;br /&gt;
P.S. I reverted your change ;)&lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 09:09, 16 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Sure?==&lt;br /&gt;
Meanwhile I needed to put those statements in the display method of the controller to trigger the view... because before didn&#039;t work!&lt;br /&gt;
I think this manner of explain developers the joomla framework is wrong, also keeping track of the wiki through GitHub is wrong... --[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 09:38, 16 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Sure! ==&lt;br /&gt;
&lt;br /&gt;
I tested each part of the guide I updated and it&#039;s working (I don&#039;t think the guy accepted the merge on github would rather accept it either).&lt;br /&gt;
Maybe some mispelled names or missing files?&lt;br /&gt;
Sometimes some lines missing from the main xml could give a really bad headache ;)&lt;br /&gt;
&lt;br /&gt;
I used github as a &#039;source&#039; but other than testing, I searched for the reasons of the editing, so I&#039;m pretty sure that code is good enough to be on the wiki =D&lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 10:08, 16 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Main xml ==&lt;br /&gt;
Could you give me some guidelines about the main xml? Thanks in advance!&lt;br /&gt;
--[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 04:53, 18 February 2015 (CST)&lt;/div&gt;</summary>
		<author><name>Nenomaz</name></author>
	</entry>
	<entry>
		<id>https://docs.sandbox.joomla.org/index.php?title=User_talk:Scionescire&amp;diff=158963</id>
		<title>User talk:Scionescire</title>
		<link rel="alternate" type="text/html" href="https://docs.sandbox.joomla.org/index.php?title=User_talk:Scionescire&amp;diff=158963"/>
		<updated>2015-02-16T15:38:11Z</updated>

		<summary type="html">&lt;p&gt;Nenomaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Hello!==&lt;br /&gt;
Why you have undone statements added by me in the two lessons of &amp;quot;Adding a Model to the site part&amp;quot; and &amp;quot;Adding a view&amp;quot; in the Component Development Tutorial? --[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 04:48, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Hello!! ==&lt;br /&gt;
&lt;br /&gt;
Which statements are you talking about?&lt;br /&gt;
&lt;br /&gt;
I updated the guide parts 1 to 11 following the github updated code from the lesson 10 step.&lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 05:01, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Contribution==&lt;br /&gt;
If you watch the history of these two lessons:&lt;br /&gt;
*[[J3.x:Developing a MVC Component/Adding a model to the site part]]&lt;br /&gt;
*[[J3.x:Developing a MVC Component/Adding a view to the site part]]&lt;br /&gt;
You can see my recent contribution, I had added some content important for make &amp;quot;View and Model&amp;quot; work in a component that before there wasn&#039;t... --[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 05:38, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Hello world meets coding standards ==&lt;br /&gt;
I haven&#039;t noticed your contribution before, sorry!&lt;br /&gt;
&lt;br /&gt;
I have followed the step-10 lesson github code.&lt;br /&gt;
That code removed some ininfluent parts, probably they were good for the 2.5 version of Joomla but not for the 3.x one.&lt;br /&gt;
I&#039;ve personally tested the whole code so I&#039;m sure that the parts I&#039;ve removed are irrilevant (e.g. some jimports, that in 3.x are automatically done).&lt;br /&gt;
&lt;br /&gt;
Once I&#039;ve updated the github code from 10 to 1 to follow that standard, I updated the guide too (that was quite a fast part, so that&#039;s why I missed other contributions).&lt;br /&gt;
&lt;br /&gt;
Hope it&#039;s clear now, but if it&#039;s not, don&#039;t esitate to ask ;)&lt;br /&gt;
&lt;br /&gt;
P.S. If I&#039;m correct, and you are italian too, we can answer in our language =D &lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 05:57, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Github code?==&lt;br /&gt;
&lt;br /&gt;
Could you explain me what is &amp;quot;github code&amp;quot;? I think GitHub is a server to share code, not wiki content.. but I don&#039;t know Joomla Policies... could you explain these to me?&lt;br /&gt;
&lt;br /&gt;
P.S. Si sono italiano :-) cerco di usare l&#039;inglese perchè voglio impararlo ;-)&lt;br /&gt;
&lt;br /&gt;
== Yes, github! ==&lt;br /&gt;
&lt;br /&gt;
Yes, github is exactly what you know, a server to share code!&lt;br /&gt;
But, as you know, its code can be forked, so you can provide corrections, improvements and so on, and that&#039;s what happened.&lt;br /&gt;
Someone corrected the code (that was the same as the wiki), but not the wiki, so the updated and correct version was only in the github code.&lt;br /&gt;
While revisiting it (I&#039;m trying to understand how to develop a 3.x Joomla MVC component) I stumbled upon that version so I decided to update the wiki too.&lt;br /&gt;
&lt;br /&gt;
As for now I&#039;m trying to update step 12 ;)&lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 12:06, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Sorry==&lt;br /&gt;
&lt;br /&gt;
Sorry but I&#039;m not able to understand this method of track the wiki development through GitHub... However, I will reinsert the content I&#039;d added before, I hope you help me to understand this approach of using github for the wiki by the Joomla Community.&lt;br /&gt;
--[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 04:23, 16 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Github ==&lt;br /&gt;
&lt;br /&gt;
The Joomla Wiki about the MVC in version 3.x was more like a copy of the one for the 2.5 version.&lt;br /&gt;
In fact some code was redundant or unnecessary.&lt;br /&gt;
For example a lot of jimport listed in the 2.5 guide are now automatically done in the 3.x one, so there is the need to remove them from the code.&lt;br /&gt;
Same thing for the overloading of the display method you posted.&lt;br /&gt;
If you notice the code works both ways, with and without the declaration of the display method (I guess those lines are now done by default following an exact name pattern (eg. HelloWorldMODEL, HelloWorldCONTROLLER, so if you are in a HelloWorld class and you need its controller the program will search for NAME+CONTROLLER thing.&lt;br /&gt;
&lt;br /&gt;
Hence in github someone with a more knowledge about the new version standars cleaned up the code.&lt;br /&gt;
&lt;br /&gt;
For this reason I followed those hints and rewrited the code in the guide to follow those standards. ;)&lt;br /&gt;
&lt;br /&gt;
P.S. I reverted your change ;)&lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 09:09, 16 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Sure?==&lt;br /&gt;
Meanwhile I needed to put those statements in the display method of the controller to trigger the view... because before didn&#039;t work!&lt;br /&gt;
I think this manner of explain developers the joomla framework is wrong, also keeping track of the wiki through GitHub is wrong... --[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 09:38, 16 February 2015 (CST)&lt;/div&gt;</summary>
		<author><name>Nenomaz</name></author>
	</entry>
	<entry>
		<id>https://docs.sandbox.joomla.org/index.php?title=J3.x:Developing_an_MVC_Component/Adding_a_view_to_the_site_part&amp;diff=158924</id>
		<title>J3.x:Developing an MVC Component/Adding a view to the site part</title>
		<link rel="alternate" type="text/html" href="https://docs.sandbox.joomla.org/index.php?title=J3.x:Developing_an_MVC_Component/Adding_a_view_to_the_site_part&amp;diff=158924"/>
		<updated>2015-02-16T10:26:34Z</updated>

		<summary type="html">&lt;p&gt;Nenomaz: /* Setting the controller */ Trigger the view from the controller&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{version/tutor|3.2}}&lt;br /&gt;
{{Chunk:Developing a Model-View-Controller (MVC) Component for Joomla!3.1 - Contents}}&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
This tutorial is part of the [[J3.2:Developing_a_MVC_Component|Developing a Model-View-Controller (MVC) Component for Joomla! 3.x]] tutorial. You are encouraged to read the previous parts of the tutorial before reading this.&lt;br /&gt;
&lt;br /&gt;
In the Joomla!3.x framework, third party component authors divide their code into three main parts:&lt;br /&gt;
* &#039;&#039;models&#039;&#039; They manage the data &lt;br /&gt;
* &#039;&#039;controllers&#039;&#039; They perform tasks, set and get the states of the models and ask the views to display&lt;br /&gt;
* &#039;&#039;views&#039;&#039; They display the content according to the type (&#039;&#039;error&#039;&#039;, &#039;&#039;feed&#039;&#039;, &#039;&#039;html&#039;&#039;, &#039;&#039;json&#039;&#039;, &#039;&#039;raw&#039;&#039;, &#039;&#039;xml&#039;&#039;) and the layout chosen by the controllers&lt;br /&gt;
&lt;br /&gt;
== Setting the controller ==&lt;br /&gt;
In the core code of Joomla, there is a class able to manage controllers: &#039;&#039;[https://api.joomla.org/cms-3/classes/JControllerLegacy.html JControllerLegacy]&#039;&#039;. This class has to be extended to be used in our component. In the file &#039;&#039;yoursite/components/com_helloworld/helloworld.php&#039;&#039; (entry point of our &#039;&#039;Hello World&#039;&#039; component), put these lines:&lt;br /&gt;
&lt;br /&gt;
{{vanchor|site/helloworld.php}}&lt;br /&gt;
&amp;lt;source lang=&amp;quot;php&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
/**&lt;br /&gt;
 * @package     Joomla.Administrator&lt;br /&gt;
 * @subpackage  com_helloworld&lt;br /&gt;
 *&lt;br /&gt;
 * @copyright   Copyright (C) 2005 - 2015 Open Source Matters, Inc. All rights reserved.&lt;br /&gt;
 * @license     GNU General Public License version 2 or later; see LICENSE.txt&lt;br /&gt;
 */&lt;br /&gt;
&lt;br /&gt;
// No direct access to this file&lt;br /&gt;
defined(&#039;_JEXEC&#039;) or die(&#039;Restricted access&#039;);&lt;br /&gt;
&lt;br /&gt;
// Get an instance of the controller prefixed by HelloWorld&lt;br /&gt;
$controller = JControllerLegacy::getInstance(&#039;HelloWorld&#039;);&lt;br /&gt;
&lt;br /&gt;
// Perform the Request task&lt;br /&gt;
$input = JFactory::getApplication()-&amp;gt;input;&lt;br /&gt;
$controller-&amp;gt;execute($input-&amp;gt;getCmd(&#039;task&#039;));&lt;br /&gt;
&lt;br /&gt;
// Redirect if set by the controller&lt;br /&gt;
$controller-&amp;gt;redirect();&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;[https://api.joomla.org/cms-3/classes/JControllerLegacy.html#method_getInstance getInstance]&#039;&#039; static method of the &#039;&#039;JControllerLegacy&#039;&#039; class will create a controller. In the code above, it will instantiate a controller object of a class named &#039;&#039;HelloWorldController&#039;&#039;. Joomla will look for the declaration of that class in an aptly named file called &#039;&#039;yoursite/components/com_helloworld/controller.php&#039;&#039; (it&#039;s a default behavior).&lt;br /&gt;
&lt;br /&gt;
Now, &#039;&#039;controller.php&#039;&#039; needs to be created and &#039;&#039;HelloWorldController&#039;&#039; needs to be declared and defined. So with your favorite file manager and editor, create a &#039;&#039;yoursite/components/com_helloworld/controller.php&#039;&#039; file containing&lt;br /&gt;
&lt;br /&gt;
{{vanchor|site/controller.php}}&lt;br /&gt;
&amp;lt;source lang=&amp;quot;php&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
/**&lt;br /&gt;
 * @package     Joomla.Administrator&lt;br /&gt;
 * @subpackage  com_helloworld&lt;br /&gt;
 *&lt;br /&gt;
 * @copyright   Copyright (C) 2005 - 2015 Open Source Matters, Inc. All rights reserved.&lt;br /&gt;
 * @license     GNU General Public License version 2 or later; see LICENSE.txt&lt;br /&gt;
 */&lt;br /&gt;
&lt;br /&gt;
// No direct access to this file&lt;br /&gt;
defined(&#039;_JEXEC&#039;) or die(&#039;Restricted access&#039;);&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * Hello World Component Controller&lt;br /&gt;
 *&lt;br /&gt;
 * @since  0.0.1&lt;br /&gt;
 */&lt;br /&gt;
class HelloWorldController extends JControllerLegacy&lt;br /&gt;
{&lt;br /&gt;
	public function display() {&lt;br /&gt;
 		$document = JFactory::getDocument();&lt;br /&gt;
 		$viewName   = $this-&amp;gt;input-&amp;gt;getCmd(&#039;view&#039;, &#039;login&#039;);&lt;br /&gt;
 		$viewFormat = $document-&amp;gt;getType();&lt;br /&gt;
 		$view = $this-&amp;gt;getView($viewName, $viewFormat);&lt;br /&gt;
 		$view-&amp;gt;display();&lt;br /&gt;
 		parent::__construct();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When no task is given in the request variables, the default task will be executed. It&#039;s the &#039;&#039;display&#039;&#039; task by default. The &#039;&#039;JControllerLegacy&#039;&#039; class has such a task. In our example, it will display a view named &#039;&#039;HelloWorld&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
So with &#039;&#039;task&#039;&#039; simply a public function display() of &#039;&#039;JControllerLegacy&#039;&#039; is refered to.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{tip|Just a side note for completion, you could call another function aside from &#039;&#039;display()&#039;&#039; by using an URL like this one:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;http://localhost/index.php?option=com_helloworld&amp;amp;task=insert&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This would try to call a function &#039;&#039;insert()&#039;&#039; of our controller (which we would actually have to implement in &#039;&#039;HelloWorldController&#039;&#039; ).}}&lt;br /&gt;
&lt;br /&gt;
== Setting the view ==&lt;br /&gt;
&lt;br /&gt;
When JControllerLegacy wants to display a view, it will look for certain files in the &#039;&#039;yoursite/components/com_[component_name]/views/[name of view]/&#039;&#039; folder. &lt;br /&gt;
&lt;br /&gt;
The name of the folder of the default view is the name of the component itself. In our case the path is &#039;&#039;yoursite/components/com_helloworld/views/helloworld/&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
The file that will contain the code of the view is called &#039;&#039;view.[view_mode].php&#039;&#039;. The default view mode, and probably the only view a component might need is the &#039;&#039;html&#039;&#039; mode. So this give us our file name which is &#039;&#039;view.html.php&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
With your favorite file manager and editor, create a file &#039;&#039;yoursite/components/com_helloworld/views/helloworld/view.html.php&#039;&#039; able to display the default view and containing:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;php&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
/**&lt;br /&gt;
 * @package     Joomla.Administrator&lt;br /&gt;
 * @subpackage  com_helloworld&lt;br /&gt;
 *&lt;br /&gt;
 * @copyright   Copyright (C) 2005 - 2015 Open Source Matters, Inc. All rights reserved.&lt;br /&gt;
 * @license     GNU General Public License version 2 or later; see LICENSE.txt&lt;br /&gt;
 */&lt;br /&gt;
&lt;br /&gt;
// No direct access to this file&lt;br /&gt;
defined(&#039;_JEXEC&#039;) or die(&#039;Restricted access&#039;);&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * HTML View class for the HelloWorld Component&lt;br /&gt;
 *&lt;br /&gt;
 * @since  0.0.1&lt;br /&gt;
 */&lt;br /&gt;
class HelloWorldViewHelloWorld extends JViewLegacy&lt;br /&gt;
{&lt;br /&gt;
	/**&lt;br /&gt;
	 * Display the Hello World view&lt;br /&gt;
	 *&lt;br /&gt;
	 * @param   string  $tpl  The name of the template file to parse; automatically searches through the template paths.&lt;br /&gt;
	 *&lt;br /&gt;
	 * @return  void&lt;br /&gt;
	 */&lt;br /&gt;
	function display($tpl = null)&lt;br /&gt;
	{&lt;br /&gt;
		// Assign data to the view&lt;br /&gt;
		$this-&amp;gt;msg = &#039;Hello World&#039;;&lt;br /&gt;
&lt;br /&gt;
		// Display the view&lt;br /&gt;
		parent::display($tpl);&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;display&#039;&#039; method of the &#039;&#039;[https://api.joomla.org/cms-3/classes/JViewLegacy.html JViewLegacy]&#039;&#039; class is called with the &#039;&#039;display&#039;&#039; task of the JControllerLegacy class. In our case, this method will display data using the &#039;&#039;tmpl/default.php&#039;&#039; file. With your favorite file manager and editor, create a file &#039;&#039;yoursite/components/com_helloworld/views/helloworld/tmpl/default.php&#039;&#039; able to display the default view and containing:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;php&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
/**&lt;br /&gt;
 * @package     Joomla.Administrator&lt;br /&gt;
 * @subpackage  com_helloworld&lt;br /&gt;
 *&lt;br /&gt;
 * @copyright   Copyright (C) 2005 - 2015 Open Source Matters, Inc. All rights reserved.&lt;br /&gt;
 * @license     GNU General Public License version 2 or later; see LICENSE.txt&lt;br /&gt;
 */&lt;br /&gt;
&lt;br /&gt;
// No direct access to this file&lt;br /&gt;
defined(&#039;_JEXEC&#039;) or die(&#039;Restricted access&#039;);&lt;br /&gt;
?&amp;gt;&lt;br /&gt;
&amp;lt;h1&amp;gt;&amp;lt;?php echo $this-&amp;gt;msg; ?&amp;gt;&amp;lt;/h1&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This template file will be included by the JViewLegacy class. Therefore, here, $this refers to the HelloWorldViewHelloWorld class.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
So to give an example, one could call the view inside the &#039;&#039;yoursite/components/com_[component_name]/views/[name of view]/&#039;&#039; folder by calling &amp;lt;code&amp;gt;index.php?option=com_helloworld&amp;lt;/code&amp;gt; (this would default to the &#039;&#039;yoursite/components/com_helloworld/views/helloworld/&#039;&#039; folder) or we could explicitly call the folder by calling: &amp;lt;code&amp;gt;index.php?option=com_helloworld&amp;amp;view=helloworld&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
if we change &amp;lt;code&amp;gt;&amp;amp;view=helloworld&amp;lt;/code&amp;gt; to something else, e.g. &amp;lt;code&amp;gt;&amp;amp;view=fluffy&amp;lt;/code&amp;gt; we would have to create a folder &amp;lt;code&amp;gt;components/com_helloworld/views/fluffy/&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Copy the contents of &amp;lt;code&amp;gt;views/helloworld&amp;lt;/code&amp;gt; to &amp;lt;code&amp;gt;views/fluffy&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The classname of the file &amp;lt;code&amp;gt;view.html.php&amp;lt;/code&amp;gt; of the fluffy folder would be &#039;&#039;HelloWorldViewFluffy&#039;&#039;. Afterwards you can customize the contents of &#039;&#039;default.php&#039;&#039; of the &#039;&#039;fluffy&#039;&#039; subfolder for custom output and see the output by calling &amp;lt;code&amp;gt;index.php?option=com_helloworld&amp;amp;view=fluffy&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Packaging the component ==&lt;br /&gt;
&lt;br /&gt;
Content of your code directory&lt;br /&gt;
* &#039;&#039;[[#helloworld.xml|helloworld.xml]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[#site/helloworld.php|site/helloworld.php]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|site/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[#site/controller.php|site/controller.php]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|site/views/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|site/views/helloworld/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[#site/views/helloworld/view.html.php|site/views/helloworld/view.html.php]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|site/views/helloworld/tmpl/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[#site/views/helloworld/tmpl/default.php|site/views/helloworld/tmpl/default.php]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|admin/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#admin/helloworld.php|admin/helloworld.php]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|admin/sql/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|admin/sql/updates/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|admin/sql/updates/mysql/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#admin/sql/updates/mysql/0.0.1.sql|admin/sql/updates/mysql/0.0.1.sql]]&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Create a compressed file of this directory or directly download the [https://github.com/scionescire/Joomla-3.2-Hello-World-Component/archive/step-2-adding-a-site-view.zip archive] and install it using the extension manager of Joomla. You can test this basic component by putting &#039;&#039;index.php?option=com_helloworld&#039;&#039; in your browser address.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;helloworld.xml&amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;helloworld.xml&#039;&#039;&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
&amp;lt;extension type=&amp;quot;component&amp;quot; version=&amp;quot;3.2.0&amp;quot; method=&amp;quot;upgrade&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
	&amp;lt;name&amp;gt;Hello World!&amp;lt;/name&amp;gt;&lt;br /&gt;
	&amp;lt;!-- The following elements are optional and free of formatting constraints --&amp;gt;&lt;br /&gt;
	&amp;lt;creationDate&amp;gt;December 2013&amp;lt;/creationDate&amp;gt;&lt;br /&gt;
	&amp;lt;author&amp;gt;John Doe&amp;lt;/author&amp;gt;&lt;br /&gt;
	&amp;lt;authorEmail&amp;gt;john.doe@example.org&amp;lt;/authorEmail&amp;gt;&lt;br /&gt;
	&amp;lt;authorUrl&amp;gt;http://www.example.org&amp;lt;/authorUrl&amp;gt;&lt;br /&gt;
	&amp;lt;copyright&amp;gt;Copyright Info&amp;lt;/copyright&amp;gt;&lt;br /&gt;
	&amp;lt;license&amp;gt;License Info&amp;lt;/license&amp;gt;&lt;br /&gt;
	&amp;lt;!--  The version string is recorded in the components table --&amp;gt;&lt;br /&gt;
	&amp;lt;version&amp;gt;0.0.2&amp;lt;/version&amp;gt;&lt;br /&gt;
	&amp;lt;!-- The description is optional and defaults to the name --&amp;gt;&lt;br /&gt;
	&amp;lt;description&amp;gt;Description of the Hello World component ...&amp;lt;/description&amp;gt;&lt;br /&gt;
&lt;br /&gt;
	&amp;lt;update&amp;gt; &amp;lt;!-- Runs on update; New since J2.5 --&amp;gt;&lt;br /&gt;
		&amp;lt;schemas&amp;gt;&lt;br /&gt;
			&amp;lt;schemapath type=&amp;quot;mysql&amp;quot;&amp;gt;sql/updates/mysql&amp;lt;/schemapath&amp;gt;&lt;br /&gt;
		&amp;lt;/schemas&amp;gt;&lt;br /&gt;
	&amp;lt;/update&amp;gt;&lt;br /&gt;
&lt;br /&gt;
	&amp;lt;!-- Site Main File Copy Section --&amp;gt;&lt;br /&gt;
	&amp;lt;!-- Note the folder attribute: This attribute describes the folder&lt;br /&gt;
		to copy FROM in the package to install therefore files copied&lt;br /&gt;
		in this section are copied from /site/ in the package --&amp;gt;&lt;br /&gt;
	&amp;lt;files folder=&amp;quot;site&amp;quot;&amp;gt;&lt;br /&gt;
		&amp;lt;filename&amp;gt;index.html&amp;lt;/filename&amp;gt;&lt;br /&gt;
		&amp;lt;filename&amp;gt;helloworld.php&amp;lt;/filename&amp;gt;&lt;br /&gt;
		&amp;lt;filename&amp;gt;controller.php&amp;lt;/filename&amp;gt;&lt;br /&gt;
		&amp;lt;folder&amp;gt;views&amp;lt;/folder&amp;gt;&lt;br /&gt;
	&amp;lt;/files&amp;gt;&lt;br /&gt;
&lt;br /&gt;
	&amp;lt;administration&amp;gt;&lt;br /&gt;
		&amp;lt;!-- Administration Menu Section --&amp;gt;&lt;br /&gt;
		&amp;lt;menu link=&#039;index.php?option=com_helloworld&#039;&amp;gt;Hello World!&amp;lt;/menu&amp;gt;&lt;br /&gt;
		&amp;lt;!-- Administration Main File Copy Section --&amp;gt;&lt;br /&gt;
		&amp;lt;!-- Note the folder attribute: This attribute describes the folder&lt;br /&gt;
			to copy FROM in the package to install therefore files copied&lt;br /&gt;
			in this section are copied from /admin/ in the package --&amp;gt;&lt;br /&gt;
		&amp;lt;files folder=&amp;quot;admin&amp;quot;&amp;gt;&lt;br /&gt;
			&amp;lt;!-- Admin Main File Copy Section --&amp;gt;&lt;br /&gt;
			&amp;lt;filename&amp;gt;index.html&amp;lt;/filename&amp;gt;&lt;br /&gt;
			&amp;lt;filename&amp;gt;helloworld.php&amp;lt;/filename&amp;gt;&lt;br /&gt;
			&amp;lt;!-- SQL files section --&amp;gt;&lt;br /&gt;
			&amp;lt;folder&amp;gt;sql&amp;lt;/folder&amp;gt;&lt;br /&gt;
		&amp;lt;/files&amp;gt;&lt;br /&gt;
	&amp;lt;/administration&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/extension&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Result:&#039;&#039;&#039;&lt;br /&gt;
You will see by default the message contained in the variable &#039;&#039;$this-&amp;gt;msg&#039;&#039; in the &#039;&#039;view.html.php&#039;&#039; file.&lt;br /&gt;
&lt;br /&gt;
{{notice|Please create a pull request or issue at https://github.com/joomla/Joomla-3.2-Hello-World-Component for any code descprepancies or if editing any of the source code on this page.}}&lt;br /&gt;
&lt;br /&gt;
{{:J3.2:Developing a MVC Component/Navigate|prev=Developing a Basic Component|next=Adding a menu type to the site part}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;noinclude&amp;gt;[[Category:Component Development]] [[Category:Joomla! 3.0]] [[Category:Joomla! 3.1]][[Category:Joomla! 3.2]]&amp;lt;/noinclude&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contributors ==&lt;br /&gt;
&lt;br /&gt;
*[[User:Gunjanpatel|Gunjan Patel]]&lt;br /&gt;
*[[User:cdemko|Christophe Demko]]&lt;br /&gt;
*[[User:oaksu|Ozgur Aksu]]&lt;br /&gt;
*[[User:Scionescire|Scionescire]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Development]]&lt;br /&gt;
[[Category:Joomla! 3.0]]&lt;br /&gt;
[[Category:Joomla! 3.1]]&lt;br /&gt;
[[Category:Joomla! 3.2]]&lt;/div&gt;</summary>
		<author><name>Nenomaz</name></author>
	</entry>
	<entry>
		<id>https://docs.sandbox.joomla.org/index.php?title=User_talk:Scionescire&amp;diff=158923</id>
		<title>User talk:Scionescire</title>
		<link rel="alternate" type="text/html" href="https://docs.sandbox.joomla.org/index.php?title=User_talk:Scionescire&amp;diff=158923"/>
		<updated>2015-02-16T10:23:48Z</updated>

		<summary type="html">&lt;p&gt;Nenomaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Hello!==&lt;br /&gt;
Why you have undone statements added by me in the two lessons of &amp;quot;Adding a Model to the site part&amp;quot; and &amp;quot;Adding a view&amp;quot; in the Component Development Tutorial? --[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 04:48, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Hello!! ==&lt;br /&gt;
&lt;br /&gt;
Which statements are you talking about?&lt;br /&gt;
&lt;br /&gt;
I updated the guide parts 1 to 11 following the github updated code from the lesson 10 step.&lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 05:01, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Contribution==&lt;br /&gt;
If you watch the history of these two lessons:&lt;br /&gt;
*[[J3.x:Developing a MVC Component/Adding a model to the site part]]&lt;br /&gt;
*[[J3.x:Developing a MVC Component/Adding a view to the site part]]&lt;br /&gt;
You can see my recent contribution, I had added some content important for make &amp;quot;View and Model&amp;quot; work in a component that before there wasn&#039;t... --[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 05:38, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Hello world meets coding standards ==&lt;br /&gt;
I haven&#039;t noticed your contribution before, sorry!&lt;br /&gt;
&lt;br /&gt;
I have followed the step-10 lesson github code.&lt;br /&gt;
That code removed some ininfluent parts, probably they were good for the 2.5 version of Joomla but not for the 3.x one.&lt;br /&gt;
I&#039;ve personally tested the whole code so I&#039;m sure that the parts I&#039;ve removed are irrilevant (e.g. some jimports, that in 3.x are automatically done).&lt;br /&gt;
&lt;br /&gt;
Once I&#039;ve updated the github code from 10 to 1 to follow that standard, I updated the guide too (that was quite a fast part, so that&#039;s why I missed other contributions).&lt;br /&gt;
&lt;br /&gt;
Hope it&#039;s clear now, but if it&#039;s not, don&#039;t esitate to ask ;)&lt;br /&gt;
&lt;br /&gt;
P.S. If I&#039;m correct, and you are italian too, we can answer in our language =D &lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 05:57, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Github code?==&lt;br /&gt;
&lt;br /&gt;
Could you explain me what is &amp;quot;github code&amp;quot;? I think GitHub is a server to share code, not wiki content.. but I don&#039;t know Joomla Policies... could you explain these to me?&lt;br /&gt;
&lt;br /&gt;
P.S. Si sono italiano :-) cerco di usare l&#039;inglese perchè voglio impararlo ;-)&lt;br /&gt;
&lt;br /&gt;
== Yes, github! ==&lt;br /&gt;
&lt;br /&gt;
Yes, github is exactly what you know, a server to share code!&lt;br /&gt;
But, as you know, its code can be forked, so you can provide corrections, improvements and so on, and that&#039;s what happened.&lt;br /&gt;
Someone corrected the code (that was the same as the wiki), but not the wiki, so the updated and correct version was only in the github code.&lt;br /&gt;
While revisiting it (I&#039;m trying to understand how to develop a 3.x Joomla MVC component) I stumbled upon that version so I decided to update the wiki too.&lt;br /&gt;
&lt;br /&gt;
As for now I&#039;m trying to update step 12 ;)&lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 12:06, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Sorry==&lt;br /&gt;
&lt;br /&gt;
Sorry but I&#039;m not able to understand this method of track the wiki development through GitHub... However, I will reinsert the content I&#039;d added before, I hope you help me to understand this approach of using github for the wiki by the Joomla Community.&lt;br /&gt;
--[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 04:23, 16 February 2015 (CST)&lt;/div&gt;</summary>
		<author><name>Nenomaz</name></author>
	</entry>
	<entry>
		<id>https://docs.sandbox.joomla.org/index.php?title=User_talk:Scionescire&amp;diff=158763</id>
		<title>User talk:Scionescire</title>
		<link rel="alternate" type="text/html" href="https://docs.sandbox.joomla.org/index.php?title=User_talk:Scionescire&amp;diff=158763"/>
		<updated>2015-02-12T16:15:58Z</updated>

		<summary type="html">&lt;p&gt;Nenomaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Hello!==&lt;br /&gt;
Why you have undone statements added by me in the two lessons of &amp;quot;Adding a Model to the site part&amp;quot; and &amp;quot;Adding a view&amp;quot; in the Component Development Tutorial? --[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 04:48, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Hello!! ==&lt;br /&gt;
&lt;br /&gt;
Which statements are you talking about?&lt;br /&gt;
&lt;br /&gt;
I updated the guide parts 1 to 11 following the github updated code from the lesson 10 step.&lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 05:01, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Contribution==&lt;br /&gt;
If you watch the history of these two lessons:&lt;br /&gt;
*[[J3.x:Developing a MVC Component/Adding a model to the site part]]&lt;br /&gt;
*[[J3.x:Developing a MVC Component/Adding a view to the site part]]&lt;br /&gt;
You can see my recent contribution, I had added some content important for make &amp;quot;View and Model&amp;quot; work in a component that before there wasn&#039;t... --[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 05:38, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Hello world meets coding standards ==&lt;br /&gt;
I haven&#039;t noticed your contribution before, sorry!&lt;br /&gt;
&lt;br /&gt;
I have followed the step-10 lesson github code.&lt;br /&gt;
That code removed some ininfluent parts, probably they were good for the 2.5 version of Joomla but not for the 3.x one.&lt;br /&gt;
I&#039;ve personally tested the whole code so I&#039;m sure that the parts I&#039;ve removed are irrilevant (e.g. some jimports, that in 3.x are automatically done).&lt;br /&gt;
&lt;br /&gt;
Once I&#039;ve updated the github code from 10 to 1 to follow that standard, I updated the guide too (that was quite a fast part, so that&#039;s why I missed other contributions).&lt;br /&gt;
&lt;br /&gt;
Hope it&#039;s clear now, but if it&#039;s not, don&#039;t esitate to ask ;)&lt;br /&gt;
&lt;br /&gt;
P.S. If I&#039;m correct, and you are italian too, we can answer in our language =D &lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 05:57, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Github code?==&lt;br /&gt;
&lt;br /&gt;
Could you explain me what is &amp;quot;github code&amp;quot;? I think GitHub is a server to share code, not wiki content.. but I don&#039;t know Joomla Policies... could you explain these to me?&lt;br /&gt;
&lt;br /&gt;
P.S. Si sono italiano :-) cerco di usare l&#039;inglese perchè voglio impararlo ;-)&lt;/div&gt;</summary>
		<author><name>Nenomaz</name></author>
	</entry>
	<entry>
		<id>https://docs.sandbox.joomla.org/index.php?title=User_talk:Scionescire&amp;diff=158646</id>
		<title>User talk:Scionescire</title>
		<link rel="alternate" type="text/html" href="https://docs.sandbox.joomla.org/index.php?title=User_talk:Scionescire&amp;diff=158646"/>
		<updated>2015-02-12T11:38:47Z</updated>

		<summary type="html">&lt;p&gt;Nenomaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Hello!==&lt;br /&gt;
Why you have undone statements added by me in the two lessons of &amp;quot;Adding a Model to the site part&amp;quot; and &amp;quot;Adding a view&amp;quot; in the Component Development Tutorial? --[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 04:48, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
== Hello!! ==&lt;br /&gt;
&lt;br /&gt;
Which statements are you talking about?&lt;br /&gt;
&lt;br /&gt;
I updated the guide parts 1 to 11 following the github updated code from the lesson 10 step.&lt;br /&gt;
&lt;br /&gt;
[[User:Scionescire|Scionescire]] ([[User talk:Scionescire|talk]]) 05:01, 12 February 2015 (CST)&lt;br /&gt;
&lt;br /&gt;
==Contribution==&lt;br /&gt;
If you watch the history of these two lessons:&lt;br /&gt;
*[[J3.x:Developing a MVC Component/Adding a model to the site part]]&lt;br /&gt;
*[[J3.x:Developing a MVC Component/Adding a view to the site part]]&lt;br /&gt;
You can see my recent contribution, I had added some content important for make &amp;quot;View and Model&amp;quot; work in a component that before there wasn&#039;t... --[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 05:38, 12 February 2015 (CST)&lt;/div&gt;</summary>
		<author><name>Nenomaz</name></author>
	</entry>
	<entry>
		<id>https://docs.sandbox.joomla.org/index.php?title=User:Nenomaz&amp;diff=158638</id>
		<title>User:Nenomaz</title>
		<link rel="alternate" type="text/html" href="https://docs.sandbox.joomla.org/index.php?title=User:Nenomaz&amp;diff=158638"/>
		<updated>2015-02-12T10:53:03Z</updated>

		<summary type="html">&lt;p&gt;Nenomaz: Created page with &amp;quot;Hi!  I&amp;#039;m an Italian Junior Web Developer.&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Hi!&lt;br /&gt;
&lt;br /&gt;
I&#039;m an Italian Junior Web Developer.&lt;/div&gt;</summary>
		<author><name>Nenomaz</name></author>
	</entry>
	<entry>
		<id>https://docs.sandbox.joomla.org/index.php?title=User_talk:Scionescire&amp;diff=158637</id>
		<title>User talk:Scionescire</title>
		<link rel="alternate" type="text/html" href="https://docs.sandbox.joomla.org/index.php?title=User_talk:Scionescire&amp;diff=158637"/>
		<updated>2015-02-12T10:48:23Z</updated>

		<summary type="html">&lt;p&gt;Nenomaz: Created page with &amp;quot;==Hello!== Why you have undone statements added by me in the two lessons of &amp;quot;Adding a Model to the site part&amp;quot; and &amp;quot;Adding a view&amp;quot; in the Component Development Tutorial? --~~~~&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Hello!==&lt;br /&gt;
Why you have undone statements added by me in the two lessons of &amp;quot;Adding a Model to the site part&amp;quot; and &amp;quot;Adding a view&amp;quot; in the Component Development Tutorial? --[[User:Nenomaz|Nenomaz]] ([[User talk:Nenomaz|talk]]) 04:48, 12 February 2015 (CST)&lt;/div&gt;</summary>
		<author><name>Nenomaz</name></author>
	</entry>
	<entry>
		<id>https://docs.sandbox.joomla.org/index.php?title=J3.x:Developing_an_MVC_Component/Adding_a_view_to_the_site_part&amp;diff=157895</id>
		<title>J3.x:Developing an MVC Component/Adding a view to the site part</title>
		<link rel="alternate" type="text/html" href="https://docs.sandbox.joomla.org/index.php?title=J3.x:Developing_an_MVC_Component/Adding_a_view_to_the_site_part&amp;diff=157895"/>
		<updated>2015-02-05T17:03:09Z</updated>

		<summary type="html">&lt;p&gt;Nenomaz: /* Setting the controller */ code of controller&amp;#039;s display method to trigger the view&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{version/tutor|3.2}}&lt;br /&gt;
{{Chunk:Developing a Model-View-Controller (MVC) Component for Joomla!3.1 - Contents}}&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
This tutorial is part of the [[J3.2:Developing_a_MVC_Component|Developing a Model-View-Controller (MVC) Component for Joomla! 3.x]] tutorial. You are encouraged to read the previous parts of the tutorial before reading this.&lt;br /&gt;
&lt;br /&gt;
In the Joomla!3.x framework, third party component authors divide their code into three main parts:&lt;br /&gt;
* &#039;&#039;models&#039;&#039; They manage the data &lt;br /&gt;
* &#039;&#039;controllers&#039;&#039; They perform tasks, set and get the states of the models and ask the views to display&lt;br /&gt;
* &#039;&#039;views&#039;&#039; They display the content according to the type (&#039;&#039;error&#039;&#039;, &#039;&#039;feed&#039;&#039;, &#039;&#039;html&#039;&#039;, &#039;&#039;json&#039;&#039;, &#039;&#039;raw&#039;&#039;, &#039;&#039;xml&#039;&#039;) and the layout chosen by the controllers&lt;br /&gt;
&lt;br /&gt;
== Setting the controller ==&lt;br /&gt;
In the core code of Joomla, there is a class able to manage controllers: &#039;&#039;[https://api.joomla.org/cms-3/classes/JControllerLegacy.html JControllerLegacy]&#039;&#039;. This class has to be extended to be used in our component. In the file &#039;&#039;yoursite/components/com_helloworld/helloworld.php&#039;&#039; (entry point of our &#039;&#039;Hello World&#039;&#039; component), put these lines:&lt;br /&gt;
&lt;br /&gt;
{{vanchor|site/helloworld.php}}&lt;br /&gt;
&amp;lt;source lang=&amp;quot;php&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
/**&lt;br /&gt;
* @package Joomla.Administrator&lt;br /&gt;
* @subpackage com_helloworld&lt;br /&gt;
*&lt;br /&gt;
* @copyright Copyright (C) 2005 - 2015 Open Source Matters, Inc. All rights reserved.&lt;br /&gt;
* @license GNU General Public License version 2 or later; see LICENSE.txt&lt;br /&gt;
*/&lt;br /&gt;
&lt;br /&gt;
// No direct access to this file&lt;br /&gt;
defined(&#039;_JEXEC&#039;) or die(&#039;Restricted access&#039;);&lt;br /&gt;
&lt;br /&gt;
// Get an instance of the controller prefixed by HelloWorld&lt;br /&gt;
$controller = JControllerLegacy::getInstance(&#039;HelloWorld&#039;);&lt;br /&gt;
&lt;br /&gt;
// Perform the Request task&lt;br /&gt;
$input = JFactory::getApplication()-&amp;gt;input;&lt;br /&gt;
$controller-&amp;gt;execute($input-&amp;gt;getCmd(&#039;task&#039;));&lt;br /&gt;
&lt;br /&gt;
// Redirect if set by the controller&lt;br /&gt;
$controller-&amp;gt;redirect();&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;[https://api.joomla.org/cms-3/classes/JControllerLegacy.html#method_getInstance getInstance]&#039;&#039; static method of the &#039;&#039;JControllerLegacy&#039;&#039; class will create a controller. In the code above, it will instantiate a controller object of a class named &#039;&#039;HelloWorldController&#039;&#039;. Joomla will look for the declaration of that class in an aptly named file called &#039;&#039;yoursite/components/com_helloworld/controller.php&#039;&#039; (it&#039;s a default behavior).&lt;br /&gt;
&lt;br /&gt;
Now, &#039;&#039;controller.php&#039;&#039; needs to be created and &#039;&#039;HelloWorldController&#039;&#039; needs to be declared and defined. So with your favorite file manager and editor, create a &#039;&#039;yoursite/components/com_helloworld/controller.php&#039;&#039; file containing&lt;br /&gt;
&lt;br /&gt;
{{vanchor|site/controller.php}}&lt;br /&gt;
&amp;lt;source lang=&amp;quot;php&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
/**&lt;br /&gt;
* @package Joomla.Administrator&lt;br /&gt;
* @subpackage com_helloworld&lt;br /&gt;
*&lt;br /&gt;
* @copyright Copyright (C) 2005 - 2015 Open Source Matters, Inc. All rights reserved.&lt;br /&gt;
* @license GNU General Public License version 2 or later; see LICENSE.txt&lt;br /&gt;
*/&lt;br /&gt;
&lt;br /&gt;
// No direct access to this file&lt;br /&gt;
defined(&#039;_JEXEC&#039;) or die(&#039;Restricted access&#039;);&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * Hello World Component Controller&lt;br /&gt;
 *&lt;br /&gt;
 * @since   0.0.1&lt;br /&gt;
 */&lt;br /&gt;
class HelloWorldController extends JControllerLegacy&lt;br /&gt;
{&lt;br /&gt;
        public function display() {&lt;br /&gt;
		$document = JFactory::getDocument();&lt;br /&gt;
		$viewName   = $this-&amp;gt;input-&amp;gt;getCmd(&#039;view&#039;, &#039;login&#039;);&lt;br /&gt;
		$viewFormat = $document-&amp;gt;getType();&lt;br /&gt;
		$view = $this-&amp;gt;getView($viewName, $viewFormat);&lt;br /&gt;
		$view-&amp;gt;display();&lt;br /&gt;
		parent::__construct();&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When no task is given in the request variables, the default task will be executed. It&#039;s the &#039;&#039;display&#039;&#039; task by default. The &#039;&#039;JControllerLegacy&#039;&#039; class has such a task. In our example, it will display a view named &#039;&#039;HelloWorld&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
So with &#039;&#039;task&#039;&#039; simply a public function display() of &#039;&#039;JControllerLegacy&#039;&#039; is refered to.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{tip|Just a side note for completion, you could call another function aside from &#039;&#039;display()&#039;&#039; by using an URL like this one:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;http://localhost/index.php?option=com_helloworld&amp;amp;task=insert&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This would try to call a function &#039;&#039;insert()&#039;&#039; of our controller (which we would actually have to implement in &#039;&#039;HelloWorldController&#039;&#039; ).}}&lt;br /&gt;
&lt;br /&gt;
== Setting the view ==&lt;br /&gt;
&lt;br /&gt;
When JControllerLegacy wants to display a view, it will look for certain files in the &#039;&#039;yoursite/components/com_[component_name]/views/[name of view]/&#039;&#039; folder. &lt;br /&gt;
&lt;br /&gt;
The name of the folder of the default view is the name of the component itself. In our case the path is &#039;&#039;yoursite/components/com_helloworld/views/helloworld/&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
The file that will contain the code of the view is called &#039;&#039;view.[view_mode].php&#039;&#039;. The default view mode, and probably the only view a component might need is the &#039;&#039;html&#039;&#039; mode. So this give us our file name which is &#039;&#039;view.html.php&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
With your favorite file manager and editor, create a file &#039;&#039;yoursite/components/com_helloworld/views/helloworld/view.html.php&#039;&#039; able to display the default view and containing:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;php&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
/**&lt;br /&gt;
* @package Joomla.Administrator&lt;br /&gt;
* @subpackage com_helloworld&lt;br /&gt;
*&lt;br /&gt;
* @copyright Copyright (C) 2005 - 2015 Open Source Matters, Inc. All rights reserved.&lt;br /&gt;
* @license GNU General Public License version 2 or later; see LICENSE.txt&lt;br /&gt;
*/&lt;br /&gt;
&lt;br /&gt;
// No direct access to this file&lt;br /&gt;
defined(&#039;_JEXEC&#039;) or die(&#039;Restricted access&#039;);&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
* HTML View class for the HelloWorld Component&lt;br /&gt;
*&lt;br /&gt;
* @since 0.0.1&lt;br /&gt;
*/&lt;br /&gt;
class HelloWorldViewHelloWorld extends JViewLegacy&lt;br /&gt;
{&lt;br /&gt;
	/**&lt;br /&gt;
         * Display the Hello World view&lt;br /&gt;
         *&lt;br /&gt;
         * @param   string  $tpl  The name of the template file to parse; automatically searches through the template paths.&lt;br /&gt;
         *&lt;br /&gt;
         * @return  void&lt;br /&gt;
         */&lt;br /&gt;
	public function display($tpl = null) &lt;br /&gt;
	{&lt;br /&gt;
		// Assign data to the view&lt;br /&gt;
		$this-&amp;gt;msg = &#039;Hello World&#039;;&lt;br /&gt;
&lt;br /&gt;
		// Display the view&lt;br /&gt;
		parent::display($tpl);&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;display&#039;&#039; method of the &#039;&#039;[https://api.joomla.org/cms-3/classes/JViewLegacy.html JViewLegacy]&#039;&#039; class is called with the &#039;&#039;display&#039;&#039; task of the JControllerLegacy class. In our case, this method will display data using the &#039;&#039;tmpl/default.php&#039;&#039; file. With your favorite file manager and editor, create a file &#039;&#039;yoursite/components/com_helloworld/views/helloworld/tmpl/default.php&#039;&#039; able to display the default view and containing:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;php&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
/**&lt;br /&gt;
* @package Joomla.Administrator&lt;br /&gt;
* @subpackage com_helloworld&lt;br /&gt;
*&lt;br /&gt;
* @copyright Copyright (C) 2005 - 2014 Open Source Matters, Inc. All rights reserved.&lt;br /&gt;
* @license GNU General Public License version 2 or later; see LICENSE.txt&lt;br /&gt;
*/&lt;br /&gt;
&lt;br /&gt;
// No direct access to this file&lt;br /&gt;
defined(&#039;_JEXEC&#039;) or die(&#039;Restricted access&#039;);&lt;br /&gt;
?&amp;gt;&lt;br /&gt;
&amp;lt;h1&amp;gt;&amp;lt;?php echo $this-&amp;gt;msg; ?&amp;gt;&amp;lt;/h1&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This template file will be included by the JViewLegacy class. Therefore, here, $this refers to the HelloWorldViewHelloWorld class.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
So to give an example, one could call the view inside the &#039;&#039;yoursite/components/com_[component_name]/views/[name of view]/&#039;&#039; folder by calling &amp;lt;code&amp;gt;index.php?option=com_helloworld&amp;lt;/code&amp;gt; (this would default to the &#039;&#039;yoursite/components/com_helloworld/views/helloworld/&#039;&#039; folder) or we could explicitly call the folder by calling: &amp;lt;code&amp;gt;index.php?option=com_helloworld&amp;amp;view=helloworld&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
if we change &amp;lt;code&amp;gt;&amp;amp;view=helloworld&amp;lt;/code&amp;gt; to something else, e.g. &amp;lt;code&amp;gt;&amp;amp;view=fluffy&amp;lt;/code&amp;gt; we would have to create a folder &amp;lt;code&amp;gt;components/com_helloworld/views/fluffy/&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Copy the contents of &amp;lt;code&amp;gt;views/helloworld&amp;lt;/code&amp;gt; to &amp;lt;code&amp;gt;views/fluffy&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The classname of the file &amp;lt;code&amp;gt;view.html.php&amp;lt;/code&amp;gt; of the fluffy folder would be &#039;&#039;HelloWorldViewFluffy&#039;&#039;. Afterwards you can customize the contents of &#039;&#039;default.php&#039;&#039; of the &#039;&#039;fluffy&#039;&#039; subfolder for custom output and see the output by calling &amp;lt;code&amp;gt;index.php?option=com_helloworld&amp;amp;view=fluffy&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Packaging the component ==&lt;br /&gt;
&lt;br /&gt;
Content of your code directory&lt;br /&gt;
* &#039;&#039;[[#helloworld.xml|helloworld.xml]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[#site/helloworld.php|site/helloworld.php]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|site/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[#site/controller.php|site/controller.php]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|site/views/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|site/views/helloworld/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[#site/views/helloworld/view.html.php|site/views/helloworld/view.html.php]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|site/views/helloworld/tmpl/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[#site/views/helloworld/tmpl/default.php|site/views/helloworld/tmpl/default.php]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|admin/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#admin/helloworld.php|admin/helloworld.php]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|admin/sql/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|admin/sql/updates/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|admin/sql/updates/mysql/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#admin/sql/updates/mysql/0.0.1.sql|admin/sql/updates/mysql/0.0.1.sql]]&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Create a compressed file of this directory or directly download the [http://joomlacode.org/gf/download/frsrelease/11394/58226/com_helloworld-1.6-part02.zip archive] and install it using the extension manager of Joomla. You can test this basic component by putting &#039;&#039;index.php?option=com_helloworld&#039;&#039; in your browser address.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;helloworld.xml&amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;helloworld.xml&#039;&#039;&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
&amp;lt;extension type=&amp;quot;component&amp;quot; version=&amp;quot;3.2&amp;quot; method=&amp;quot;upgrade&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
	&amp;lt;name&amp;gt;Hello World!&amp;lt;/name&amp;gt;&lt;br /&gt;
	&amp;lt;!-- The following elements are optional and free of formatting constraints --&amp;gt;&lt;br /&gt;
	&amp;lt;creationDate&amp;gt;December 2013&amp;lt;/creationDate&amp;gt;&lt;br /&gt;
	&amp;lt;author&amp;gt;John Doe&amp;lt;/author&amp;gt;&lt;br /&gt;
	&amp;lt;authorEmail&amp;gt;john.doe@example.org&amp;lt;/authorEmail&amp;gt;&lt;br /&gt;
	&amp;lt;authorUrl&amp;gt;http://www.example.org&amp;lt;/authorUrl&amp;gt;&lt;br /&gt;
	&amp;lt;copyright&amp;gt;Copyright Info&amp;lt;/copyright&amp;gt;&lt;br /&gt;
	&amp;lt;license&amp;gt;License Info&amp;lt;/license&amp;gt;&lt;br /&gt;
	&amp;lt;!--  The version string is recorded in the components table --&amp;gt;&lt;br /&gt;
	&amp;lt;version&amp;gt;0.0.2&amp;lt;/version&amp;gt;&lt;br /&gt;
	&amp;lt;!-- The description is optional and defaults to the name --&amp;gt;&lt;br /&gt;
	&amp;lt;description&amp;gt;Description of the Hello World component ...&amp;lt;/description&amp;gt;&lt;br /&gt;
&lt;br /&gt;
	&amp;lt;update&amp;gt; &amp;lt;!-- Runs on update; New since J2.5 --&amp;gt;&lt;br /&gt;
		&amp;lt;schemas&amp;gt;&lt;br /&gt;
			&amp;lt;schemapath type=&amp;quot;mysql&amp;quot;&amp;gt;sql/updates/mysql&amp;lt;/schemapath&amp;gt;&lt;br /&gt;
		&amp;lt;/schemas&amp;gt;&lt;br /&gt;
	&amp;lt;/update&amp;gt;&lt;br /&gt;
&lt;br /&gt;
	&amp;lt;!-- Site Main File Copy Section --&amp;gt;&lt;br /&gt;
	&amp;lt;!-- Note the folder attribute: This attribute describes the folder&lt;br /&gt;
		to copy FROM in the package to install therefore files copied&lt;br /&gt;
		in this section are copied from /site/ in the package --&amp;gt;&lt;br /&gt;
	&amp;lt;files folder=&amp;quot;site&amp;quot;&amp;gt;&lt;br /&gt;
		&amp;lt;filename&amp;gt;index.html&amp;lt;/filename&amp;gt;&lt;br /&gt;
		&amp;lt;filename&amp;gt;helloworld.php&amp;lt;/filename&amp;gt;&lt;br /&gt;
		&amp;lt;filename&amp;gt;controller.php&amp;lt;/filename&amp;gt;&lt;br /&gt;
		&amp;lt;folder&amp;gt;views&amp;lt;/folder&amp;gt;&lt;br /&gt;
	&amp;lt;/files&amp;gt;&lt;br /&gt;
&lt;br /&gt;
	&amp;lt;administration&amp;gt;&lt;br /&gt;
		&amp;lt;!-- Administration Menu Section --&amp;gt;&lt;br /&gt;
		&amp;lt;menu link=&#039;index.php?option=com_helloworld&#039;&amp;gt;Hello World!&amp;lt;/menu&amp;gt;&lt;br /&gt;
		&amp;lt;!-- Administration Main File Copy Section --&amp;gt;&lt;br /&gt;
		&amp;lt;!-- Note the folder attribute: This attribute describes the folder&lt;br /&gt;
			to copy FROM in the package to install therefore files copied&lt;br /&gt;
			in this section are copied from /admin/ in the package --&amp;gt;&lt;br /&gt;
		&amp;lt;files folder=&amp;quot;admin&amp;quot;&amp;gt;&lt;br /&gt;
			&amp;lt;!-- Admin Main File Copy Section --&amp;gt;&lt;br /&gt;
			&amp;lt;filename&amp;gt;index.html&amp;lt;/filename&amp;gt;&lt;br /&gt;
			&amp;lt;filename&amp;gt;helloworld.php&amp;lt;/filename&amp;gt;&lt;br /&gt;
			&amp;lt;!-- SQL files section --&amp;gt;&lt;br /&gt;
			&amp;lt;folder&amp;gt;sql&amp;lt;/folder&amp;gt;&lt;br /&gt;
		&amp;lt;/files&amp;gt;&lt;br /&gt;
	&amp;lt;/administration&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/extension&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Result:&#039;&#039;&#039;&lt;br /&gt;
You will see by default the message contained in the variable &#039;&#039;$this-&amp;gt;msg&#039;&#039; in the &#039;&#039;view.html.php&#039;&#039; file.&lt;br /&gt;
&lt;br /&gt;
{{notice|Please create a pull request or issue at https://github.com/joomla/Joomla-3.2-Hello-World-Component for any code descprepancies or if editing any of the source code on this page.}}&lt;br /&gt;
&lt;br /&gt;
{{:J3.2:Developing a MVC Component/Navigate|prev=Developing a Basic Component|next=Adding a menu type to the site part}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;noinclude&amp;gt;[[Category:Component Development]] [[Category:Joomla! 3.0]] [[Category:Joomla! 3.1]][[Category:Joomla! 3.2]]&amp;lt;/noinclude&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contributors ==&lt;br /&gt;
&lt;br /&gt;
*[[User:Gunjanpatel|Gunjan Patel]]&lt;br /&gt;
*[[User:cdemko|Christophe Demko]]&lt;br /&gt;
*[[User:oaksu|Ozgur Aksu]]&lt;br /&gt;
*[[User:Scionescire|Scionescire]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Development]]&lt;br /&gt;
[[Category:Joomla! 3.0]]&lt;br /&gt;
[[Category:Joomla! 3.1]]&lt;br /&gt;
[[Category:Joomla! 3.2]]&lt;/div&gt;</summary>
		<author><name>Nenomaz</name></author>
	</entry>
	<entry>
		<id>https://docs.sandbox.joomla.org/index.php?title=J3.x:Developing_an_MVC_Component/Adding_a_model_to_the_site_part&amp;diff=157894</id>
		<title>J3.x:Developing an MVC Component/Adding a model to the site part</title>
		<link rel="alternate" type="text/html" href="https://docs.sandbox.joomla.org/index.php?title=J3.x:Developing_an_MVC_Component/Adding_a_model_to_the_site_part&amp;diff=157894"/>
		<updated>2015-02-05T16:46:36Z</updated>

		<summary type="html">&lt;p&gt;Nenomaz: /* Adding a model */ set the model for the view in the controller&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{:J3.1:Developing a MVC Component}}&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
This tutorial is part of the [[J3.2:Developing a MVC Component | Developing a MVC Component for Joomla! 3.2]] tutorial. You are encouraged to read the previous parts of the tutorial before reading this.&lt;br /&gt;
&lt;br /&gt;
== Adding a model ==&lt;br /&gt;
In the Joomla framework, models are responsible for managing the data. The first function that has to be written for a model is a &#039;&#039;get&#039;&#039; function. It returns data to the caller. In our case, the caller will be the &#039;&#039;HelloWorldViewHelloWorld&#039;&#039; view. By default, the model named &#039;&#039;HelloWorldModelHelloWorld&#039;&#039; residing in &#039;&#039;site/models/helloworld.php&#039;&#039; is the main model associated to this view. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
So let&#039;s have a quick look at the naming conventions with an example, since the naming convention are the actual magic, that make everything work:&lt;br /&gt;
&lt;br /&gt;
The class &#039;&#039;HelloWorldView&#039;&#039;&#039;HelloWorld&#039;&#039;&#039;&#039;&#039; resides in &#039;&#039;site/views/&#039;&#039;&#039;helloworld&#039;&#039;&#039;/view.html.php&#039;&#039; and will make use of the class &#039;&#039;HelloWorldModel&#039;&#039;&#039;HelloWorld&#039;&#039;&#039;&#039;&#039; in the file &#039;&#039;site/models/&#039;&#039;&#039;helloworld&#039;&#039;&#039;.php&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
So let&#039;s just assume we want to use an imaginary view &#039;&#039;fluffy&#039;&#039;, you would have to have:&lt;br /&gt;
&lt;br /&gt;
The class &#039;&#039;HelloWorldView&#039;&#039;&#039;Fluffy&#039;&#039;&#039;&#039;&#039; which resides in &#039;&#039;site/views/&#039;&#039;&#039;fluffy&#039;&#039;&#039;/view.html.php&#039;&#039;. The view will make use of &#039;&#039;HelloWorldModel&#039;&#039;&#039;Fluffy&#039;&#039;&#039;&#039;&#039; in the file &#039;&#039;site/models/&#039;&#039;&#039;fluffy&#039;&#039;&#039;.php&#039;&#039;. Note: the actual screen of the view: &#039;&#039;site/views/&#039;&#039;&#039;fluffy&#039;&#039;&#039;/tmpl/default.php&#039;&#039; is required as well to make this example work.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Breaking any of these bold conventions will lead to errors or a blank page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
So back to the actual implementation of the single classes:&lt;br /&gt;
&lt;br /&gt;
With your favorite file manager and editor put a &#039;&#039;site/models/helloworld.php&#039;&#039; file containing:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;site/models/helloworld.php&amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;site/models/helloworld.php&#039;&#039;&lt;br /&gt;
&amp;lt;source lang=&amp;quot;php&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
// No direct access to this file&lt;br /&gt;
defined(&#039;_JEXEC&#039;) or die(&#039;Restricted access&#039;);&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * HelloWorld Model&lt;br /&gt;
 */&lt;br /&gt;
class HelloWorldModelHelloWorld extends JModelItem&lt;br /&gt;
{&lt;br /&gt;
	/**&lt;br /&gt;
	 * @var string msg&lt;br /&gt;
	 */&lt;br /&gt;
	protected $msg;&lt;br /&gt;
&lt;br /&gt;
	/**&lt;br /&gt;
	 * Get the message&lt;br /&gt;
	 * @return string The message to be displayed to the user&lt;br /&gt;
	 */&lt;br /&gt;
	public function getMsg() &lt;br /&gt;
	{&lt;br /&gt;
		if (!isset($this-&amp;gt;msg)) &lt;br /&gt;
		{&lt;br /&gt;
			$this-&amp;gt;msg = &#039;Hello World!&#039;;&lt;br /&gt;
		}&lt;br /&gt;
		return $this-&amp;gt;msg;&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Open the site/controller.php file and inject the model to the view:&lt;br /&gt;
&amp;lt;source lang=&amp;quot;php&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
&lt;br /&gt;
// No direct access to this file&lt;br /&gt;
defined(&#039;_JEXEC&#039;) or die(&#039;Restricted access&#039;);&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
class HelloWorldController extends JControllerLegacy {&lt;br /&gt;
	&lt;br /&gt;
	public function display() {&lt;br /&gt;
		$document = JFactory::getDocument();&lt;br /&gt;
		$vName   = $this-&amp;gt;input-&amp;gt;getCmd(&#039;view&#039;, &#039;login&#039;);&lt;br /&gt;
		$vFormat = $document-&amp;gt;getType();&lt;br /&gt;
		$model = $this-&amp;gt;getModel($vName);&lt;br /&gt;
		$view = $this-&amp;gt;getView($vName, $vFormat);&lt;br /&gt;
		$view-&amp;gt;setModel($model, true);&lt;br /&gt;
		$view-&amp;gt;display();&lt;br /&gt;
		parent::__construct();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
The &#039;&#039;HelloWorldViewHelloWorld&#039;&#039; class asks the model for data using the &#039;&#039;get&#039;&#039; method of the &#039;&#039;JViewLegacy&#039;&#039; class:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;site/views/helloworld/view.html.php&amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;site/views/helloworld/view.html.php&#039;&#039;&lt;br /&gt;
&amp;lt;source lang=&amp;quot;php&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
/**&lt;br /&gt;
* @package Joomla.Administrator&lt;br /&gt;
* @subpackage com_helloworld&lt;br /&gt;
*&lt;br /&gt;
* @copyright Copyright (C) 2005 - 2015 Open Source Matters, Inc. All rights reserved.&lt;br /&gt;
* @license GNU General Public License version 2 or later; see LICENSE.txt&lt;br /&gt;
*/&lt;br /&gt;
 &lt;br /&gt;
// No direct access to this file&lt;br /&gt;
defined(&#039;_JEXEC&#039;) or die(&#039;Restricted access&#039;);&lt;br /&gt;
 &lt;br /&gt;
/**&lt;br /&gt;
* HTML View class for the HelloWorld Component&lt;br /&gt;
*&lt;br /&gt;
* @since 0.0.1&lt;br /&gt;
*/&lt;br /&gt;
class HelloWorldViewHelloWorld extends JViewLegacy&lt;br /&gt;
{&lt;br /&gt;
	/**&lt;br /&gt;
         * Display the Hello World view&lt;br /&gt;
         *&lt;br /&gt;
         * @param   string  $tpl  The name of the template file to parse; automatically searches through the template paths.&lt;br /&gt;
         *&lt;br /&gt;
         * @return  void&lt;br /&gt;
         */&lt;br /&gt;
	// Overwriting JViewLegacy display method&lt;br /&gt;
	public function display($tpl = null) &lt;br /&gt;
	{&lt;br /&gt;
		// Assign data to the view&lt;br /&gt;
		$this-&amp;gt;msg = $this-&amp;gt;get(&#039;Msg&#039;);&lt;br /&gt;
 &lt;br /&gt;
		// Check for errors.&lt;br /&gt;
		if (count($errors = $this-&amp;gt;get(&#039;Errors&#039;))) &lt;br /&gt;
		{&lt;br /&gt;
			JLog::add(implode(&#039;&amp;lt;br /&amp;gt;&#039;, $errors), JLog::WARNING, &#039;jerror&#039;);&lt;br /&gt;
			return false;&lt;br /&gt;
		}&lt;br /&gt;
 &lt;br /&gt;
		// Display the view&lt;br /&gt;
		parent::display($tpl);&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note: $this-&amp;gt;get() is a member of JViewLegacy::get which is a proxy to get* methods of the default model where * is populated with the value of the first parameter passed to get()&lt;br /&gt;
&lt;br /&gt;
Also modify your &#039;&#039;helloworld.xml&#039;&#039; file to indicate use of models and the new version:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;helloworld.xml&amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;helloworld.xml&#039;&#039;&lt;br /&gt;
&amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
&amp;lt;extension type=&amp;quot;component&amp;quot; version=&amp;quot;3.2&amp;quot; method=&amp;quot;upgrade&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
	&amp;lt;name&amp;gt;Hello World!&amp;lt;/name&amp;gt;&lt;br /&gt;
	&amp;lt;!-- The following elements are optional and free of formatting constraints --&amp;gt;&lt;br /&gt;
	&amp;lt;creationDate&amp;gt;January 2014&amp;lt;/creationDate&amp;gt;&lt;br /&gt;
	&amp;lt;author&amp;gt;John Doe&amp;lt;/author&amp;gt;&lt;br /&gt;
	&amp;lt;authorEmail&amp;gt;john.doe@example.org&amp;lt;/authorEmail&amp;gt;&lt;br /&gt;
	&amp;lt;authorUrl&amp;gt;http://www.example.org&amp;lt;/authorUrl&amp;gt;&lt;br /&gt;
	&amp;lt;copyright&amp;gt;Copyright Info&amp;lt;/copyright&amp;gt;&lt;br /&gt;
	&amp;lt;license&amp;gt;License Info&amp;lt;/license&amp;gt;&lt;br /&gt;
	&amp;lt;!--  The version string is recorded in the components table --&amp;gt;&lt;br /&gt;
	&amp;lt;version&amp;gt;0.0.4&amp;lt;/version&amp;gt;&lt;br /&gt;
	&amp;lt;!-- The description is optional and defaults to the name --&amp;gt;&lt;br /&gt;
	&amp;lt;description&amp;gt;Description of the Hello World component ...&amp;lt;/description&amp;gt;&lt;br /&gt;
&lt;br /&gt;
	&amp;lt;update&amp;gt; &amp;lt;!-- Runs on update; New since J2.5 --&amp;gt;&lt;br /&gt;
		&amp;lt;schemas&amp;gt;&lt;br /&gt;
			&amp;lt;schemapath type=&amp;quot;mysql&amp;quot;&amp;gt;sql/updates/mysql&amp;lt;/schemapath&amp;gt;&lt;br /&gt;
		&amp;lt;/schemas&amp;gt;&lt;br /&gt;
	&amp;lt;/update&amp;gt;&lt;br /&gt;
&lt;br /&gt;
	&amp;lt;!-- Site Main File Copy Section --&amp;gt;&lt;br /&gt;
	&amp;lt;!-- Note the folder attribute: This attribute describes the folder&lt;br /&gt;
		to copy FROM in the package to install therefore files copied&lt;br /&gt;
		in this section are copied from /site/ in the package --&amp;gt;&lt;br /&gt;
	&amp;lt;files folder=&amp;quot;site&amp;quot;&amp;gt;&lt;br /&gt;
		&amp;lt;filename&amp;gt;index.html&amp;lt;/filename&amp;gt;&lt;br /&gt;
		&amp;lt;filename&amp;gt;helloworld.php&amp;lt;/filename&amp;gt;&lt;br /&gt;
		&amp;lt;filename&amp;gt;controller.php&amp;lt;/filename&amp;gt;&lt;br /&gt;
		&amp;lt;folder&amp;gt;views&amp;lt;/folder&amp;gt;&lt;br /&gt;
		&amp;lt;folder&amp;gt;models&amp;lt;/folder&amp;gt;&lt;br /&gt;
	&amp;lt;/files&amp;gt;&lt;br /&gt;
&lt;br /&gt;
	&amp;lt;administration&amp;gt;&lt;br /&gt;
		&amp;lt;!-- Administration Menu Section --&amp;gt;&lt;br /&gt;
		&amp;lt;menu link=&#039;index.php?option=com_helloworld&#039;&amp;gt;Hello World!&amp;lt;/menu&amp;gt;&lt;br /&gt;
		&amp;lt;!-- Administration Main File Copy Section --&amp;gt;&lt;br /&gt;
		&amp;lt;!-- Note the folder attribute: This attribute describes the folder&lt;br /&gt;
			to copy FROM in the package to install therefore files copied&lt;br /&gt;
			in this section are copied from /admin/ in the package --&amp;gt;&lt;br /&gt;
		&amp;lt;files folder=&amp;quot;admin&amp;quot;&amp;gt;&lt;br /&gt;
			&amp;lt;!-- Admin Main File Copy Section --&amp;gt;&lt;br /&gt;
			&amp;lt;filename&amp;gt;index.html&amp;lt;/filename&amp;gt;&lt;br /&gt;
			&amp;lt;filename&amp;gt;helloworld.php&amp;lt;/filename&amp;gt;&lt;br /&gt;
			&amp;lt;!-- SQL files section --&amp;gt;&lt;br /&gt;
			&amp;lt;folder&amp;gt;sql&amp;lt;/folder&amp;gt;&lt;br /&gt;
		&amp;lt;/files&amp;gt;&lt;br /&gt;
	&amp;lt;/administration&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/extension&amp;gt;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Packaging the component ==&lt;br /&gt;
&lt;br /&gt;
Content of your code directory&lt;br /&gt;
* &#039;&#039;[[#helloworld.xml|helloworld.xml]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Adding_a_view_to_the_site_part#site/helloworld.php|site/helloworld.php]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|site/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Adding_a_view_to_the_site_part#site/controller.php|site/controller.php]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|site/views/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|site/views/helloworld/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Adding_a_view_to_the_site_part#site/views/helloworld/view.html.php|site/views/helloworld/view.html.php]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|site/views/helloworld/tmpl/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Adding_a_menu_type_to_the_site_part#site/views/helloworld/tmpl/default.xml|site/views/helloworld/tmpl/default.xml]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Adding_a_view_to_the_site_part#site/views/helloworld/tmpl/default.php|site/views/helloworld/tmpl/default.php]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|site/models/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[#site/models/helloworld.php|site/models/helloworld.php]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|admin/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#admin/helloworld.php|admin/helloworld.php]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|admin/sql/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|admin/sql/updates/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#index.html|admin/sql/updates/mysql/index.html]]&#039;&#039;&lt;br /&gt;
* &#039;&#039;[[J3.2:Developing_a_MVC_Component/Developing_a_Basic_Component#admin/sql/updates/mysql/0.0.1.sql|admin/sql/updates/mysql/0.0.1.sql]]&#039;&#039;&lt;br /&gt;
Create a compressed file of this directory or directly download the [https://github.com/joomla/Joomla-3.2-Hello-World-Component/archive/step-4-adding-a-site-model.zip archive] and install it using the extension manager of Joomla. You can add a menu item of this component using the menu manager in the backend.&lt;br /&gt;
&lt;br /&gt;
{{notice|Please create a pull request or issue at https://github.com/joomla/Joomla-3.2-Hello-World-Component for any code descprepancies or if editing any of the source code on this page.}}&lt;br /&gt;
&lt;br /&gt;
{{:J3.2:Developing a MVC Component/Navigate&lt;br /&gt;
|prev=Adding a menu type to the site part &amp;lt;!-- previous article subpage name --&amp;gt;&lt;br /&gt;
|next=Adding a variable request in the menu type &amp;lt;!-- next article subpage name --&amp;gt;}}&lt;br /&gt;
&lt;br /&gt;
== Contributors ==&lt;br /&gt;
*[[User:cdemko|Christophe Demko]]&lt;br /&gt;
*[[User:oaksu|Ozgur Aksu]]&lt;br /&gt;
*[[User:Jossnaz|Lukas Meier]]&lt;br /&gt;
*[[User:betweenbrain|Matt Thomas]]&lt;br /&gt;
*[[User:Scionescire|Scionescire]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Joomla! 3.0]]&lt;br /&gt;
[[Category:Joomla! 3.1]]&lt;br /&gt;
[[Category:Joomla! 3.2]]&lt;br /&gt;
[[Category:Beginner Development]]&lt;br /&gt;
[[Category:Component Development]]&lt;/div&gt;</summary>
		<author><name>Nenomaz</name></author>
	</entry>
</feed>