User login

Drupal

Incremental improvements make Drupal's code awesome

A fix was recently committed to both Drupal 8 and Drupal 7 to use #attached for block_admin_display_form() instead of drupal_add_css(). It only came up in my "Your issues" block on my drupal.org dashboard because, it turned out, i was the one who had initially complained about it. And that's all i did- looking for core examples to tell readers of dgd7.org how to write good code, i noticed core was in fact doing it wrong.

Simplify Drupal by Building Core Features with Building Blocks

It takes a very long (and enlightening and entertaining and informative) article to get there, but Jeff Eaton makes the key point which i think we all know in Drupal but can have trouble expressing. This is the key big picture for very many of our Drupal 8 initiatives:

Faking an active trail for items not in a menu: Drupal 7 active state for main menu based on content type

Situation: You have lots of content that you don't really want in a menu at all, but you want to appear to be below or within a section of the site when you are viewing that content. For instance, when viewing news content the menu link for the overall views listing should appear to be active, or rather in the active path or trail.

Return user to current page: How to link to a form from a Drupal menu

Press login / press account links for anonymous and logged in users, respectively. Subtly added to a bottom menu. Via code in order to allow for the redirect back to the page you were on after login or editing.

There is surely a way, or should be a way, that does not involve hook_page_alter(), but hey, this works.

Media module should use Views for Administration

Media module should at least come with proper Views integration and a number of default views for administration, probably making use of Views Bulk Operations.

This can be pure progressive enhancement, the code weight is in separate files and the rare person who does not have Views can use the much weaker administration pages Media currently has.

Modules to exclude selected content types from Drupal's search

http://drupal.org/project/search_block

http://drupal.org/project/search_config

I think this is my pick, Jennifer Hodgdon's Search By Page, it does more but it is all good things:
http://drupal.org/project/search_by_page

Background on the topic:

Exposed filters and VIews Gotcha

Ordinarily, when you leave off selecting a taxonomy term from a filter that says "Is one of", nodes tagged with that term will not show up in the View. However, when you make that filter an Exposed filter, the behavior changes. Even if you checkmark "Limit list to selected items", nodes tagged with that term will show in the initial view. Users see this item, but if they filter, they won't see it any more. Not exactly intuitive.

Two unsatisfying routes to manipulating presentation of addressfield output

[Status: No clean, lightweight solution to munging addressfields for loading elsewhere on the page. The current solution (waaaay at the bottom) splits the difference, in an almost certainly pointless compromise, but that's what happens when trying two different approaches-- you don't finish either of them. But each route looked so bad, once i got a good look, i figured the other had to be better. Now leaning toward my first instinct of loading the field with field_view_field() but i doubt that makes sense for anything but addressfields when your needs are simple.]

Create vocabulary and taxonomy terms in an installation profile

The first part is provided by the default installation profile:

Syndicate content