Thursday, March 20, 2008

Redirect SharePoint Site to New Location

I recently had a request to move a SharePoint subsite to a new location under a different site collection.  The site was moved over after performing the standard import/export stsadm commands.  However, the customer also wanted the old location to perform an automatic redirect for anyone still pointing to the old location.  I wanted to be able to do this without having hack up pages using designer (or other tool) or having to allow for code blocks within the default.aspx by opening my web.config up to vulnerabilities.  I found the easiest way to do this was with Javascript and a Content Editor Web Part.

  1. Add a Content Editor Web Part to the Main Page of the site.
  2. Modify the Web Part and click on Source Editor.
  3. Paste in the following code while changing the URLs to match your target.

    <SCRIPT language="JavaScript">
    function redirectsp()
       if (top.frames.length==0)
  4. <body>
    Redirecting you to the new location.  If you are not redirected, click <a href="

  5. I set the redirect time to 0, but you can set it higher if you like.  1 sec = 1000, 2 sec = 2000, etc.
  6. Save the code changes.

The fun part of this solution is the fact that the code tries to load no matter what view you are in (i.e. Standard view, Edit Page, etc).  So, if you have to make changes to the code you have to let the page load but then time a press of the ESC key to keep the Javascript from loading each time.


Friday, March 14, 2008

WSU Windows Mobile Theme - Go Cougs!!

In the spirit of my alma mater, Washington State University, and the great basketball season they are having I am posting the Windows Mobile theme I created.  It has the Cougar logo on the vertical today screen and a shot of Pullman with Bryan Tower on the horizontal today screen.


Go Cougs!!


Thursday, March 13, 2008

Patch to Fix Presence in SharePoint and Outlook 2007

I ran into presence not appearing in SharePoint or Outlook 2007 after my upgrade to Communicator 2007.

Microsoft recently released a patch to fix this issue.

Thought I would pass it along...


Friday, March 7, 2008

Crawling a Content Source Requiring Basic Authentication

As much as I fight basic authentication, there are still people out there who want to use it.  SharePoint Enterprise Search can crawl a site requiring basic authentication through the use of Crawl Rules.

  1. Browse to the Shared Services Provider page within Central Administration.

  2. Click on Search Settings -> Content sources and crawl schedules.

  3. I recommend adding the source as a new content source.

  4. Once you have created the new content source return to the Search Settings screen.

  5. Click on Crawl Rules -> New Crawl Rule.

  6. Enter the path this rule will affect.  Using wildcards is the easiest way to make sure the enter server is being crawled with the account specified.

  7. Change the crawl configuration to 'Include all items in this path'.  Specify other settings if necessary.

  8. Change the authentication to 'Specify a different content access account'.

  9. DO NOT CHECK 'Do not allow Basic Authentication'.

  10. Click OK to save the settings and your new crawl rule will appear in the list.

  11. Kick off a full crawl of the content source for the rule to take effect.

Simple I know.  But I was hit up for this multiple times so I figured I would write a post on it.


Who Doesn't Love Free Online Disk Space?

So I was just playing around with Windows Live Writer to test it out for posting to my blog and discovered Windows Live SkyDrive.  Free 5 GB worth of disk space and you can store personal files, share with your Live Messenger friends, or share out to the general population.

The interface is very easy to use.

Windows Live SkyDrive Site:

SkyDrive Team Blog:

SkyDrive Viewer from ScottIsAFool on CodePlex: