However relying on your own code to do this isn't always the best option.
An alternative is to define the version information in the ScriptInfo.xml file and Plus! will automatically check the online database for a newer version (obviously once it is back up and online).
xml code:
<?xml version="1.0" encoding="UTF-16"?>
<ScriptInfo xmlns="urn:msgplus:scripts" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="urn:msgplus:scripts PlusScripts.xsd">
<Information>
<Name>Screenshot Sender</Name>
<Description>Allows you to easily send screenshots to your contacts.</Description>
<Author>matty, Mattias & Dempsey</Author>
<AboutUrl>http://beta.screenshotsender.com</AboutUrl>
<Version>5</Version>
>>> <UpdateId>SS5</UpdateId><<<
>>> <Build>0062</Build><<<
</Information>
</ScriptInfo>