ThemeShaper Forums » Thematic

[closed]

Adding classes to the sidebars

(3 posts)
  • Started 8 years ago by TrolliBoll
  • Latest reply from TrolliBoll
  • This topic is resolved

Tags:

  1. TrolliBoll
    Member

    I'm trying to use the 960 grid system with Thematic, thus I want to add the appropriate classes to the DIVs. But I'm having trouble in finding where the sidebar DIVs are opened. So, if anyone can point out in which file and on what line that happens I would be really glad.

    Posted 8 years ago #
  2. i think you are looking for the thematic_before_widget_area() function. i had to dig around to find it, but it is in the widget-extensions.php file. the function looks like this (at least in my latest version of thematic)

    // this function returns the opening CSS markup for the widget area
    function thematic_before_widget_area($hook) {
    	$content =  "\n";
    	if ($hook == 'primary-aside') {
    		$content .= '<div id="primary" class="aside main-aside">' . "\n";
    	} elseif ($hook == 'secondary-aside') {
    		$content .= '<div id="secondary" class="aside main-aside">' . "\n";
    	} elseif ($hook == '1st-subsidiary-aside') {
    		$content .= '<div id="first" class="aside sub-aside">' . "\n";
    	} elseif ($hook == '2nd-subsidiary-aside') {
    		$content .= '<div id="second" class="aside sub-aside">' . "\n";
    	} elseif ($hook == '3rd-subsidiary-aside') {
    		$content .= '<div id="third" class="aside sub-aside">' . "\n";
    	} else {
    		$content .= '<div id="' . $hook . '" class="aside">' ."\n";
    	}
    	$content .= "\t" . '<ul class="xoxo">' . "\n";
    	return apply_filters('thematic_before_widget_area', $content);
    }

    i'd love to see what you come up with. i am trying to code on 960 too, but havent tried porting thematic over.

    Posted 8 years ago #
  3. TrolliBoll
    Member

    Thanks a lot! Don't know how I could have missed it.

    Posted 8 years ago #

RSS feed for this topic

Topic Closed

This topic has been closed to new replies.