This forum is for assistance with theme development.

First and last block of a sidebar

Is there a way to differentiate the first and the last block in a sidebar ?

I would like to have some kid of continuous zone including all the blocks, and closed at the top and bottom...
I can't find a variable allowing to assign a specific class to these 2 blocks...

Thanks

Show last blog entries in profile view

I need to show the last blog entries writen by an user in his profile page. And algo want to show his last recipes (a new content type, made with CCK).

I find a post in drupal.org, and thanks to that post now I'm able to show the last posts via the custom user_profile.tpl.php, but I don't know nothing about PHP, and I need the code for showing the last recipes.

Please, can you help me? Thanks in advance!

Adding a reset.css before drupal core module css files

Hi all,

I am working on creating a base theme to build any future work on.
Elements will include bits of:
Zen theme
Hunchbaque theme
Sympal Theme
Blueprint CSS framework.

In order to add the reset.css component of blueprint.css,
I need that stylesheet to get added before drupal adds module css files.

I have a function in my template.php file that I use to add all the css.

function bluezen_styles() {
  drupal_add_css(path_to_theme().'/css/lib/typography.css', 'theme', 'all');
  drupal_add_css(path_to_theme().'/css/lib/grids.css', 'theme', 'all');
  drupal_add_css(path_to_theme().'/css/lib/buttons.css', 'theme', 'all');
  drupal_add_css(path_to_theme().'/css/lib/print.css', 'theme', 'print');
  drupal_add_css(path_to_theme().'/css/layout.css', 'theme', 'all');
  
  $css = drupal_add_css();

  $reset = path_to_theme().'/css/lib/reset.css';
  $css[all][module][$reset]= 1;

//  array_unshift($css[all][module],($reset=>1));

  
  return drupal_get_css($css);
}

This does a great job of adding all the extra css files.
The tricky thing is getting the reset.css file adding to the beginning of the $css array.
The code displayed above only adds in to the end of the $css[all][module] array.
array_unshift seems to be the correct function, but I can't get that to work.

As a workaround, I have added it in as regular HTML above the

getting block images to display inline

I have created a block from a view that displays recently submitted user images as thumbnails. This works, but I want to align the images horizontally. I have been able to change several aspects of the styling (I can remove the bullet images, etc) but I can't get the images to align inline.

Here is the code from the source of the page:

Drop Down Menus Work but need to tweak the template.php... help?

Ok gurus...

I have implemented a pure css drop down menu on my drupal 5.x site and it works perfectly, except in older IE. The fixes below (conditional if statements) need to be added on the fly to the nav list generation...

I am sure this is what the template.php can do, but lack the skills to make the check and code to add the extra bits below... eg:

 <!--[if IE 7]><!--></a><!--<![endif]-->
<!--[if lte IE 6]><table><tr><td><![endif]--> 

the above needs to be added to the end of expanded menu list items...

Any ideas what I would put into my template.php and then how I tell drupal to use it?

Thanks!

how to I theme the edit profile form?

I have created about 20 fields in a profile category called "Background". I would like to alter how these fields are displayed when people edit them. I'd like some of them to be side-by-side in a table view, some of them grouped in a border, some of them I don't want their labels or default help text to show up. Writing the html/css to display the form how I want is not an issue, I just don't know where to put the code so that it's used by Drupal correctly. I've found I can "intercept" the edit profile output by doing something like this on page.tpl.php:

Pages

Subscribe with RSS Subscribe to RSS - Theme development