Skip Navigation | Groups

This site uses cookies- for more information see the Cookie Policy | Continue

 

Search Application Installation

Package contents and installation


System Requirements

  • Windows Server running asp.NET 2.0 or later
  • SQL database - this can be SQL Server or any of the SQL Express or Compact forms.

Package Contents

Keywords.aspx
Allows generation of the keyword index for new (unindexed) pages, or reindexing of older pages that may have been edited.
Initial use will install the tables and views used by the search.
This page is password protected to restrict access to website administrators.
Keywords.aspx.vb
Code-behind file for keywords.aspx
seek.aspx
Page containing the search textbox -  for public use.
Search results are presented using the page titles as link text.
seek.aspx.vb
Code-behind file for seek.aspx
kpUpdate.aspx
This page allows page titles (as used by seek.aspx) to be edited specifically for the presentation of search results .
This page is password protected to restrict access to website administrators.
kpUpdate.aspx.vb
Code-behind for kpUpdate.aspx
lex.xml
xml file containing a list of words that will be ignored in the search. These words include:  be, are, you, we, us, the, etc 
search.config
Configuration file for the search pages - contains a reference to the database connection string, and a list of page extensions that will be searched.

Installation

Overview

It is assumed that the site already uses a SQL Server database.

Expand the .zip file into a folder and import the files into your website. All the files should be imported into the same folder.

Ensure that a suitable connection string is present in the web.config file (located in the websites root folder), and change references to this in search.config

Make the necessary changes (described below scroll down) in the code files (keywords.aspx.vb scroll down, kpUpdate.aspx.vb scroll down, search.config scroll down and web.config scroll down)

Open keywords.aspx in a browser (a server is required - either publish to your online website or use the Expression Web Development Server). Login and then click "Generate Website Keywords" button. This will create the required three tables and view in the database, and then find keywords from the web pages in the site and populate the tables.

Finally, style the pages to suit the website.

Required Code Changes

web.config
If necessary, add a connection string. The string this site (www.rxs-enterprises.org) uses is similar to:
<configuration>
... other entries ...
<connectionStrings>
<add name="myConnectionStringName" 
connectionString="Data Source=serverName;
Initial Catalog=databaseName;
Persist Security Info=True;
User ID=user;
Password=password" 
providerName="System.Data.SqlClient" />
</connectionstrings>
... other entries ...
</configuration>
There may be a suitable connection string already in place. Make a note of the name - it will be used by the other pages. Other connection strings (for different variants of SQL Server) can be found at http://connectionstrings.com.
keywords.aspx.vb
  • About line 12 - Change the default password to a strong, memorable word or phrase. This is case sensitive. The password should be the same as that used by kpUpdate.aspx.
    'Edit following lines:
    Dim psswrd as String = "mypassword"
    'End required edits
    
seek.aspx.vb
  • No changes required
kpUpdate.aspx
  • About line 10 - Change the default password to a strong, memorable word or phrase. This is case sensitive. The password should be the same as that used by keywords.aspx.
    'Edit following lines:
    Dim psswrd as String = "mypassword"
    'End required edits
    
search.config
  • Change the connection string name to that used in the web.config file (described above)
  • Add to or Delete from the extensions list in <validextensions>
    <config>
    <connectionstringname>myConnectionStringName</connectionstringname>
    <validextensions>.htm .html .asp .aspx</validextensions>
    </config>