Location: PHPKode > projects > Content*Builder > contentbuilder/plugins/media_manager/mediaTypesGeneral.inc.php
<?php
	if($typeSub != 1) {
		$display = "overview";
	} else {
		$display = "own";
		$modSet = false;
		if (ereg("(^[1-9]?[0-9]*$)", $typeID)) {
			$modQuery = mysql_fetch_object(mysql_query("SELECT * FROM ".TABLE."_mm_type WHERE typeID = '$typeID'"));
			$modName = $modQuery->name;
			$modExt = $modQuery->extension;
			if($modName != "" && $modExt != "") { $modSet = true; }
		} else {
			unset($typeID);
			unset($mod);
		} 
	
		if(empty($_POST[uploadbutton])) {
			if($modThumb)  $modThumbChk  = "checked";
			if($modResize) $modResizeChk = "checked";
			$tpl->assign("type_form",
				array ( "TID"                => $typeID,
						"MOD"                => $mod,
						"NAME"               => $modName,
						"EXTENSION"          => $modExt,
						"CHK_TN"             => $modThumbChk,
						"CHK_RS"             => $modResizeChk,
						"RS_HEIGHT"          => $modResizeHeight,
						"RS_WIDTH"           => $modResizeWidth,
						"TN_HEIGHT"          => $modThumbHeight,
						"TN_WIDTH"           => $modThumbWidth
				)
			);
			$tpl->assign("type_form_set", "1");
			$tpl->assign("type_mod_general_set", "1");
		} else {
			// Prüfen, ob alles korrekt ist
			$extension = explode("; ", $_POST['tExtension']);
			$extensionArray = array();
			foreach($extension as $key => $value) {
				if (ereg("^([0-9a-zA-Z].[0-9a-zA-Z.]*)$", $value)) {
					$extensionArray[] = $value;
				} 
			} 
			$extensionArray = implode("; ", $extensionArray); 
			// In DB einfügen oder Updaten
			if (empty($error)) {
				if (empty($mod)) {
					mysql_query("INSERT INTO ".TABLE."_mm_type (name, extension) VALUES ('$_POST[tName]', '$extensionArray')");
					$thisTypeID = mysql_insert_id();
				} else {
					mysql_query("UPDATE ".TABLE."_mm_type SET name = '$_POST[tName]', extension = '$extensionArray' WHERE typeID = '$typeID'");
				}
				$display = "overview";
			} 
		} 
	}
?>
Return current item: Content*Builder