Awesomeness redefined: Drupal 7 Theming

13 November 2009 mortendk

Last time the king of denmark was here in stockholm 40 nobles were decapitated. Now I had the opportunity to present the new Drupal 7 theme layer at the Drupal Stockholm, and that will cost 40 modules their head. The 2. Bloodbath in stockholm: drupal 7 theming ;)

Whats new in Drupal7 Theming


I must admit I have been very lazy (and busy at work) so I havent been putting so much time, as i should, into the whole Drupal7 theme, as i would and should - But WOW the theme layer looks so sweet it will turn water into beer
For realz we can no finally do what we always wanted to do \mm/

Heres my slides fromt the session: whats new in drupal 7 theming slides

Drupal 7 Theming is gonna change the way we look at themes!

  1. Drupal render & hide
    You can now hide elements from the $content, and print them later in the .tpl files
    so something like this
      //hide elements from $content
      hide($content['field_image']);
      hide($content['links']);

      //print whatever thats we didnt hide
      print render($content);

      //print the image field
      print render($content['field_image']); 
  2. hook_form_alter
    This is really awesome - themes can now actually do stuff with forms!
    This basically means that the small module a themer have to do to be able to change even the simpelst things in a form. is now going away.
    Ive heard some developers crying that now the themer can destroy the site - well get down from your high horse please ... We can do that allready - die("Im sick and tired of having to add modules to change my markup");
    This means that we now have the same tools as the modules have to change the markup - so now it make sence to learn that form api thing ;)
    Seriously im so hyped about this that i wanna make drupal7 Sites now!
  3. hook_page_alter
    Grap the whole page just before its rendered, and mess around with it its one biiiig array so you can really fun
    with the content for the final page

And thats just a small part of whats new so go grap a devel version of d7 it now and play around its amazing

Resources

Mothership

I did the first real presentation of my "clean up the html" theme, showed of some of the coolness that themes can get out of using the mothership as a preloading theme. I really hope I can get other front end loving geeks into rocking with me on this so we can get the markup to be as beautiful on the front end as it is on the backend
A thing i was really happy with was the comments "Im happy that im not the only one that cares about the way the source looks"
Will mothership be ported to drupal 7 - well what do you think ;)

All you html are belong to us Slides

Sweden Röcks

The worlds first hard rock Drupal Tribute band saw the light of day at the event: Kitten Killers
http://www.youtube.com/watch?v=L2pXcNu4GRo

Watch them live: http://www.twitvid.com/F2F66

They totally Gets the Drüpal Rocks concept ;)
What im hoping for is the rewrite of Judas Priests classic: "Breaking the Law" try shifting that out with "Hacking core"...

Im hoping that we can get them to play copenhagen sometime in 2010

Its pretty cool to se how much ass the swedes are kicking - Last time I hooked up with the Swedes, Druplicon got laid at my local bar - Besides of hanging out and talking drupal for 2 days.

A big thanx to the nodeone Guys & Girls they have been wonderful host. and have made sure that everything just worked and us invited guest really felt welcome all around.
oooh and Big kudos! for make sure that I had a hotel booking now im staying the weekend here in stockholm with the Queen - i mean how awesome is that! Its the Drupal community love kicking in.

Its actually hard when I as a Dane see the swedes raising the standards for drupal comunity buikding - but you better belive that the Drupal Copenhagen Camp in May will follow up on this, and redifine awesomeness! if not ill change my name to Rainbow moonbeam!

Pingback

[...] Awesomeness redefined: Drupal 7 Theming | morten.dk morten.dk/blog/awesomeness-redefined-drupal-7-theming-0 – view page – cached Last time the king of denmark was here in stockholm 40 nobles were decapitated. Now I had the opportunity to present the new Drupal 7 theme layer at the Drupal Stockholm, and that will cost 40... Read moreLast time the king of denmark was here in stockholm 40 nobles were decapitated. Now I had the opportunity to present the new Drupal 7 theme layer at the Drupal Stockholm, and that will cost 40 modules their head. The 2. Bloodbath in stockholm: drupal 7 theming ;) Read less [...]

Pingback

[...] here to see the original: Awesomeness redefined: Drupal 7 Theming | morten.dk By admin | category: Drupal, Object | tags: acquia, chief-technology, dries, Drupal, [...]

Thnaks Morton for the great

Thnaks Morton for the great presentation (new in d7 theming.pdf). It was a real pleasure to read about all the great new stuff in D7.

CompuBase 13 November, 2009 - 18:02

Pingback

[...] the original:  Awesomeness redefined: Drupal 7 Theming | morten.dk By admin | category: Object, drupal | tags: acquia, chief-technology, dries, drupal, [...]

Pingback

[...] more here: Awesomeness redefined: Drupal 7 Theming | morten.dk Share and [...]

Pingback

[...] 7 desde la perspectiva de un usuario final, en drupal coder y desde la perspectiva de un themer, en morten.dk. (en [...]

Just want to thank you

For all your work on Mothership, and your blog which I hit up every once in a while. Mothership was exactly what I wanted when I started using Drupal, and I have a couple personal tpls to pair the html down even further. If and when I write a personal ultra sparse html Drupal theme for html5, what I've learned from the Mothership code will get me 80% there. So thanks again.

Rob W. 19 October, 2010 - 03:42

Pingback

[...] Introduction It is common knowledge that when writing a research article for a journal, certain average have to be followed and applied throughout the article structure and its contents. In some cases, these kinds of rules may render the article understandable only by those who are researching in the same field, and certainly not by the common public. The boundary which can clearly separate vital academic research from the rest of the population is nothing however a self-imposed limit… More information: หมวกเด็ก [...]
The Dilemma of Journal Publication 16 November, 2010 - 14:24

Pingback

[...] with very small competition for a product you desire to sell as an affiliate? More information: football shirt No Comments » [...]

Pingback

[...] Do you always have cold? Are you the person that in the dead of summer is walking encircling with a runny nose and feeling generally terrible? If you believe that you always have a cold, you may be quite surprised that what you have may not be a cold at all! Here are two surprising facts about colds that may alter your intellect! More information: กระเป๋าสะพาย [...]

Pingback

[...] insurance. Find outside what you can do that will aid you avoid getting these. More information: วอลเปเปอร์ติดผ&#... Categories: Uncategorized Read More PreviousThe Benefits Of Kohler Residential [...]

Pingback

[...] finances. You desire to step up to aid. What can you do to become their guardian? More information: used rosetta stone spanish Categories: Uncategorized 16 Dec [...]

Drupalcon

Really enjoyed your presentation at DC, you seem like a really great developer and the world needs more great drupal people!!

Anonymous 16 March, 2011 - 16:01

Thanks!

Thank you for the info & help!
Will read it twice again : )

Anonymous 19 April, 2011 - 08:22

mothership theme features awesom

drupal 7 mothership theme is awesome looking forward to build theme of my site under mothership base theme. but still need more new awesome feature . so it can help us to build classic themes of drupal

lalit 13 August, 2011 - 20:52

Thanks

HI,

Thanks to share this information.

jayendra 11 November, 2011 - 11:54
The content of this field is kept private and will not be shown publicly.
@danigrrl yup true and she is the source for it - but okay she don't touch my espresso machine so i guess its okay (almost) 24 min 1 sec ago
3,251

DrupalCon Denver 2012 - I am a Speaker!

good Stüff

Mothership - a clean up the crap "theme"

Miro - a open atrium theme:
more info & comments

freya rocks

the progress for my premature daughter can be folllowed here:
Freya Rocks
sorry its in danish

the blög

Give some Love to the development of the mothership

Flattr this

User login

Recent comments

give some luv

drupal member ...

geek royale