Difference between revisions of "How to hide the map from certain categories"

From JReviews Documentation
Jump to: navigation, search
(Created page with 'If you selected the <span style="color: blue">geomaps</span> theme in JReviews Configuration, the theme files with the map code will be used on all …')
 
Line 1: Line 1:
If you selected the <span style="color: blue">geomaps</span> theme in [[Configuration-General tab|JReviews Configuration]], the theme files with the map code will be used on all your sections and categories.
+
You've successfully added GeoMaps to your site, but you also have certain categories, like news and blogs and others that don't require showing maps.
  
 +
The easiest solution is to edit the listing type of those categories and disable displaying the map on their list and detail pages.
  
To hide the map from certain sections or categories, use the [[Theme Manager]] and add a "_nomap" theme suffix to those sections/categories.
 
  
 +
Alternative is to create a copy of these two theme files
 +
*\com_jreviews\jreviews\views\themes\default\listings\detail.thtml
 +
*\com_jreviews\jreviews\views\themes\default\listings\listings_blogview.thtml
  
Then you will be able to use different theme files (without the map) for those categories:
+
rename the copies to this:
 +
*detail_nomap.thtml - listing detail page
 +
*listings_blogview_nomap.thtml - category list page
 +
and delete the code for maps in those files.
  
detail_nomap.thtml - listing detail page <br />
+
Click on '''Clear File Registry''' link in JReviews administration for JReviews to recogniz new files.
listings_blogview_nomap.thtml - category list page
+
  
  
The easiest way to do that is to copy and rename these two files:
+
To hide the map from certain categories, use the [[Theme Manager]] and add a "_nomap" theme suffix to those categories.
 
+
\com_jreviews\jreviews\views\themes\default_02\listings\detail.thtml<br />
+
\com_jreviews\jreviews\views\themes\default_02\listings\listings_blogview.thtml
+
 
+
 
+
The <span style="color: blue">default_02</span> theme is the same as <span style="color: blue">geomaps</span> theme, but without the map code.
+
 
+
 
+
After you rename the files to:
+
 
+
detail_nomap.thtml<br />
+
listings_blogview_nomap.thtml
+
 
+
move them into this folder:
+
 
+
\com_jreviews_addons\geomaps\views\themes\geomaps\listings
+
 
+
 
+
Click on '''Clear File Registry''' link in JReviews administration and that is it.
+
  
  

Revision as of 11:05, 17 June 2011

You've successfully added GeoMaps to your site, but you also have certain categories, like news and blogs and others that don't require showing maps.

The easiest solution is to edit the listing type of those categories and disable displaying the map on their list and detail pages.


Alternative is to create a copy of these two theme files

  • \com_jreviews\jreviews\views\themes\default\listings\detail.thtml
  • \com_jreviews\jreviews\views\themes\default\listings\listings_blogview.thtml

rename the copies to this:

  • detail_nomap.thtml - listing detail page
  • listings_blogview_nomap.thtml - category list page

and delete the code for maps in those files.

Click on Clear File Registry link in JReviews administration for JReviews to recogniz new files.


To hide the map from certain categories, use the Theme Manager and add a "_nomap" theme suffix to those categories.