css Fehler

Bitte alle templatebezogenen Beiträge in diesem Forum veröffentlichen.
User avatar
santscho
Posts: 1442
Joined: Mon 2. Apr 2007, 08:56
Location: Schweiz

Re: css Fehler

Post by santscho »

The solution is: In page layout where the checkboxes and fields for background and colors are: you need to check "disabled" and everything works fine.
Schon Konfuzius sagte: "Sei kein YAML-Lappen". YAML-phpwcms-Integration auf http://www.yaml.phpwcms.org
User avatar
Oliver Georgi
Site Admin
Posts: 9892
Joined: Fri 3. Oct 2003, 22:22
Contact:

Re: css Fehler

Post by Oliver Georgi »

Checked again — was my fault. I have fixed the related function although this is a deprecated functionality.

See include/inc_front/front.func.inc.php around line 120:

Code: Select all

function get_body_attributes(& $values) {
	//return a standard list of standard html body attributes
	//based on the pagelayout definitions
	$body_class	= '';
	$link_class	= '';
	if(is_array($values)) {
		if(empty($values["layout_noborder"])) {
			$body_class .= add_style_attribute('		margin', '0').LF;
			$body_class .= add_style_attribute('		padding-top',		empty($values["layout_border_top"])		? '0' : intval($values["layout_border_top"])   .'px').LF;
			$body_class .= add_style_attribute('		padding-bottom',	empty($values["layout_border_bottom"])	? '0' : intval($values["layout_border_bottom"]).'px').LF;
			$body_class .= add_style_attribute('		padding-left',	empty($values["layout_border_left"]) 	? '0' : intval($values["layout_border_left"])  .'px').LF;
			$body_class .= add_style_attribute('		padding-right', 	empty($values["layout_border_right"]) 	? '0' : intval($values["layout_border_right"]) .'px').LF;
			$body_class .= LF;
		}
		if(!empty($values["layout_bgcolor"])) {
			$body_class .= add_style_attribute('		background-color', $values["layout_bgcolor"]);
			$body_class .= LF;
		}
		if(!empty($values["layout_bgimage"])) {
			$body_class .= add_style_attribute('		background-image', 'url('.$values["layout_bgimage"].')');
			$body_class .= LF;
		}
		if(!empty($values["layout_textcolor"])) {
			$body_class .= add_style_attribute('		color', $values["layout_textcolor"]);
			$body_class .= LF;
		}
		if(!empty($body_class)) {
			$body_class  = '	body {'.LF.$body_class.'	}'.LF;
		}
		if(!empty($values["layout_linkcolor"])) {
			$link_class .= '	a, a:link, a:active, a:visited, a:hover { color: '.$values["layout_linkcolor"].'; }';
			$link_class .= LF;
		}
		if(!empty($values["layout_vcolor"])) {
			$link_class .= '	a:visited { color: '.$values["layout_vcolor"].'; }';
			$link_class .= LF;
		}
		if(!empty($values["layout_acolor"])) {
			$link_class .= '	a:active { color: '.$values["layout_acolor"].'; }';
			$link_class .= LF;
		}
		if(!empty($body_class) || !empty($link_class)) {
			$body_class  = '  <style type="text/css">'.LF. $body_class;
			$body_class .= $link_class . '  </style>'.LF;
		}
		
		return $body_class;
	}
	return '';
}
Oliver Georgi | phpwcms Developer | GitHub | LinkedIn | Систрон
Post Reply