Closed (fixed)
Project:
GMap Module
Version:
5.x-1.x-dev
Component:
Documentation
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
20 Apr 2007 at 01:26 UTC
Updated:
9 Dec 2008 at 18:09 UTC
Jump to comment: Most recent file
Comments
Comment #1
bensheldon commentedHere is a patch for gmap_views.module that simply takes the current code that generates marker windows for Views and passes it through a hook_theme function. This allows the marker windows theme to be overridden by traditional methods.
The default marker theme code is this:
Comment #2
Caleb G2 commentedThis is a great patch. Thanks bensheldon. Marking rtbc. Once I have fleshed out my tpl file a little more I'll come back and paste the code and/or attach the files to help the next person along.
Comment #3
Caleb G2 commentedSo using this patch it boils down to:
1. patching gmap_views.module
2. Adding this to template.php:
3. Creating a file called gmap_views_maker_label.tpl.php and adding:
4. Note the added 'gmapstyle-' which is added to the class in order to make it easier to find in the mess of code that gets generated by all of this. Fine tuning of themeing can involve a) editing css, b) editing the tpl file itself, and/or c) creating new versions of the gmap views and editing the fields and/or the order of the fields.
Comment #4
bdragon commentedCongratulations, you win the "closest to something I had locally but forgot to commit" prize!
You had better commentation and a function name, so I just adapted mine to pretty much match yours.
*committed*
Thanks!
--Brandon
Comment #5
dries commentedComment #6
njehlen commentedI was able to theme views in general using this code - can someone give an example of how to theme different views differently?
Comment #7
thomasmuirhead commentedI was having trouble with this for a while so just in case anyone was too check that you are spelling marker with an 'r' wherever you use it... as above the 'r' seems to have been dropped in some cases and not in others.
I changed them all to having the r and everything worked...thanks for the solution guys it's made using gmap views a possibility.
Thomas