WYLD TECHNOTE 97
Date: 04/19/2005Subject: Catalog Access Links for web developers (note - this technote assumes familiarity with HTML)
Some libraries may wish to create their own catalog access page in order to highlight local resources or additional databases as well as the standard resources linked from default pages at http://wyld.state.wy.us. (also known as 'welcome screens'.) The following technote provides the syntax for creating links to your catalog, a quick form for keyword searching, and examples of searches embedded in URLs.
Linking to your WYLDCAT catalog
To link to your WYLDCAT catalog, you must pass login information in the body of the URL. An example hyperlink will look like this:
http://wyld.state.wy.us/uhtbin/cgisirsi/x/0/0/57/49?user_id=wslwebSimply replace the portion after 'user_id=' with your catalog userid. This is typically your library policy name followed by the word 'web'. E.g. larmweb, larm-burnweb, larm-genweb. If you are unsure of your library policy name, please contact the WYLD Office. There must be no spaces in the URL
Creating a form that will launch a quick keyword search in the library catalog
To place a basic form on a webpage that will launch a search you need to have the following information:
- The login information in the form action statement. You must provide the user_id or the search will not use your WYLDCAT environment. See above for more information about the user_id for your library.
- The srchfield1, searchoper1, search_type1, and library as hidden fields. The library value is your library's Policy name. If you do not include your library's policy name, the search will not limit to your library.
- Search terms are passed to the server through the 'searchdata1' field.
- See the example below and replace the WWCC information with your own library's information to use this form.
<form NAME="searchform" METHOD=POST ACTION="http://wyld.state.wy.us/uhtbin/cgisirsi/x/0/0/57/5?user_id=wwccweb"> <INPUT TYPE="hidden" NAME="srchfield1" VALUE="GENERAL^SUBJECT^GENERAL^^keyword"> <INPUT TYPE="hidden" NAME="searchoper1" VALUE="AND"> <INPUT TYPE="hidden" NAME="search_type1" VALUE="KEYWORD"> <!-- add these lines with your library policy name as 'library' to limit search--> <INPUT TYPE="hidden" NAME="library" VALUE="WWCC"> <INPUT TYPE="hidden" NAME="new_gateway_db" VALUE=""> <INPUT TYPE=text name=searchdata1 size=10 maxlength=255 value=""> <INPUT TYPE="submit" VALUE="Search"> </form>
To offer multiple choices for locations to search, change the line:
<INPUT TYPE="hidden" NAME="library" VALUE="WWCC">to a select list, like below. *you will need the policy names for the libraries you wish to search:
<SELECT name="library" id="library" ">
<option value="WWCC">Western Wyoming College</option>
<option value="SWTRLIBS">Sweetwater County Library</option>
<option value="ALL">All WYLD Libraries</option>
</SELECT>
Creating links to pre-determined searches in URLs
Your url cannot have any spaces in it and must contain the following elements:
- user_id value (to log in to your library environment)
- searchdata1 value (terms to search, concatenate additional terms with a '+' sign. E.g. nutrition+sports )
- library value (to limit the search results)
Examples: (the code is too long to display on one line, but it must appear as one line with no spaces in your code for it to work!)
- KEYWORD SEARCH syntax:
http://wyld.state.wy.us/uhtbin/cgisirsi/x/0/0/57/5?user_id=larmweb
&library=LARM
&searchdata1=bison
&srchfield1=GENERAL^SUBJECT^GENERAL^^keyword
&searchoper1=AND
&search_type1=KEYWORDNOTE: If you do not include a 'srchfield1' value, then searches that fail will go to a 'no hits' page in the catalog which offers options to search again with different words, or to search all libraries. If you DO include the srchfield1 value in your url, then a failed search will result in a browse index display which may be more helpful to the user.
- ISSN SEARCH syntax: (include the catalog field to limit to ISBN '{22}' in the searchdata1 statement )
http://wyld.state.wy.us/uhtbin/cgisirsi/x/0/0/57/5?user_id=larmweb
&library=LARM
&searchdata1=0037-301X{022}
&srchfield1=GENERAL^SUBJECT^GENERAL^^keyword
&searchoper1=AND
&search_type1=SUBJECT
- ISBN SEARCH syntax: (include the catalog field to limit to ISBN '{20}' in the searchdata1 statement )
http://wyld.state.wy.us/uhtbin/cgisirsi/x/0/0/57/5?user_id=larmweb
&library=LARM
&searchdata1=087113795X{020}
&srchfield1=GENERAL^SUBJECT^GENERAL^^keyword
&searchoper1=AND
&search_type1=SUBJECT - AUTHOR SEARCH syntax:
http://wyld.state.wy.us/uhtbin/cgisirsi/x/0/0/57/5?user_id=larmweb
&library=LARM
&searchdata1=perry+anne
&srchfield1=AU^AUTHOR^AUTHORS^^author
&searchoper1=AND
&search_type1=AUTHOR - TITLE SEARCH syntax:
Edit the keyword sample URL, replacing the following:
use srchfield1=TI^TITLE^TITLE^SERIES^^title
use search_type1=TITLE
put the title word or words in the searchdata1 section. e.g. searchdata1=m+is+for+malice - SUBJECT SEARCH syntax:
Edit the keyword sample URL, replacing the following:
use srchfield1=SU^SUBJECT^SUBJECTS^^subject
use search_type1=SUBJECT
put the subject word or words in the searchdata1 section. e.g. searchdata1=geographic+information+systems - SERIES SEARCH syntax:
Edit the keyword sample URL, replacing the following:
use srchfield1=SER^SERIES^SERIES^^series
use search_type1=SERIES
put the series word or words in the searchdata1 section. e.g. searchdata1=boxcar+children - PERIODICAL TITLE SEARCH syntax:
Edit the keyword sample URL, replacing the following:
use srchfield1=PER^PERTITLE^SERIES^Title
use search_type1=TITLE
put the title word or words in the searchdata1 section. e.g. searchdata1=better+homes+gardens
language= (e.g. &language=SPANISH)
item_type= (e.g. &item_type=BOOK or &item_type=VIDEO+OR+DVD+OR+DVD2)
item_2cat= (e.g. &item_2cat=ADULT or &item_2cat=JUVENILE)
pubyear= (e.g. pubyear=2003)
Direct links to other catalog results or pages:
http://wyld.state.wy.us/uhtbin/cgisirsi/x/0/0/57/36/1163/X/BLASTOFF?user_id=lcccweb&library=LCCCReplace the user_id and library parameters with your library specific information as outlined above.
http://wyld.state.wy.us/uhtbin/cgisirsi/x/0/0/57/1/774/X/BLASTOFF?user_id=albyweb&library=ALBYReplace the user_id and library parameters with your library specific information as outlined above.
http://wyld.state.wy.us/uhtbin/cgisirsi/x/0/0/57/1/1166/X/BLASTOFF?user_id=albywebReplace the user_id parameter with your library specific information as outlined above.
all libraries - http://wyld.state.wy.us/uhtbin/cgisirsi/x/0/0/60/1173/X
individual library - http://wyld.state.wy.us/uhtbin/cgisirsi/x/0/0/57/38/1179/X/BLASTOFF?user_id=natrweb&library=NATRReplace the user_id and library parameters with your library specific information as outlined above.
(7 day list) http://wyld.state.wy.us/New/[LIBRARY_POLICY].html
(30 day list) http://wyld.state.wy.us/New30/[LIBRARY_POLICY].htmlReplace the [LIBRARY_POLICY] value with your library's SirsiDynix policy name, eg NATR or ALBY-ROCK
http://wyld.state.wy.us/New/NATR.html
http://wyld.state.wy.us/New/ALBY-ROCK.html
more technotes | technical support | network members
