Posts

Showing posts from August, 2005

Google Desktop and Firefox

Some may have figured this out already, or use the GDS install tool at Horopter.com (which also contains instruction on how to do it manually). There is an easier way than this (the files are actually part of the Google Desktop install): Go to C:\Program Files\Google\Google Desktop Search Copy the files GoogleDesktopMozilla.src and GoogleDesktopMozilla.png Go to C:\Program Files\Mozilla Firefox\searchplugins Then paste the files into this folder You can also create a batch script to do it as well: @echo off cd "%ProgramFiles%\Google\Google Desktop Search\" echo Copying GoogleDesktopMozilla.src copy GoogleDesktopMozilla.src "%ProgramFiles%\Mozilla Firefox\searchplugins\" echo Copying GoogleDesktopMozilla.png copy GoogleDesktopMozilla.png "%ProgramFiles%\Mozilla Firefox\searchplugins\" Tags: Web Developer Blog , Google , Google Desktop

LinkList Class (JavaScript, HTML)

Client-side version of LinkList Class (C#, ASP.NET) . Works in a similar way: var links = new WebDeveloperBlog.LinkList(); links.Add("Home", "home.aspx", "Home Page"); links.Add("Page 1", "test.html"); links.Add("Page 2", "page2.aspx"); links.Add("Page 3", "page3.aspx"); // need to set CssClass for 'Inline' and 'Block' types links.CssClass = "myclass"; // use inline type (surround with span tags) links.ListType = "Inline"; document.write("<p>Inline ListType<\/p>" + links.ToString()); // use block type (surround with div tags) links.ListType = "Block"; // change separator links.Separator = " | "; document.write("<p>Block ListType<\/p>" + links.ToString()); // use ordered list type (surround with ol, li tags) links.ListType = "OrderedList"; document.write("<p>OrderedList ListType

Google Talk

Seems Google Talk , Google's instant messenger service, is now available. Uses the open source Jabber/XMPP protocol. Because of this, it is more cross platform friendy - i.e. you can cmmunicate with users on Mac, Linux etc - but not with AIM or MSN Messenger users. Requires a Gmail account. Very basic, no rich text or smilies. Links to Gmail inbox and allows you to email by clicking the familiar Gmail logo next to a name. Tags: Web Developer Blog , Google Talk

Get tags using CSS selectors (Javascript)

These functions query a web page and gets all elements using CSS selectors. Could be seen as more powerful versions of getElementByTagName. cssQuery is by the author of IE7 (not the new browser being developed by Microsoft, but a hack to improve CSS support in IE 5 or later). It has recently had an update to cssQuery Version 2 to support more selectors. getElementsBySelector is similar to this and is less powerful and is used via document.getElementsBySelector. An example of where this might be useful is if you wanted to change all links that opened in a new window to open in the current window instead and be made bold: var tags = cssQuery("a[target='_blank']"); for(i=0;i<tags.length;i++) { tags[i].setAttribute("target", ""); tags[i].style.fontWeight = "bold"; } Tags: Web Developer Blog , CSS , Javascript

LinkList Class (C#, ASP.NET)

This class can be used to generate a list of links that could be used for breadcrumbs or menu navigation. Add items to the list as follows (1st parameter is text, 2nd is the page url and 3rd is the tooltip, which is optional): LinkList links = new LinkList(); links.Add(new LinkList.Link("Home", ResolveUrl("home.aspx"), "Home Page")); links.Add(new LinkList.Link("Page 1", ResolveUrl("page1.aspx"))); links.Add(new LinkList.Link("Page 2", ResolveUrl("page2.aspx"))); links.Add(new LinkList.Link("Page 3", ResolveUrl("page3.aspx"))); // need to set CssClass for 'Inline' and 'Block' types links.CssClass = "myclass"; There are four types of list types. Shown in the order they are added in. Also, if the current page you are on is the same as one in the list, the text is displayed instead of the link. One is 'Inline', which surrounds the links with a span tag (only if yo

Recursive File List Control v2 (ASP.NET)

Much like the original Recursive File List Control , this user control lists files and folders within a virtual web folder. Improvements include - excludes directories ending in '_file' (i.e. those created by Internet Explorer when you download a web page), excludes files beginning with '~$' (i.e. temporary documents generated by Microsoft Office applications), multiple instances can be placed on a web page, postback does not end up causing duplication of list and it takes into account other querystring parameters that may be passed on to the page. Control (filelist.ascx) <%@ Control Language="C#" src="filelist.ascx.cs" Inherits="WebDeveloperBlog.RecursiveFileList" %> Code behind (filelist.ascx.cs) using System; using System.Collections; using System.Collections.Specialized; using System.IO; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; namespace WebDeveloperBlog { public class RecursiveFileList : UserCo