Web Part Package Installer for Windows SharePoint Services 2003

Mark Wagner
June 20, 2005

For those of us who are familiar with installing and removing SharePoint web parts, it’s a pretty easy process. However, for those individuals who spend more time using SharePoint than installing and configuring it; locating and using the STSADM command can be a bit tedious. To help simplify the installation of web parts, I have created a simple Web Part Package Installer program.

The purpose of this program is to make the installation of web part packages much easier for less-technical people. Web Part Packages are stored in files having a .CAB file extension. The nice thing about a web part package is that a package can define some initial properties and configuration settings for the web part being installed. This is where my Web Part Package Installer program may be useful.

The Web Part Package Installer program will only install web part packages. The Web Part Package Installer will not install a web part using a web part description (.dwp) file, or a web part assembly (.dll) file. If you only have a web part assembly file, I highly recommend using the InstallAssemblies program by Blue Dog Limited.

Use At Your Own Risk

There is no warranty express or implied. You may use it free of charge.

Download Files

Installing the Web Part Package Installer

Before you can use the Web Part Package Installer program, you must download and run the Web Part Package Installer Setup program.  The Web Part Package Installer must be installed on your SharePoint web server.

  • Logon directly to your SharePoint web server with administrator access. If you do not have administrator access to your SharePoint web server, then you need to contact your SharePoint administrator before you may proceed.
  • Run the Web Part Package Installer Setup program and follow the setup dialogs until the setup process is done.
  • You should now have a new program on your Start > All Program > Castle Rock Software menu with the name of Web Part Installer.
  • Your Web Part Installer is now ready for use.

Using the Web Part Package Installer

The Web Part Package Installer is a very simple program. Before you can install any web parts you must make sure you are logged on to your SharePoint web server as a user with full rights to administer SharePoint.

Start the Web Part Package Installer program. To do this, go to the Start > All Programs > Castle Rock Software > Web Part Package Installer menu option.

  • The installer form is very simple.
    WPPI
  • Select the web part package (.cab) file to install to clicking the ellipse () button.
  • The “Overwrite an existing Web Part Package” option is usually not needed. You should normally leave this option un-checked. You only need to check this option if you want to replace the existing web part. This is usually only needed when an older version of a web part already exists on this web server.
  • When you are ready click the “Install Web Part Package” button. The web part has been successfully installed when you receive a message saying the web part is “Deploying”. Here is an example of the success message. Your message will be slightly different depending on the name of your server. 
    WPPIFail
  • If you receive a message like this instead, your web part package was not installed.
    WPPISuccess
    This message is indicating that a copy of the web part you are trying to install already exists on this server.  You can replace the existing web part package by selecting the “Overwrite..“ option.
  • The web part should now be available to add to your page(s) using the standard drag-and-drop normally used in SharePoint.

Google Search Web Part

Mark Wagner
June 10, 2005

Update: June 20, 2005
For those of you who need assistance with installing this web part, you can use my Web Part Package Installer program.  This installer program makes installing a web part package very easy.

Downloads
I have provided two downloads.

I created a custom Google web part a few weeks ago for my demo SharePoint site. The Google web part submits a search request by navigating the user directly to the Google search web page and performs a Google search using the Google search engine. I have since received a number of emails requesting to get this web part for use on their SharePoint sites.First and foremost, the Google name and search service are the property of Google. I have no affiliation with the Google name and its services.

Google is a must-have resource for my daily work. If I need to find something, I Google it, and nothing else comes close when searching on the Internet. With this dependency, I had to have it on my new SharePoint demo site.  My SharePoint demo site is more of a test-harness at this point since it is hosted on a shared/public server, so don’t be too disappointed when you see it.

For those of you not familiar with Google, welcome to the Internet. Google is the single best Internet search service available on the Internet, for the Internet. If you need to find something on the Internet, Google will find it for you. This process of searching is commonly referred to Googling. If you Google something, your are using Google to search the Internet for it. For the rest of you, Google is probably how you found this article.

It is important to remember that this Google Search web part is not intended to replace the SharePoint search feature. In order for Google to find any results, Google must have already searched and indexed your site. Also remember that Google will not be able to crawl and index pages on your SharePoint site that are not accessible to the public. This is where the SharePoint search has the upper hand. Again, this web part is not intended to replace the SharePoint search feature, but to conveniently access the much used Google search from your SharePoint page.

Configuring the Google Search Web Part

Here is a picture of the web part configurations.

GoogleSearchWPConfig

Google Image URL

Once you have installed the web part, in the configuration options of the web part is a Google Image URL property which defaults to an image on Google’s web site.  You should use the default url for the Google image. I have made this property available just in case Google renames or moves their image.

This Google Search Web Part can be configured in three distinct ways.


Standard Google Search

GoogleSearchWP

Local Site Search

GoogleSearchWPLocal

Custom Site Search

GoogleSearchWPCustom

Standard Google search
The standard search performs a normal Google search just as if you went to the Google web site and entered your search criteria.

Local Site Search (Using Google)
The local site check box is used to limit the Google search results to return only content that resides within the current site URL. The local site URL will be displayed in the Google Search Web Part to make this clear to the user. This allows the Google Web part to use the current site URL as the search scope. To be clear, the Google search engine is used to search for results for only those web pages that have the same domain as the current page.

Important Note: The Local Site check box may not stay checked. If this is the case, this is intentionally being unchecked by the web part when you save because the mechanism used to obtain the local site URL is not allowed due to the current security restrictions on SharePoint server. You will either need to have the server administrator grant the necessary access, or simply not use this option.

Custom Site URL (Using Google)
If you specify a custom URL, the custom URL is used to narrow the Google search results to return only the results that are located on the specified custom site/URL.

About the Downloads

The compiled assembly and web part package have been built with a strong name and therefore can be installed in the GAC if needed. This also allows for this assembly to be configured and used on SharePoint servers that have tighter security. If you are unable to compile, or simply wish to use my assembly, you can do so with the confidence knowing the full assembly name (including the version, public token, etc.) will only work with the compiled assembly I have provided in the web part package (.cab) file.

The source code is also available in a separate download; however, I have removed the Strong Name Key file to keep my compiled version secure from any bogus impersonators. You will need to create your own strong name key file and update the necessary manifest and web part description (.dwp) file to successfully deploy your web part assembly to your SharePoint server. For those who are interested in how this web part has been written, you can view the source, modify, and build your own Google Search Web Part.

How the Google Search Web Part works

This is a very simple web part. The entire Google search request is performed using the standard Google search URL along with a couple query string (URL) parameters.

The Google Search URL accepts a number of parameters. The only two we are concerned with are the search criteria and; optionally the site URL scope. The search criteria is appended to the URL with the “q=” parameter. Additionally, the “site=” parameter allows us to optionally narrow the scope the of the search results to the site URL provided.

Here is the base Google Search URL.

http://www.google.com/search

Here we have appended the search criteria to the URL.

http://www.google.com/search?q=mark+wagner+web+part

Finally, we here we have the Google Search URL with the search criteria and the site scope added to the URL. This will only return results that meet my search criteria AND exist on the blogs.crsw.com/mark site.

http://www.google.com/search?q=web+part+site:blogs.crsw.com/mark

This Google Search Web Part may be used – free. There is no implied warranty and you use it at your own risk. But how could you not.

Need Help Installing This Web Part?

If you need help installing this web part package, try using my Web Part Package Installer program to make this process easy.