Feature: Insert information text into plugin box

Phoca Maps - displaying maps in Joomla! CMS
Maexxle
Phoca Newbie
Phoca Newbie
Posts: 1
Joined: 27 Jan 2024, 17:38

Feature: Insert information text into plugin box

Post by Maexxle »

If the map cannot be displayed due to an error or a blocked cookie (GDPR Cookie Hint), a corresponding notice should be visible.

I have therefore expanded the plugin as follows: (German information text, this could still be improved via the language module!)

File: plg_content_phocamaps/phocamaps.php
From line ~350

Code: Select all

	// Map Box
	if ($tmpl['border'] == '') {
		$output .= '<div class="phocamaps-box" align="center" style="'.$tmpl['stylesite'].'">';
		if ($tmpl['fullwidth'] == 1) {
			$output .= '<div id="phocaMap'.$id.'" style="margin:0;padding:0;width:100%;height:'.$mapp->height.'">';
			//EXTENSION MADE HERE 1/4
			$output .= '<p>&nbsp;</p><p>Sie müssen die funktionalen Cookies von Google Maps aktivieren und damit auch die Nutzungsbedingungen von Google akzeptieren, um diese Funktion nutzen zu können!</p>';
			$output .= '</div>';
		} else {
			$output .= '<div id="phocaMap'.$id.'" style="margin:0;padding:0;width:'.$mapp->width.';height:'.$mapp->height.'">';
			//EXTENSION MADE HERE 2/4
			$output .= '<p>&nbsp;</p><p>Sie müssen die funktionalen Cookies von Google Maps aktivieren und damit auch die Nutzungsbedingungen von Google akzeptieren, um diese Funktion nutzen zu können!</p>';
			$output .= '</div>';
		}
		$output .= '</div>';
	} else {
		$output .= '<div class="phocamaps-box phocamaps-box-border'.$tmpl['border'].'" align="center" style="'.$tmpl['stylesite'].'">';
		if ($tmpl['fullwidth'] == 1) {
			$output .= '<div id="phocaMap'.$id.'" class="phocamaps-map" style="width:100%;height:'.$mapp->height.'">';
			//EXTENSION MADE HERE 3/4
			$output .= '<p>Sie müssen die funktionalen Cookies von Google Maps aktivieren und damit auch die Nutzungsbedingungen von Google akzeptieren, um diese Funktion nutzen zu können</p>';
			$output .= '</div>';
		} else {
			$output .= '<div id="phocaMap'.$id.'" class="phocamaps-map" style="width:'.$mapp->width.';height:'.$mapp->height.'">';
			//EXTENSION MADE HERE 4/4
			$output .= '<p>&nbsp;</p><p>Sie müssen die funktionalen Cookies von Google Maps aktivieren und damit auch die Nutzungsbedingungen von Google akzeptieren, um diese Funktion nutzen zu können!</p>';
			$output .= '</div>';
		}
		$output .= '</div>';
		//echo '</div></div></div></div></div>';
	}

Tags:
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 47887
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Feature: Insert information text into plugin box

Post by Jan »

Hi, thank you for this improvement.

Jan
If you find Phoca extensions useful, please support the project
Post Reply