This forum is for assistance with theme development.

Theming Date Output for Historical Dates

Can somebody help me correctly theme the output of the date module when using historical dates?

I am trying to get my template to print out a nicely formatted historical date from a CCK date field (with both from and to dates). I am using ADOdb. Everything is rather easy if I want to just use the default combination of the "from" and "to" dates; I can just use print $node->field_born[0]['view']

drop down sort menu in views

Hi,

hopefully someone can help me :)

Is it possible to create a drop down list to sort the items of a view?
I have created a 'case studies' (list) view.
I need to create a drop down menu 'sort by' including some criteria to sort the list!

Any idea? @_@

Thanks
Francesca

Add new comment link

Is there a solution for swapping Add new comment link and subsequent links in this area to be wrapped with button tags, or replaced by and image?

contact us link in the primary menu

Hi!

Does everybody have an idea why the contact link (/contact.) in the primary menu of the website I am building doesn't have an active state when I am in the contact page?
The only difference with the other links in the primary menu is that the content type of 'Contact us' is 'survey' and not 'page'.

Does it make any difference?

Any other suggestions?

Thanks
Francesca

Custumized search form

Hey, I've put my search theme form in my header, in FF it works prefect.

In IE it works also, but if I open a book page my search form jumps from the left to the right where my logo and title is.

This is my css

/*
this will expand the default garland bar, make it bigger so our form and message can fit in.
*/
#navigation {
float: right;
padding-top: 50px;
}

/*
by default, the default form adds some surrounding space, this cancels it
*/
#navigation div.form-item,
#navigation div.content {
margin: 0; padding: 0;
}

/*
this adds some space in top and bottom, so anything inside can look vertically
centered
*/
#user-bar {
float: right;
padding: 0pt;
padding-top: 45px;
margin: 0pt;
position: absolute;
}

/*
by default, fields labels tries to reserve a whole line for itself, this
cancels that and and sends it to the left.
it also adds some space on the right and left of the label to look easy on
the eye.
#user-bar label {
float: left;
margin-left: 10px;
margin-right: 2px;
}
*/
#search-theme-form div{
margin-right: 0;
padding-right: 0;
}
#search #edit-submit{
cursor: pointer;
}

/*
inputs too, they try to reserve a whole line for itself, this
cancels that and sends it to the left
*/
#user-bar input {
float: left;
position: absolute;
}

/*

active state in primary menu

Hi all and nice to meet you,
I am a newbie so please be patient with me :)

I am building my first drupal website and one of the things I am struggling with is the menu active state.
The site I am building has an horizontal graphic primary menu on the top, and then a secondary menu on the left side (I created different menus for every item of the primary menu and made each of them visible only to some pages).

This is the code in the page.tpl.php


  <div id="menu">
  <?php if ($primary_links){ 
	$old_links = theme('links', $primary_links, array('class' => 'links primary_menu'));
	$new_links = str_replace('">home', '"><span>home', $old_links);
	$new_links = str_replace('">about', '"><span>about', $new_links);
	$new_links = str_replace('">what', '"><span>what', $new_links);
	$new_links = str_replace('">how', '"><span>how', $new_links);
	$new_links = str_replace('">clients', '"><span>clients', $new_links);
	$new_links = str_replace('">media', '"><span>media', $new_links);
	$new_links = str_replace('">contact', '"><span>contact', $new_links);
	$new_links = str_replace('</a>', '</span></a>', $new_links);
	print $new_links;
	

}
if (count($secondary_links)){
print theme('links', $secondary_links, array('class' => 'links secondary_menu'))
}

?>

Pages

Subscribe with RSS Subscribe to RSS - Theme development