<?PHP

include_once 'gb_source_pad.php';

/*
 * register globals = off
 * Registriert werden können die folgenden Variablen:
 * $gp_user['action'] = $gp_action;
 * $gp_user['lang'] = $gp_lang;
 * $gp_user['unique_nr'] = $gp_unique_nr;
 * $gp_user['color_opener'] = $gp_color_opener;
 * $gp_user['image_name'] = $gp_image_name;
 * $gp_user['tpl_set'] = $gp_tpl_set;
 */
if ($_GET['action'] == 'make_image'){
	gb_source_pad::handle_make_image($_GET['image_name'], $_GET['tpl_set']);

}
else{
	$handle = new gb_source_pad('*handle*');

	switch ($_GET['action'])
	{
	    case 'make_js_pad':
	         $gp_return = $handle -> handle_make_js_pad($_GET['unique_nr'], $_GET['tpl_set'], $_GET['lang']);
	         break;
	    case 'make_js_functions':
	         $gp_return = $handle -> handle_make_js_functions($_GET['tpl_set'], $_GET['lang']);
	         break;
	    case 'make_popup_color':
	         $gp_return = $handle -> handle_make_popup_color($_GET['color_opener'], $_GET['unique_nr'], $_GET['tpl_set'], $_GET['lang']);
	         break;
	    case 'make_popup_search':
	         $gp_return = $handle -> handle_make_popup_search($_GET['unique_nr'], $_GET['tpl_set'], $_GET['lang']);
	         break;
	    case 'make_popup_search_replace':
	         $gp_return = $handle -> handle_make_popup_search_replace($_GET['unique_nr'], $_GET['tpl_set'], $_GET['lang']);
	         break;
	    case 'make_popup_link':
	         $gp_return = $handle -> handle_make_popup_link($_GET['unique_nr'], $_GET['tpl_set'], $_GET['lang']);
	         break;
	    case 'make_popup_image':
	         $gp_return = $handle -> handle_make_popup_image($_GET['unique_nr'], $_GET['tpl_set'], $_GET['lang']);
	         break;
	    case 'make_popup_list':
	         $gp_return = $handle -> handle_make_popup_list($_GET['unique_nr'], $_GET['tpl_set'], $_GET['lang']);
	         break;
	    case 'make_popup_table':
	         $gp_return = $handle -> handle_make_popup_table($_GET['unique_nr'], $_GET['tpl_set'], $_GET['lang']);
	         break;
	    case 'make_popup_special_chars':
	         $gp_return = $handle -> handle_make_popup_special_chars($_GET['unique_nr'], $_GET['tpl_set'], $_GET['lang']);
	         break;
	    case 'make_css':
	         $gp_return = $handle -> handle_make_css($_GET['tpl_set']);
	         break;
	}
}

echo $gp_return;

?>