User login

Complete

To be used with care. Pages are complete only when they meet the posting guidelines.

Undo a conflicting change in your working copy that you didn't want anyway

In short, resolve a conflict in favor of the outside repository.

The file can be a

mv offending.file ~/elsewhere
git checkout offending.file

See also for resetting everything: http://agaric.com/note/git-update-and-ignore-local-changes

Example of hook_block in Drupal 6

<?php
/**
* Implementation of hook_block().
*/
function fightfi_block($op = 'list', $delta = 0) {
  $block = array();
  switch ($op) {
    case 'list':
      $block[0]['info'] = t('Sidebar Links');
      $block[1]['info'] = t('Footer Links');
      return $block;
    case 'view':
      switch ($delta) {
        case 0:

Drupal 7 module development gotchas

First we discovered that you need a .module file for your module to be recognized. A .info file is not enough. (In this case, we only wanted the .install file, we made an empty .module file, and all was well. But then we wanted to add some functions to that empty .module file...)

Now we have found that you need to declare

files[] = agaric_example.module

in your agaric_example.info file for your agaric_example.module to be read!!!

May Western Mass Drupal Meetup Notes

Here is a breif outline of what I went over

Feed API module
http://drupal.org/project/feedapi

http://dhakimzadeh.com as a use case
setting up feeds
-linking to content types
-mapping fields
-views integration
setting up a point and click blog site with google reader, and things like it

How to Unpublish Content

Gus helped a client who wanted a quotation to no longer appear in the rotation for a random quotation block.

Dear client,

Yes, you can delete the quote. Though you probably would simply want to unpublish the quote instead of deleting it. This way you can use the quote in the future without having to re-enter it. If you go here:

http://example.com/admin/content/node

Drupal 7's jobqueue doesn't guarantee your hard drive won't be hit by a meteor

Meteor safety is surely the most important metric in open source free software, and we must warn you: Drupal 7's new Jobqueue doesn't guarantee your hard drive won't be hit by a meteor.

This has been a public service announcement from Agaric Design Collective. Good day.

Get the lesser of two or more values with PHP

I love it when PHP has the logically named function. To get the lowest of two or more variables, min($var1, $var2)

Resolution

Patterns

Patterns module
Creating or Writing Patterns documentation

The more modules that allow exportable configuration for use like this, the better, and the easier it will be to use DBScripts to do the rest.

Resolution

Syndicate content