SiteKiosk Documentation
One Step Back

SiteCoach Object




The SiteCoach object controls the environment of the SiteCoach plugin.


Members Table

    The following table lists the members provided by the SiteCoach object.

    Members
    PropertiesDescription
    ClearCacheOnStartupIf the cache should be cleared on startup.
    EnabledIf SiteCoach is enabled.
    FilterStateIf the SiteCoach filter is active.
    NameName of this plugin.
    EventsDescription
    OnBlockURLFires when an URL is blocked.
    OnFilterStateChangedFires when the filter status changed.

Remarks
    This object is available through the collection Plugins. Use the SiteCoach object to enable or disable blocking web pages or to get settings of this plugin.

    Note that the path of a file using SiteKiosk objects must be allowed in the
    SiteKiosk configuration (Security -> Access -> URL's With Script Permission)
    if it is not a browser skin file.
Examples
    The following example shows information about the SiteCoach plugin.

    <html>
    <body>
    <table border="0" bgcolor="#ebebeb" width="600" cellspacing="5"
    cellpadding="5" style="font-family:verdana;font-size:8pt;"
    align="center">
    <tr><td bgcolor="f8f8f8">
    Try to open the forbidden URL when the SiteCoach [Plug-In]
    filter is activated.
    </td></tr>
    <tr><td style="font-family:verdana;font-size:8pt;">
    <pre>
    <SCRIPT TYPE="text/javascript">
    window.external.InitScriptInterface();
    if (SiteKiosk.Plugins('SiteCoach').Enabled)
    {
       coachstatus = "SiteCoach Plugin is active";
       if (SiteKiosk.Plugins("SiteCoach").FilterState)
       coachfilterstatus = "activated";
       else coachfilterstatus = "deactivated";
    }
    else
    {
       coachstatus = "SiteCoach Plugin has not been configured";
       coachfilterstatus = "-";
    }
    document.writeln("Status: " + coachstatus);
    document.write("<span id='id_scoachfilter'>Filter: " +
    coachfilterstatus + "</span>");
    function adswitch()
    {
       if (SiteKiosk.Plugins('SiteCoach').Enabled)
       {
          SiteKiosk.Plugins("SiteCoach").FilterState =
          !SiteKiosk.Plugins("SiteCoach").FilterState;
       } else alert("SiteCoach Plugin has not been configured");
    }
    function openurl()
    {
       window.open("http://www.sex.com");
    }
    SiteKiosk.Plugins("SiteCoach").OnFilterStateChanged = OFSChanged;
    function OFSChanged()
    {
       if (SiteKiosk.Plugins("SiteCoach").FilterState)
       coachfilterstatus = "activated";
       else coachfilterstatus = "deactivated";
       id_scoachfilter.innerHTML = "Filter: " + coachfilterstatus;
    }
    </SCRIPT>
    </pre>
    </td></tr>
    </table>
    <br><br>
    <div align="center">
    <a href="javascript:adswitch()">Activate / Deactivate</a>
    &nbsp;
    <a href="javascript:openurl()">Open URL</a>
    </div>
    </body>
    </html>
    

Applies to
    SiteKiosk v5.0 (and later versions).

Back to topBack to top

© 1997-2008 PROVISIO - Chicago, USA & Muenster, Germany - SiteKiosk DevTeam