Lozinski's "Updated" Updated! Scripts

Whether you have Unix or Windows Server, running ASP/VBScript, .NET, JSP, or PHP, here's an easy way to automatically keep track, print, and notify your users when a webpage on your website has been "updated"!

  LANGUAGE
    ASP/VBScript .NET JSP PHP
PLATFORM/OS Windows Server Available
Available
Available
Available
Unix - - Available
Available
My "Updated" Updated! scripts' features:
  1. Display to your users an "updated" image (Updated!), the textual date a page was updated, or both!

    See my scripts homepage for examples. Look for the Updated! image!

  2. Use your own custom "updated" image!


  3. Specify the length, in days, the "updated" notification should appear!
    You can have "updated" displayed for 14 days for one file, 5 days for another file, and always for yet a third file!

  4. Works on any kind of file: asp, aspx, php, html, gif, jpg, pdf, or any other file!

  5. Have one "updated" notification appear for one file or multiple files!
    Great if you have HTML "frame" documents and you want ONE (instead of many) "updated" notification to be displayed if ANY of the "frame" documents are updated!

SEE MY SCRIPTS IN ACTION!

Note: My service provider does not support ASP, .NET, or JSP, so I can only have the PHP demos online. The ASP, .NET, and JSP scripts display the exact same results.

Used on my "homepage"
This script is used on my homepage!
Just look for any of the "updated" (Updated!) images!

Used on my "Scripts homepage"
This script is used on my "scripts" homepage!
Just look for any of the "updated" (Updated!) images with the dates!

DOWNLOAD MY SCRIPTS!

ASP/Active Server Pages Visual Basic Script:
updated.asp is the complete ASP/VBScript source code.

Requirements:
  1. Windows NT or later
  2. IIS 4.0 or later

Basic Installation/Configuration Instructions:
  1. Download the ASP version here (a plain ascii-dos text file) onto your system. There are many ways this script can be installed and used. The procedure is what I recommend for ASP beginners. If you're more advanced and know what you're doing, by all means feel free to install this script however you wish.


  2. Save the ASP code in a separate file entitled "updated.asp" in your root web directory.


  3. In your ASP files where you will have the "updated" information displayed, be sure to "include" the "updated.asp" file.

    EXAMPLE:
    <!--#include file="updated.asp"-->


  4. Set the value for UPDATED_IMAGE_URL to be the URL to the "updated" image you wish to have displayed.

  5. Call the function "PrintUpdatedInfo" with the appropriate parameters (as described in the source code) wherever you wish to have the "updated" notification displayed.

    EXAMPLES:
    PrintUpdatedInfo ("F:/Inetpub/wwwroot/test.asp",3,2)
    PrintUpdatedInfo ("F:/Inetpub/wwwroot/test.asp|F:/Inetpub/wwwroot/default.asp",7,0)



.NET:
updated.vb is the complete VB .NET Class file source code.

Requirements:
  1. Windows 2000 or later
  2. IIS 5.0 or later
  3. .NET Framework 1.1 or later

Basic Installation/Configuration Instructions:
  1. Download the VB.NET Class file here (a plain ascii-dos text file) onto your system.


  2. Set the value for UPDATED_IMAGE_URL to be the URL to the "updated" image you wish to have displayed.


  3. Compile this VB .NET code and move the resulting dll file into your web project's "bin" directory.


  4. In the aspx page you wish to have this control run, add in the appropriate "Register" directive.

    EXAMPLE:
    <%@ Register TagPrefix="Lozinski" Namespace="Updated.LozinskiWebScript" Assembly="Updated" %>


  5. Add the control's tag to your ASPX page and set the properties (as described in the source code) wherever you wish to have the "updated" notification displayed.

    EXAMPLES:
    <LOZINSKI:UPDATED ID="Updated1" RUNAT="server" FILELIST="F:/Inetpub/wwwroot/scripts/updated/updated.aspx" DAYDIFFERENCE="3" DISPLAYMODE="1" />

    <LOZINSKI:UPDATED ID="Updated1" RUNAT="server" FILELIST="C:/Inetpub/wwwroot/menu.html" DAYDIFFERENCE="-1" DISPLAYMODE="1" />




JSP:
updated.jsp is the complete JSP source code.
This script will should run "as is" on either Unix or Windows Server with JSP installed provided you meet the requirements.

Requirements:
  1. Java J2EE version 1.3.1 or greater.
  2. Unix or Windows Server

Basic Installation/Configuration Instructions:
  1. Download the basic jsp version here (a plain ascii-dos text file) onto your system. There are many ways this script can be installed and used. The procedure is what I recommend for JSP beginners. If you're more advanced and know what you're doing, by all means feel free to install this script however you wish.


  2. Save the JSP code in a separate file entitled "updated.jsp" in your root web directory.


  3. In your JSP files where you will have the "updated" information displayed, be sure to "include" the "updated.jsp" file.

    EXAMPLE:
    <%@ include file="updated.jsp" %>

  4. In those same JSP files, if they do not use the java.util or java.io packages, import those:
    <%@ page import="java.io.*,java.util.*;" %>

  5. Set the value for UPDATED_IMAGE_URL to be the URL to the "updated" image you wish to have displayed.


  6. Call the function "PrintUpdatedInfo" with the appropriate parameters (as described in the source code) wherever you wish to have the "updated" notification displayed.

    EXAMPLES:
    PrintUpdatedInfo ("/var/home/htdocs/test.jsp",3,2,out)
    PrintUpdatedInfo ("F:/Inetpub/wwwroot/test.jsp|F:/Inetpub/wwwroot/default.asp",7,0,out)




PHP:
updated.php is the complete PHP source code.
This script will should run "as is" on either Unix or Windows Server with PHP installed provided you meet the requirements.

Requirements:
  1. PHP version 4.0.3 or greater.
  2. Unix or Windows Server

Basic Installation/Configuration Instructions:
  1. Download the basic php version here (a plain ascii-dos text file) onto your system. There are many ways this script can be installed and used. The procedure is what I recommend for PHP beginners. If you're more advanced and know what you're doing, by all means feel free to install this script however you wish.


  2. Save the PHP code in a separate file entitled "updated.php" in your root web directory.


  3. In your PHP files where you will have the "updated" information displayed, be sure to "include" the "updated.php" file.

    EXAMPLE:
    include ("updated.php");

  4. Set the value for $UPDATED_IMAGE_URL to be the URL to the "updated" image you wish to have displayed.


  5. Call the function "PrintUpdatedInfo" with the appropriate parameters (as described in the source code) wherever you wish to have the "updated" notification displayed.

    EXAMPLES:
    PrintUpdatedInfo ("F:/Inetpub/wwwroot/test.php",3,2)
    PrintUpdatedInfo ("F:/Inetpub/wwwroot/test.php|F:/Inetpub/wwwroot/default.asp",7,0)


DISCLAIMERS