"admin only" component

Have a programming question regarding your component, plug-in, extension or core hacks? Have an interesting tidbit, FAQ or programming tip you’d like to share? This is the place for you.

Moderators: tjay, seadap, Rogue4ngel, matthewhayashida

Post Reply
laurelwilliams
Joomla! Apprentice
Joomla! Apprentice
Posts: 6
Joined: Tue Nov 20, 2007 8:40 pm

"admin only" component

Post by laurelwilliams » Tue Nov 20, 2007 8:46 pm

I'm working with the hello world tutorials for 1.5, specifically the fourth example which introduces some administration concepts. I'm interested in finding out if it is possible to make a hello world component that is administrator only - ie. there is no joomla front end, so you can't add it to the main menu, etc.

I removed the "site" files from the zip file, and also the "site" parts of the xml file, however, when I install the component, I can still add it to the main menu, etc.

How would I make this component "admin only"??

L.

permalink
Joomla! Apprentice
Joomla! Apprentice
Posts: 9
Joined: Tue Feb 19, 2008 5:36 pm

Re:

Post by permalink » Tue Feb 26, 2008 7:02 am

well I do know that in your install xml you need to have this, hopefully its all you need:

Code: Select all

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE install SYSTEM "http://dev.joomla.org/xml/1.5/component-install.dtd">
<install type="component" version="1.5.0">
...
	<files>
            <!-- notice the empty files section -->
	</files>
	<administration>
		<languages folder="languages">
			<language tag="en-GB">en-GB.com_mine.ini</language>
		</languages>
		<menu img="mine.png">My Component</menu>
		<files>
			<filename>index.html</filename>
			<filename>etc.php</filename>
		</files>
	</administration>
</install>


Post Reply