Hi all,
I've been working a while on a site and am now trying to add zoom search to it as the default search was not as good.
Unfortunately, due to my inexperience, I'm having real trouble in getting zoom to work on my site.
The site is currently up here
I'll break down what I've done to see if you can spot where its gone wrong!
I've copied the code
'<form method="GET" action="search.php">
<input type="text" name="zoom_query" size="10">
<input type="submit" value="Search">
</form>'
and added that to my master page. This is the search box (which I'm still going to try and change the look of...)
Then on the search results page I've got the following code:
<style type="text/css">
.highlight { background: #FFFF40; }
.searchheading { font-size: 100%; font-weight: bold; }
.summary { font-size: 80%; font-style: italic; }
.suggestion { font-size: 80%; }
.results { font-family: Arial; font-size: 80%; }
.category { color: #999999; }
.sorting { text-align: right; }
.result_title { font-size: 100%; margin-bottom: 10px; }
.description { font-size: 100%; color: #800080; }
.context { font-size: 100%; }
.infoline { font-size: 80%; font-style: normal; color: #808080;}
.zoom_searchform { font-size: 100%; }
.zoom_results_per_page { font-size: 80%; margin-left: 10px; }
.zoom_match { font-size: 80%; margin-left: 10px;}
.zoom_categories { font-size: 80%; }
.zoom_categories ul { display: inline; margin: 0px; padding: 0px;}
.zoom_categories li { display: inline; margin-left: 15px; list-style-type: none; }
.cat_summary ul { margin: 0px; padding: 0px; display: inline; }
.cat_summary li { display: inline; margin-left: 15px; list-style-type: none; }
input.zoom_button { }
input.zoom_searchbox { }
.result_image { float: left; display: block; }
.result_image img { margin: 10px; width: 80px; border: 0px; }
.result_block { margin-top: 15px; margin-bottom: 15px; clear: left; }
.result_altblock { margin-top: 15px; margin-bottom: 15px; clear: left; }
.result_pages { font-size: 100%; }
.result_pagescount { font-size: 100%; }
.searchtime { font-size: 80%; }
.recommended
{
background: #DFFFBF;
border-top: 1px dotted #808080;
border-bottom: 1px dotted #808080;
margin-top: 15px;
margin-bottom: 15px;
}
.recommended_heading { float: right; font-weight: bold; }
.recommend_block { margin-top: 15px; margin-bottom: 15px; clear: left; }
.recommend_title { font-size: 100%; }
.recommend_description { font-size: 100%; color: #008000; }
.recommend_infoline { font-size: 80%; font-style: normal; color: #808080;}
.recommend_image { float: left; display: block; }
.recommend_image img { margin: 10px; width: 80px; border: 0px; }
</style>'
This has been amended so the style matches the rest of the site. Up to this point it searches fine and brings the results up on the search results page.
Now, in order to enable the jump to highlight feature I have ticked the box in zoom to enable it, reindexed and re-uploaded the files to my site.
Then I've used the following code as a fragment at the top of all master pages:
'<style type="text/css">.highlight { background: #FFFF40; }</style>
<script type="text/javascript" src="highlight.js"></script>'
And then in place of the '__AddCode="MasterPageInBodyTag"'
I have added the following code:'onload="highlight();"'
I've also tried adding it to the main body tag of each page though this didnt work.
When I click through from the search results page to the matched results its no longer even highlighting that word on the page, let alone scrolling down to it. And to make it worse some odd symbols seem to have come back at the top of the published site page which I got rid of the other day by amending the site to html output --> western european.
I've pestered everyone on the serif forums about it, and they've been a great help, but thought you guys on here may spot something others have possibly missed?
Any ideas will be gratefully received!
Thanks
Rich
I've been working a while on a site and am now trying to add zoom search to it as the default search was not as good.
Unfortunately, due to my inexperience, I'm having real trouble in getting zoom to work on my site.
The site is currently up here
I'll break down what I've done to see if you can spot where its gone wrong!
I've copied the code
'<form method="GET" action="search.php">
<input type="text" name="zoom_query" size="10">
<input type="submit" value="Search">
</form>'
and added that to my master page. This is the search box (which I'm still going to try and change the look of...)
Then on the search results page I've got the following code:
<style type="text/css">
.highlight { background: #FFFF40; }
.searchheading { font-size: 100%; font-weight: bold; }
.summary { font-size: 80%; font-style: italic; }
.suggestion { font-size: 80%; }
.results { font-family: Arial; font-size: 80%; }
.category { color: #999999; }
.sorting { text-align: right; }
.result_title { font-size: 100%; margin-bottom: 10px; }
.description { font-size: 100%; color: #800080; }
.context { font-size: 100%; }
.infoline { font-size: 80%; font-style: normal; color: #808080;}
.zoom_searchform { font-size: 100%; }
.zoom_results_per_page { font-size: 80%; margin-left: 10px; }
.zoom_match { font-size: 80%; margin-left: 10px;}
.zoom_categories { font-size: 80%; }
.zoom_categories ul { display: inline; margin: 0px; padding: 0px;}
.zoom_categories li { display: inline; margin-left: 15px; list-style-type: none; }
.cat_summary ul { margin: 0px; padding: 0px; display: inline; }
.cat_summary li { display: inline; margin-left: 15px; list-style-type: none; }
input.zoom_button { }
input.zoom_searchbox { }
.result_image { float: left; display: block; }
.result_image img { margin: 10px; width: 80px; border: 0px; }
.result_block { margin-top: 15px; margin-bottom: 15px; clear: left; }
.result_altblock { margin-top: 15px; margin-bottom: 15px; clear: left; }
.result_pages { font-size: 100%; }
.result_pagescount { font-size: 100%; }
.searchtime { font-size: 80%; }
.recommended
{
background: #DFFFBF;
border-top: 1px dotted #808080;
border-bottom: 1px dotted #808080;
margin-top: 15px;
margin-bottom: 15px;
}
.recommended_heading { float: right; font-weight: bold; }
.recommend_block { margin-top: 15px; margin-bottom: 15px; clear: left; }
.recommend_title { font-size: 100%; }
.recommend_description { font-size: 100%; color: #008000; }
.recommend_infoline { font-size: 80%; font-style: normal; color: #808080;}
.recommend_image { float: left; display: block; }
.recommend_image img { margin: 10px; width: 80px; border: 0px; }
</style>'
This has been amended so the style matches the rest of the site. Up to this point it searches fine and brings the results up on the search results page.
Now, in order to enable the jump to highlight feature I have ticked the box in zoom to enable it, reindexed and re-uploaded the files to my site.
Then I've used the following code as a fragment at the top of all master pages:
'<style type="text/css">.highlight { background: #FFFF40; }</style>
<script type="text/javascript" src="highlight.js"></script>'
And then in place of the '__AddCode="MasterPageInBodyTag"'
I have added the following code:'onload="highlight();"'
I've also tried adding it to the main body tag of each page though this didnt work.
When I click through from the search results page to the matched results its no longer even highlighting that word on the page, let alone scrolling down to it. And to make it worse some odd symbols seem to have come back at the top of the published site page which I got rid of the other day by amending the site to html output --> western european.
I've pestered everyone on the serif forums about it, and they've been a great help, but thought you guys on here may spot something others have possibly missed?
Any ideas will be gratefully received!
Thanks
Rich
Comment