Powered By Blogger

Thursday, February 3, 2011

Create Updater fror XPI

<?xml version="1.0"?>
<r:RDF xmlns:r="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
        xmlns="http://www.mozilla.org/2004/em-rdf#">
<r:Description about="urn:mozilla:extension:{d17e6cb0-f2ff-11df-98cf-0800200c9a66}">
    <updates>
    <r:Seq>
    <r:li>
    <r:Description>
        <version>2.2</version>
        <targetApplication>
            <r:Description>
            <id>{ec8030f7-c20a-464f-9b0e-13a3a9e97384}</id>
            <minVersion>1.5</minVersion>
            <maxVersion>3.8.*</maxVersion>
            <updateLink>http://www.ddemo.com//demo.xpi</updateLink>
            <updateHash>sha1:42eea7ea61bf1bd8a0d160626bde05e9c6e847b9</updateHash>
            </r:Description>
        </targetApplication>
    </r:Description>
    </r:li>
    </r:Seq>
    </updates>
</r:Description>
</r:RDF>

--UpdateHash can be created with software HashCheck.
--Use McCoy Software to verify update.rdf file.
--Put update.rdf file on server in a path same as described in install.rdf

2 comments:

  1. I have studied this code but there is no idea how to use code for toolbar development. Please share details information with steps.

    ReplyDelete
    Replies
    1. Leon :
      To create updator for extension you need 2 things-
      1. Server (https:// or http://)
      2. Update.rdf

      Also, location of update.rdf should be pre-defined in install.rdf.

      Sample syntax for update.rdf are same as above.

      Steps :-
      1> First install Hash Check software in your PC,
      2> Right Click on XPI file and create Hash file for
      same.
      3> Create Update.rdf using above sample and put hash
      information there.
      4> Put new version in update.rdf
      5> McCoy Software will check and correct update.rdf
      automatically.
      6> Put update.rdf in same location as it was mentioned
      in xpi file.

      Firefox will automatically prompt for update, user can skip the installation but Firefox will again remind user for update.

      You can use silent installer created in different programming language like(VB, VC++, C#) to update your extension silently.After updation user will get updated extension without any prompt.

      --- Enjoy | cheers ---

      Delete