| 1 | <% |
|---|
| 2 | |
|---|
| 3 | ' |
|---|
| 4 | ' = ASP Stats Generator - Powerful and reliable ASP website counter |
|---|
| 5 | ' |
|---|
| 6 | ' Copyright (c) 2003-2008 Simone Carletti <weppos@weppos.net> |
|---|
| 7 | ' |
|---|
| 8 | ' Permission is hereby granted, free of charge, to any person obtaining a copy |
|---|
| 9 | ' of this software and associated documentation files (the "Software"), to deal |
|---|
| 10 | ' in the Software without restriction, including without limitation the rights |
|---|
| 11 | ' to use, copy, modify, merge, publish, distribute, sublicense, and/or sell |
|---|
| 12 | ' copies of the Software, and to permit persons to whom the Software is |
|---|
| 13 | ' furnished to do so, subject to the following conditions: |
|---|
| 14 | ' |
|---|
| 15 | ' The above copyright notice and this permission notice shall be included in |
|---|
| 16 | ' all copies or substantial portions of the Software. |
|---|
| 17 | ' |
|---|
| 18 | ' THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR |
|---|
| 19 | ' IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, |
|---|
| 20 | ' FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE |
|---|
| 21 | ' AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER |
|---|
| 22 | ' LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, |
|---|
| 23 | ' OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN |
|---|
| 24 | ' THE SOFTWARE. |
|---|
| 25 | ' |
|---|
| 26 | ' |
|---|
| 27 | ' @category ASP Stats Generator |
|---|
| 28 | ' @package ASP Stats Generator |
|---|
| 29 | ' @author Simone Carletti <weppos@weppos.net> |
|---|
| 30 | ' @copyright 2003-2008 Simone Carletti |
|---|
| 31 | ' @license http://www.opensource.org/licenses/mit-license.php |
|---|
| 32 | ' @version SVN: $Id$ |
|---|
| 33 | ' |
|---|
| 34 | |
|---|
| 35 | |
|---|
| 36 | ' |
|---|
| 37 | ' Checks whether a newer release is available |
|---|
| 38 | ' and returns an array with latest release version, date and url. |
|---|
| 39 | ' |
|---|
| 40 | public function asgVersionCheck(strCurrentVersion) |
|---|
| 41 | |
|---|
| 42 | Dim strHost, strVersion, strUrl, strResponse |
|---|
| 43 | Dim aryLastVersion |
|---|
| 44 | |
|---|
| 45 | strHost = Request.ServerVariables("HTTP_HOST") |
|---|
| 46 | strVersion = strCurrentVersion |
|---|
| 47 | strUrl = "http://www.weppos.com/asg/checkversion/check_update.asp?" &_ |
|---|
| 48 | "host=" & Server.URLEncode(strHost) & "&" &_ |
|---|
| 49 | "version=" & Server.URLEncode(strVersion) |
|---|
| 50 | |
|---|
| 51 | strResponse = asgHttpGetRequest(strUrl) |
|---|
| 52 | if varType(strResponse) = 8 then ' successful response |
|---|
| 53 | aryLastVersion = split(strResponse, "|") |
|---|
| 54 | else |
|---|
| 55 | aryLastVersion = array() |
|---|
| 56 | end if |
|---|
| 57 | |
|---|
| 58 | asgVersionCheck = aryLastVersion |
|---|
| 59 | |
|---|
| 60 | end function |
|---|
| 61 | |
|---|
| 62 | |
|---|
| 63 | %> |
|---|