Want to make tool to help create code box:
Code box is from Tutzone.Wanted tool to easily add code box to blog entries.
HTML, CSS, batch commands, and Javascript examples that I have used in my library work. Short entries, designed as quick reference.
By Len Davidson at CUA Law Library
1/23/2011
1/13/2011
How to embed Blog posts into web pages?
Using gfeedfetcher.js from dynamic drive. This takes RSS feed from a blog, and allows you to embed the content into a web page.
<script src="http://www.google.com/jsapi?key=Your-API-key" type="text/javascript">
</script>
<script src="http://your-server.com/gfeedfetcher.js" type="text/javascript">
</script>
<script type="text/javascript">
var cssfeed=new gfeedfetcher("example2", "test2class", "")
cssfeed.addFeed("CSS Drive", "URL of your ") //Specify "label" plus URL to RSS feed
cssfeed.displayoptions("description") //show the specified additional fields
cssfeed.setentrycontainer("p") //Display each entry as a list (li element)
cssfeed.filterfeed(5, "date") //Show 10 entries, sort by date
cssfeed.init() //Always call this last
</script>
</script>
<script src="http://your-server.com/gfeedfetcher.js" type="text/javascript">
</script>
<script type="text/javascript">
var cssfeed=new gfeedfetcher("example2", "test2class", "")
cssfeed.addFeed("CSS Drive", "URL of your ") //Specify "label" plus URL to RSS feed
cssfeed.displayoptions("description") //show the specified additional fields
cssfeed.setentrycontainer("p") //Display each entry as a list (li element)
cssfeed.filterfeed(5, "date") //Show 10 entries, sort by date
cssfeed.init() //Always call this last
</script>
1/02/2011
How to limit access to public PC? (Kiosk)
Our library has small number of Windows PCs totally open to public. We want to limit them to *.edu and specific .com sites (databases, etc). We had manually entered list of valid domains in each computer, but keeping updated was a pain.
Now we use an Automatic Configuration Script, basically its a javascript which says which domains are allowed.
Here is script we use:
Now we use an Automatic Configuration Script, basically its a javascript which says which domains are allowed.
- Samples of scripts & syntax. (Can be used to block ads & porn, another)
- Place on webserver (have to add .PAC extension to mime types)
- Then add to PC, we just use IE: Configuring IE, Firefox, & other browsers
Here is script we use:
//2011-Jan List of allowed sites for CUA Law Library
//Len Davidson x-6206
//
function FindProxyForURL(url, host)
{
if (isPlainHostName(host))
return "DIRECT";
else if (shExpMatch(url,"*cardinalmail*"))
return "DIRECT";
else if (shExpMatch(url,"*jsapi*"))
return "DIRECT";
else if (shExpMatch(url,"*google-analytics*"))
return "DIRECT";
else if (shExpMatch(host, "*.gov"))
return "DIRECT";
else if (shExpMatch(host, "*.us"))
return "DIRECT";
else if (shExpMatch(host, "*.org"))
return "DIRECT";
else if (shExpMatch(host, "*.edu"))
return "DIRECT";
else if (shExpMatch(host, "*.int"))
return "DIRECT";
else if (shExpMatch(host, "*.adobe.com"))
return "DIRECT";
else if (shExpMatch(host, "*.macromedia.com"))
return "DIRECT";
else if (shExpMatch(host, "*.microsoft.com"))
return "DIRECT";
else if (shExpMatch(host, "*.newsbank.com"))
return "DIRECT";
else if (shExpMatch(host, "*.bna.com"))
return "DIRECT";
else if (shExpMatch(host, "*.cch.com"))
return "DIRECT";
else if (shExpMatch(host, "*pf.com"))
return "DIRECT";
else if (shExpMatch(host, "*lexis-nexis.com"))
return "DIRECT";
else if (shExpMatch(host, "*.lexisnexis.com"))
return "DIRECT";
else if (shExpMatch(host, "*.lexis.com"))
return "DIRECT";
else if (shExpMatch(host, "*.silverplatter.com"))
return "DIRECT";
else if (shExpMatch(host, "*.odyssi.com"))
return "DIRECT";
else if (shExpMatch(host, "*.hwwilsonweb.com"))
return "DIRECT";
else if (shExpMatch(host, "*.indexmaster.com"))
return "DIRECT";
else if (shExpMatch(host, "*.irlweb.com"))
return "DIRECT";
else if (shExpMatch(host, "*.bvdep.com"))
return "DIRECT";
else if (shExpMatch(host, "*.galegroup.com"))
return "DIRECT";
else if (shExpMatch(host, "*.westlaw.com"))
return "DIRECT";
else if (shExpMatch(host, "*.loislawschool.com"))
return "DIRECT";
else if (shExpMatch(host, "*.paradigmpub.com"))
return "DIRECT";
else if (shExpMatch(host, "*.wrlc.org"))
return "DIRECT";
else if (shExpMatch(host, "*.wmata.com"))
return "DIRECT";
else if (shExpMatch(host, "*.googlesyndicatedsearch.com"))
return "DIRECT";
else if (shExpMatch(host, "*.windowsupdate.com"))
return "DIRECT";
else if (shExpMatch(host, "*.update.microsoft"))
return "DIRECT";
else if (shExpMatch(host, "windowsupdate.microsoft.com"))
return "DIRECT";
else if (shExpMatch(host, "*.symplicity.com"))
return "DIRECT";
else if (shExpMatch(host, "*.live.com"))
return "DIRECT";
// else if (shExpMatch(host, "*.com"))
//return "PROXY comproxy:80";
else
return "PROXY PROXY comproxy:80"; }
//Len Davidson x-6206
//
function FindProxyForURL(url, host)
{
if (isPlainHostName(host))
return "DIRECT";
else if (shExpMatch(url,"*cardinalmail*"))
return "DIRECT";
else if (shExpMatch(url,"*jsapi*"))
return "DIRECT";
else if (shExpMatch(url,"*google-analytics*"))
return "DIRECT";
else if (shExpMatch(host, "*.gov"))
return "DIRECT";
else if (shExpMatch(host, "*.us"))
return "DIRECT";
else if (shExpMatch(host, "*.org"))
return "DIRECT";
else if (shExpMatch(host, "*.edu"))
return "DIRECT";
else if (shExpMatch(host, "*.int"))
return "DIRECT";
else if (shExpMatch(host, "*.adobe.com"))
return "DIRECT";
else if (shExpMatch(host, "*.macromedia.com"))
return "DIRECT";
else if (shExpMatch(host, "*.microsoft.com"))
return "DIRECT";
else if (shExpMatch(host, "*.newsbank.com"))
return "DIRECT";
else if (shExpMatch(host, "*.bna.com"))
return "DIRECT";
else if (shExpMatch(host, "*.cch.com"))
return "DIRECT";
else if (shExpMatch(host, "*pf.com"))
return "DIRECT";
else if (shExpMatch(host, "*lexis-nexis.com"))
return "DIRECT";
else if (shExpMatch(host, "*.lexisnexis.com"))
return "DIRECT";
else if (shExpMatch(host, "*.lexis.com"))
return "DIRECT";
else if (shExpMatch(host, "*.silverplatter.com"))
return "DIRECT";
else if (shExpMatch(host, "*.odyssi.com"))
return "DIRECT";
else if (shExpMatch(host, "*.hwwilsonweb.com"))
return "DIRECT";
else if (shExpMatch(host, "*.indexmaster.com"))
return "DIRECT";
else if (shExpMatch(host, "*.irlweb.com"))
return "DIRECT";
else if (shExpMatch(host, "*.bvdep.com"))
return "DIRECT";
else if (shExpMatch(host, "*.galegroup.com"))
return "DIRECT";
else if (shExpMatch(host, "*.westlaw.com"))
return "DIRECT";
else if (shExpMatch(host, "*.loislawschool.com"))
return "DIRECT";
else if (shExpMatch(host, "*.paradigmpub.com"))
return "DIRECT";
else if (shExpMatch(host, "*.wrlc.org"))
return "DIRECT";
else if (shExpMatch(host, "*.wmata.com"))
return "DIRECT";
else if (shExpMatch(host, "*.googlesyndicatedsearch.com"))
return "DIRECT";
else if (shExpMatch(host, "*.windowsupdate.com"))
return "DIRECT";
else if (shExpMatch(host, "*.update.microsoft"))
return "DIRECT";
else if (shExpMatch(host, "windowsupdate.microsoft.com"))
return "DIRECT";
else if (shExpMatch(host, "*.symplicity.com"))
return "DIRECT";
else if (shExpMatch(host, "*.live.com"))
return "DIRECT";
// else if (shExpMatch(host, "*.com"))
//return "PROXY comproxy:80";
else
return "PROXY PROXY comproxy:80"; }
Subscribe to:
Posts (Atom)