Add Plus1 Voting Widget to Nodes in Panels

If you're using ‎Panels‎ to output your content type and you enable the ‎Plus 1‎ module, you may notice the Plus 1 widget doesn't appear when you view your node.

If you don't see the widget, then you've probably enabled 'no extras' in your Panels node template override. If there's no other reason for enabling this option, you can simply uncheck the box and the Plus 1 widget will appear when you view your node.

If you do need to keep this unchecked, you can add a snippet to either your theme's node.tpl.php or node-customtype.tpl.php.

Open external links in a new window using jQuery

The way people have typically opened external links in a new window is to use the attribute target="_blank" in an <a> tag. The problem is that in HTML/XHTML Strict, the target attribute is deprecated.

While you can still use the target attribute if you're using the Transitional DOCTYPE, best practice is to adhere to web standards.

Theming a Specific CCK Field

The display of CCK fields is handled by the file content-field.tpl.php which is in the folder sites/all/modules/cck/theme. To override the display of a specific CCK field, the system will look for the format content-field-field_name.tpl.php in your theme directory.

Assuming you have a field named 'files', the name of your override would be content-field-field_files.tpl.php. If you're not sure of the field name go to admin/content/types and select the Fields tab - which will give you an overview of all your CCK fields.

Displaying your Drupal Mission Statement on Multiple Pages

While many sites don't need to utilize a mission statement, it can be useful for adding static content to your theme.

I needed to add copy to the header for a client that would appear on all pages, that they could easily edit and wouldn't involve any editing of the theme files. I immediately thought to use the mission statement that's available at admin/build/themes/settings. The only problem being that by default, the Drupal mission statement only appears on the home page.

Tags:

Testing IE6, IE7 & IE8 on one computer

Recently I had to add compatibility for IE6, IE7 & IE8 to a site I was working on. Only problem was that I can only have one version of IE installed on my machine.

more posts »

jsfwd on Twitter 

  • 12 hours 58 min ago hot damn rock vs rap!! thanks json RT @jswaby: @jsfwd http://www.sfspodcast.com rock vs rap
  • 13 hours 12 min ago #Raptors taking 5th seed back tonight! (with a little help from Boston)
  • 1 day 17 hours ago Two screens are better than one. I want. RT @BeCircle Yeah - iPad pwned by Courier. Way cooler and way more useful. http://bit.ly/aO4DqS
  • 4 days 18 hours ago World's largest gummy bear?!? http://www.giantgummybear.com I want one!
  • 5 days 21 hours ago Firefox 3.5 supports the word-wrap CSS property, finally :)
  • 6 days 12 hours ago Has anyone using #drupal and #mollom had any spam problems after upgrading from 6.x-1.10 to 6.x-1.12?
  • 6 days 12 hours ago @mollom has been almost flawless at blocking spam, but now cleaning uber-spam that started after upgrading the drupal module to 6.x-1.12.
  • 2 weeks 1 day ago February Drupal Toronto Meetup tonight... Topic: 'All about hosting' http://bit.ly/d8xM20
  • 2 weeks 5 days ago Since my earlier tweet re: http://pleaserobme #foursquare I've received over 7000 new opportunities! Who says there's a recession?
  • 2 weeks 5 days ago Tweeting your location can be hazardous to your home http://pleaserobme.com #foursquare
more jsfwd on Twitter »
i heart monkeys