How to update joomla modules from repository? - joomla

i created module and put it into joomla repository. I created the update for that module, and put into repository too. Into my xml file i write some line to be install tags:
<install version="1.5" type="module" client="site" method="upgrade">
I known how to updated extentions in joomla (Update extentions)
<extension type="component" version="2.5.0" method="upgrade">
But how to update the modules? In admin part i can't see my update from repository. Can you help me, or can you give some links where i can read about only modules update in Joomla.
Thank!

You firstly need to add the following to your XML file for your module:
<updateservers>
<server type="extension" name="Name of Module" priority="1">http://www.example.com/update.xml</server>
</updateservers>
Then, create a new XML file called update.xml (if you want to call it something else, then be sure to change the name in the code above) and add the following code to it:
<updates>
<update>
<name>Name of Module</name>
<description>description goes here</description>
<element>mod_my_module</element>
<type>module</type>
<version>1.0.0</version>
<downloads>
<downloadurl type="full" format="zip">http://www.example.com/module.zip</downloadurl>
</downloads>
<maintainer>Company Name</maintainer>
<maintainerurl>http://www.example.com</maintainerurl>
<targetplatform name="joomla" version="2.5"/>
<client>0</client>
<client_id>0</client_id>
</update>
<updates>
Every time you want to release an update, you simply need to duplicate the <update> tags and everything inside it and put it above the previous one. So here would be an example of version 1.0.0 and 1.1.0
<updates>
<update>
<name>Name of Module</name>
<description>description goes here</description>
<element>mod_my_module</element>
<type>module</type>
<version>1.1.0</version>
<downloads>
<downloadurl type="full" format="zip">http://www.example.com/module.zip</downloadurl>
</downloads>
<maintainer>Company Name</maintainer>
<maintainerurl>http://www.example.com</maintainerurl>
<targetplatform name="joomla" version="2.5"/>
<client>0</client>
<client_id>0</client_id>
</update>
<update>
<name>Name of Module</name>
<description>description goes here</description>
<element>mod_my_module</element>
<type>module</type>
<version>1.0.0</version>
<downloads>
<downloadurl type="full" format="zip">http://www.example.com/module.zip</downloadurl>
</downloads>
<maintainer>Company Name</maintainer>
<maintainerurl>http://www.example.com</maintainerurl>
<targetplatform name="joomla" version="2.5"/>
<client>0</client>
<client_id>0</client_id>
</update>
<updates>
Hope this helps

Related

Magento module not added to core_resource table

I am trying to write a script which has to execute when a module is updated. I wanted to check the version in db table core_resource, but i see now that the module is not added there. Am i looking in the wrong place, or is there something wrong with my code? This is the relevant part of the config file:
<?xml version="1.0"?>
<config>
<modules>
<mymodule>
<version>1.0.0.0</version>
</mymodule>
</modules>
<global>
<resources>
<update_myscript>
<setup>
<module>mymodule</module>
</setup>
</update_myscript>
</resources>
</global>
</config>
And i created an update file: /updateMyscript/upgrade-1.0.0.0-1.0.0.1.php
If your module has been registered on core_resource, you need to delete from that, for the setup execute again.
And if you want update the module setup, you need to create that upgrade file (upgrade-1.0.0.0-1.0.0.1.php) and alter the version on config.xml
Like this:
<mymodule>
<version>1.0.0.1</version>
</mymodule>
After this you need clear cache from Magento.

After JUpdate my content position is gone from list - joomla

I used JUpdate to update a joomla 1.5.23 site to 2.5
when i tried to re-link the content area to the article i cant find the position from my main content area in the menu anymore.
the left sidebar is still there and also the right one.
Can anyone shine some light on this? i already tried all the positions from the template twice but i cant seem to find it?
--- template details ---
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE install PUBLIC "-//Joomla! 1.6//DTD template 1.0//EN" "http://www.joomla.org/xml/dtd/1.6/template-install.dtd">
<extension version="2.5" type="template" client="site" >
<name></name>
<version>1.0.0</version>
<creationDate>07/2009</creationDate>
<author>SiteGround</author>
<authorEmail></authorEmail>
<authorUrl></authorUrl>
<copyright></copyright>
<license>GNU/GPL</license>
<description>TEMPLATE_DESCRIPTION</description>
<files>
<filename>index.php</filename>
<filename>templateDetails.xml</filename>
<filename>template_thumbnail.png</filename>
<filename>templates.php</filename>
<filename>template_preview.png</filename>
<filename>error.php</filename>
<folder>css</folder>
<folder>images</folder>
</files>
<positions>
<position>user4</position>
<position>user3</position>
<position>breadcrumb</position>
<position>user2</position>
<position>left</position>
<position>right</position>
<position>debug</position>
</positions>
<languages>
<language tag="en-GB">en-GB.tpl_siteground-j15-80.ini</language>
</languages>
<administration>
<languages folder="admin">
<language tag="en-GB">en-GB.tpl_siteground-j15-80.ini</language>
</languages>
</administration>
</extension>
I'm not too sure why you used JUpdate to update to 2.5. I personally don't always trust 3rd party extensions to update the CMS as it sometimes causes problems. What you should do is (providing you have a backup of your old 1.6 site):
Upgrade to 1.6.6 by downloading the patch and extracting it via FTP on to the root of your site
IN the Joomla Backend, go to Extensions >> Extension Manager >> Find Updates
If you can't find any updates, then go to Options and select the Long Term Release. Once saved, Purge Cache and try to find updates again.
Update:
change this:
<?php if($this->params->get('showComponent')) : ?>
<jdoc:include type="component" />
<?php endif; ?>
to this:
<jdoc:include type="component" />
So basically remove the PHP that is wrapped around

Joomla Install/Uninstall SQL FIles Location in a Package

I am building a Joomla package with a component, multiple modules and a plugin.
My question is, where should I place the install.sql and uninstall.sql files, relative to the package root? Right now they are at root/com_mypackage/administrator/sql/install.mysql.utf8.sql and they are defined in the component's manifest as:
<install><!-- Runs on install -->
<sql>
<file driver="mysql" charset="utf8">sql/install.mysql.utf8.sql</file>
</sql>
</install>
However, this doesn't seem right to me. Should I include administrator before the path in the <file> tag?
Of course, the component itself will be packed in its own .zip, to be included in the Package's XML install file.
No there is no need to this tag in administrator tag. you missing some in manifest.xml
for fully doc try:-
http://docs.joomla.org/Developing_a_Model-View-Controller_Component/2.5/Adding_an_install-uninstall-update_script_file
http://docs.joomla.org/Components:xml_installfile
on my end manifest.xml (my .sql in admin/install/install.mysql.utf8):-
<?xml version="1.0" encoding="utf-8"?>
<extension type="component" version="2.5" method="upgrade">
<name>Social</name>
<license>Open Source License, GPL v2 based</license>
<author>me</author>
<authorEmail>developers#me.com</authorEmail>
<authorUrl>http://www.me.com</authorUrl>
<creationDate>2012-01-01</creationDate>
<copyright>2013, me</copyright>
<version>1.1</version>
<description></description>
<!-- Installation -->
<install>
<sql>
<file driver="mysql" charset="utf8">install/install.mysql.utf8.sql</file>
</sql>
</install>
<installfile>install/install.php</installfile>
<uninstall>
<sql>
<file driver="mysql" charset="utf8">install/uninstall.mysql.utf8.sql</file>
</sql>
</uninstall>
<uninstallfile>install/uninstall.php</uninstallfile>
and rest of

How to create a simple administration panel for my joomla plugin

I think the problem lies in my xml.
<?xml version="1.0" encoding="UTF-8"?>
<extension version="2.5" type="plugin" group="content">
<install>
<name>Content - eya</name>
<author>eya</author>
<creationDate>February 2013</creationDate>
<copyright>(C) 2013 Open Source Matters. All rights reserved.</copyright>
<license>GNU General Public License version 2 or later; see LICENSE.txt</license>
<authorEmail>anigag#grzeit.com</authorEmail>
<authorUrl>www.eya.com</authorUrl>
<version>2.5.0</version>
<description>Adds eya plugin ot your site</description>
<files>
<filename plugin="eya">eya.php</filename>
</files>
</install>
<administration >
<filename>admin.php</filename>
</administration>
</extension>
This is my main php file that executes the content:eya.php.
I have got another file (admin.php) that takes 2 session variables from eya.php and put them in an iframe. There are two problems. One is that I dont know if the eya.php runs everytime before admin.php (or at least once to set the session variables). The second problem is that I dont know how to display only the admin.php and nothing else.
to build an admin interface for your plugin just add the config part to your xml
<config>
<fields name="params">
<fieldset name="basic">
<field name="testfield" type="text" default="mytest" label="field_label" description="field_description" />
</fieldset>
</fields>
</config>
but I didn't get the part of your admin.php/eya.php

Magento Module for new CMS layout, but in version 1.7.0.2

I'm trying to simply create a new layout option for a CMS page in Magento. I've followed the instructions here on the Magento wiki to create a module and it does not work. When I make the same addition to the actual core config.xml file, it works fine, but not as a custom module. Based on some research it looks like this would have worked in Magento 1.6, but does not work on 1.7, I'm trying to figure out why. I have the following:
app/etc/modules/Fruit_Banana.xml
<?xml version="1.0"?>
<config>
<modules>
<Fruit_Banana>
<active>true</active>
<codePool>local</codePool>
<depends>
<Mage_Page />
</depends>
</Fruit_Banana>
</modules>
</config>
app/code/local/Fruit/Banana/etc/config.xml
<?xml version="1.0"?>
<config>
<modules>
<Fruit_Banana>
<version>0.1.0</version>
</Fruit_Banana>
</modules>
<global>
<page>
<layouts>
<homepage_middle translate="label">
<label>Homepage</label>
<template>page/homepage.phtml</template>
<layout_handle>homepage_one</layout_handle>
</homepage_middle>
<!-- add more layouts here -->
</layouts>
</page>
</global>
</config>
Any ideas why it doesn't seem to be working as a module? I am using version 1.7.0.2
The local modules should be in the code directory
app/code/local/Fruit/Banana/etc/config.xml
and not in the core directory as you mentioned
app/code/core/local/Fruit/Banana/etc/config.xml
Well seems like I messed up! It does in fact work in 1.7, my problem was I had the filename for config.xml spelled confix.xml
Once I adjusted that, the custom layout popped right up! Thanks to those that chimed in.

Resources