Adding a Google Book Search Box to Your Product Pages

From AAUPwiki
Jump to: navigation, search

Tony Sanfilippo, Penn State Press

I asked Laura Driussi how Cambridge did it and she was kind enough to share the code. Remember, you have to be participating in the Book Search Publisher program for this to work.

Here's the code you would put on your pages:

SEARCH WITHIN THIS BOOK BOX CODE

<!-- Google Book Search --> <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="0"> <TR><TD HEIGHT="1" ALIGN="center" VALIGN="bottom"> <HR ALIGN="center" WIDTH="100%" SIZE="1" NOSHADE> </TD></TR> <TR><TD> <FORM METHOD="get" ACTION="<http://books.google.com/books> http://books.google.com/books"> <INPUT TYPE="hidden" NAME="ie" VALUE="UTF-8"> <INPUT TYPE="hidden" NAME="vid" VALUE="ISBN1234567890"> <INPUT TYPE="hidden" NAME="sourceid" VALUE="ca-print-YOUR_press"> <TABLE WIDTH="100%" BORDER="0" CELLSPACING="0" CELLPADDING="3"> <TR><TD ALIGN="left" VALIGN="bottom"> <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="0"> <TR><TD VALIGN="bottom"> <SPAN STYLE="font-family: Arial, Helvetica, sans-serif; font-size: 9px;">Search this book<BR></SPAN> <INPUT NAME="q" TYPE="text" SIZE="15"> </TD></TR> </TABLE></TD> <TD VALIGN="bottom"> <SPAN STYLE="font-family: Arial, Helvetica, sans-serif; font-size: 14px; color: #FFFFFF; font-weight: bold;"> <INPUT TYPE="image" SRC="gbutton_clear.png" VALUE="Google Book Search" ALT="Search" NAME="submit"> </SPAN></TD></TR> </TABLE> </FORM> </TD></TR> <TR><TD HEIGHT="1" ALIGN="center" VALIGN="top"> <HR ALIGN="center" WIDTH="100%" SIZE="1" NOSHADE> </TD></TR> </TABLE> <!-- Google Book Search -->

Note that the ISBN is placed in the hidden value "vid":

<INPUT TYPE="hidden" NAME="vid" VALUE="ISBN1234567890">

And your press name is helpful here:

<INPUT TYPE="hidden" NAME="sourceid" VALUE="ca-print-YOURPRESSNAME_press">

Be sure to use the ISBN for the edition Google is using.

Also Note: If your page is not encoded as UTF-8, you should change the hidden value for "ie".

The Google Button is available on the Penn State site here:

gbutton_clear.png

Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox