Calguys Google Maps 2 - Populating information window...

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Post Reply
User avatar
PinkElephant
Forum Members
Forum Members
Posts: 169
Joined: Fri Feb 06, 2009 2:08 pm

Calguys Google Maps 2 - Populating information window...

Post by PinkElephant »

The original thread is locked so...
naturelab wrote:

Code: Select all

{$mapdesc="<h3><a href=$maplink title=$maptitle>{$maptitle}<br /><span style='white-space:nowrap'>Read more &#9654;</span></a></3>" }
I'm surprised that renders. ;) What happens if you quote the link attributes, e.g:

Code: Select all

{$mapdesc='<h3><a href="$maplink" title="$maptitle">$maptitle<br /><span style="white-space:nowrap;">Read more &#9654;</span></a></h3>'}
?
calguy1000
Support Guru
Support Guru
Posts: 8169
Joined: Tue Oct 19, 2004 6:44 pm
Location: Fernie British Columbia, Canada

Re: Calguys Google Maps 2 - Populating information window...

Post by calguy1000 »

Remember: Smarty will not process anything inside single quotes. It will process stuff inside double quotes.
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
User avatar
PinkElephant
Forum Members
Forum Members
Posts: 169
Joined: Fri Feb 06, 2009 2:08 pm

Re: Calguys Google Maps 2 - Populating information window...

Post by PinkElephant »

calguy1000 wrote:Smarty will not process anything inside single quotes.
Good point! Not the best example then. ;)

I was asking because it looks bug-like to me, where the double quote is escaped twice;

modules\CGGoogleMaps2\lib\class.cggm2_map_generator.php v1.1.1

Code: Select all

261: if( $marker->get_description() ) $rec['bubbletext'] = addslashes($marker->get_description());
593: $out = json_encode($data);
" => \" => \\\"

I've not tested (sorry) but using a simple hard-coded value for desc should point the way.

Code: Select all

desc='<p><a href="https://www.example.com">example link</a></p>'
Post Reply

Return to “Modules/Add-Ons”