Difference between revisions of "List page map overlapping template header"

From JReviews Documentation
Jump to: navigation, search
(Created page with "If your Joomla template uses a fixed header/menu, it is possible that the map on JReviews list pages will overlap the header when scrolling the page. To fix the conflict, it is ...")
 
Line 5: Line 5:
 
*<span style="color: blue">/com_jreviews_addons/geomaps/views/themes/geomaps/geomaps/map_results.thtml</span>
 
*<span style="color: blue">/com_jreviews_addons/geomaps/views/themes/geomaps/geomaps/map_results.thtml</span>
 
(or copy the file into your custom theme in this folder /themes/{yourtheme}/geomaps/)
 
(or copy the file into your custom theme in this folder /themes/{yourtheme}/geomaps/)
 +
  
 
Find this line in the file:
 
Find this line in the file:
Line 10: Line 11:
 
var y = jQuery(window).scrollTop();
 
var y = jQuery(window).scrollTop();
 
</source>
 
</source>
 +
  
 
and add the height of your fixed header like this:
 
and add the height of your fixed header like this:
Line 16: Line 18:
 
</source>
 
</source>
  
also add this into custom_styles.css:
 
  
 +
also add this into custom_styles.css:
 
<source lang="css">
 
<source lang="css">
 
#gm_map_wrapper.fixed {
 
#gm_map_wrapper.fixed {
Line 24: Line 26:
 
</source>
 
</source>
  
In these examples, 55 represents the height of the header/menu, adjust the value based on the height of your header/menu.
+
 
 +
In these examples, 55 represents the height of the header/menu.
  
  
 
[[Category:JReviews]]
 
[[Category:JReviews]]
 
[[Category:GeoMaps Addon]]
 
[[Category:GeoMaps Addon]]

Revision as of 13:37, 2 November 2011

If your Joomla template uses a fixed header/menu, it is possible that the map on JReviews list pages will overlap the header when scrolling the page.

To fix the conflict, it is necessary to push down the map by the height of the header. To do that, modify this file:

  • /com_jreviews_addons/geomaps/views/themes/geomaps/geomaps/map_results.thtml

(or copy the file into your custom theme in this folder /themes/{yourtheme}/geomaps/)


Find this line in the file:

var y = jQuery(window).scrollTop();


and add the height of your fixed header like this:

var y = jQuery(window).scrollTop()+55;


also add this into custom_styles.css:

#gm_map_wrapper.fixed {
    top: 55px;
}


In these examples, 55 represents the height of the header/menu.