Your IP : 216.73.216.219


Current Path : /home/pteabiscqq/www/plugins/system/lab5_cookie_commander/cookie_commander/
Upload File :
Current File : /home/pteabiscqq/www/plugins/system/lab5_cookie_commander/cookie_commander/load_popup.php

<?php defined('_JEXEC') or die();
/////////////////////////////////////////////////////////////////////////////////////////////
/** 
* Cookie Commander
* 
* @author : Lab5 - Dennis Riegelsberger
* @authorUrl : https://lab5.ch
* @copyright : Copyright (C) 2018+  Lab5 - Dennis Riegelsberger. All rights reserved.
* @license : GNU/GPL General Public License version 2 or later
* @project : https://lab5.ch/cookie-commander
* @on JED : https://extensions.joomla.org/extensions/extension/site-management/cookie-control/lab5-cookie-commander/
* 
* Built with <3 
* Lab5
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ 
/**
 * @CHANGELOG :
 * * 2020.08.10 : Great overhaul
 */
/////////////////////////////////////////////////////////////////////////////////////////////

							$language = JFactory::getLanguage();
							$language->load('joomla', JPATH_ADMINISTRATOR, $language->getTag(), $reload = true);	

							$COOKIE_CONTENTS = self::$xstor->cccookies->cookie_switches;
							unset( $COOKIE_CONTENTS['sessionprotect'] ); // Soll nicht gerendert werden.
							$params = self::$xstor->cooco;  // WILL BE CHANGED WHILE PROCESSING THE POPUP-BODY
							
							////////////////////////////
							// POPUP - HEADING
							////////////////////////////
									$text =  JText::_(self::$xstor->cooco->controlsText);
									///
									$tpl_path = (self::$xstor->getCCLayoutPath)( 'popup_header' );
									ob_start(); 
									include($tpl_path); 
									$popup_header = ob_get_clean(); 
							////////////////////////////
							// POPUP - BODY
							////////////////////////////
									$tpl_path = (self::$xstor->getCCLayoutPath)( 'popup_body' );
									ob_start(); 
									include($tpl_path); 
									$popup_body = ob_get_clean(); 
									// $popup_body = str_replace(["\n","\r","\t"], ['','',''] $popup_body ); // for loading in JS 
							////////////////////////////
							// POPUP - FOOTER
							////////////////////////////		
									$tpl_path = (self::$xstor->getCCLayoutPath)( 'popup_footer' );
									ob_start(); 
									include($tpl_path); 
									$popup_footer = ob_get_clean(); 
							////////////////////////////
							// POPUP - FOOTER - EMBEDDED FORM VARIANT
							////////////////////////////		
									$tpl_path = (self::$xstor->getCCLayoutPath)( 'popup_footer_embed' );
									ob_start(); 
									include($tpl_path); 
									$popup_footer_embed = ob_get_clean(); 
							////////////////////////////
							// POPUP - FORM
							////////////////////////////		
									$URL = new JUri($_SERVER['REQUEST_URI']) ;
									$popup_form = '
									<form id="'.$params->idPopup.'_form" class="cooco-form" action="'.$URL.'" method="POST">
												{popup_html}
									</form>';
									// $tpl_path = (self::$xstor->getCCLayoutPath)( 'popup_form' );
									// ob_start(); 
									// include($tpl_path); 
									// $popup_form = ob_get_clean(); 
							////////////////////////////
							// POPUP - LIST
							//////////////////////////		
									// $tpl_path = (self::$xstor->getCCLayoutPath)( 'popup_form' );
									// ob_start(); 
									// include($tpl_path); 
									// $popup_list = ob_get_clean(); 
									ob_start(); 
									require('load_list.php'); 
									$popup_list = ob_get_clean(); 
									
									
							////////////////////////////
							// COMBINE - LIST + BODY
							//////////////////////////		
									
										$popup_body = str_replace( "{popup_list}", $popup_list, $popup_body );
										
										
							
							//////////////
							self::$xstor->cooco = $params;
							self::$xstor->cccookies->cookie_switches = $COOKIE_CONTENTS;
							unset( $COOKIE_CONTENTS, $params );
							unset($tpl_path);