Set up an OpenOPAC search embedded in a web page
Learn how to embed an OpenOPAC search onto a web page.
It is possible to insert a search box on website pages outside of the Amlib OpenOPAC environment that targets the OpenOPAC search screen, such as your library or School webpage.
Embedded Code to Insert into Page
- Copy the following OpenOPAC code below , in the web page into which you wish to add the search box, where you wish to insert the Search box:
- Please Note: Replace <hostname/> in the code above with the actual IP or Server Name (hostname) used by your OpenOPAC setup.
- For example… embedding the OpenOPAC address for localhost will result in the Search box being formed & code will be as shown below
- To make this step easier Copy & Paste the code below between the <body> </body> tags in the web page into which you wish to add the search box to.
<form id="myform" action="http://localhost/OCLC.OPEN.Frontend/Main.aspx" method="GET">
Search for items: <input type="text" name="search" id="search">
<input type="submit" name="submit" value="Go">
<p>Or choose the full <a href="http://localhost/OCLC.OPEN.Frontend/Main.aspx" target="_blank"
title="Library Catalogue">Library catalogue</a> with additional features.</p>
- Once it exists on your Webpage, simply type in your search and select Go
- You OpenOPAC page will open with the search results found
- OR Select Library Catalogue – to do a specific search within the Full application from your Webpage, which will take you to the Full OpenOPAC application where a Basic or Advanced Search is possible