This forum is for module development and code related questions, not general module support. For general support, use the Post installation forum.

Form API - Handling multiple select, when no data selected

I have been noodling over this off & on for a couple days, cruising the forums, not finding an answer:

I have a custom node that has a multi-select box. Like this:

Tablesort, pager, and search in 4.7

Can anyone point me in the direction of any resources concerning using a custom search page and displaying it in a tablesort with a pager in 4.7?

The requirements of the project are to create a search form that consists of:

MENU_DEFAULT_LOCAL_TASK - I do not want a default tab

http://drupaldocs.org/api/head/function/hook_menu says: Every set of local tasks should provide one "default" task, that links to the same path as its parent when clicked.

Why?

I have a list of services displayed on a page, and when one service is clicked the user gets presented with a set of tabs under which they may modify different items. I do want one 'default' task which will be the tab which is selected by default (ie the first tab). I do not, however, want it to link to the parent, which is the service list - that makes no sense to my interface, where the service list is a link in the Navigation Block already.

I have tried to make all three tab items 'type' values into MENU_LOCAL_TASK but then the first one behaves the same as a MENU_DEFAULT_LOCAL_TASK: It links back to the service list instead of linking to the 'url' I entered in the array in hook_menu. So the user cannot return to the first tab once he has visited the second tab; he needs to select the service again from the list.

How can I disable this 'default' tab behaviour, or work around it to force all three of my tabs to point to their 'url's as defined in the hook_menu function?

$links[] = array('path' => 'services/'.$q[1].'/edit/basic',
'title' => t('Basic'),
'callback' => 'edit_basic',
//'access' => TRUE,

hooks for new revision in 4.7

I'm relatively new to Drupal but I'm digging in deeply and making my own custom node type. It has a seperate mysql table to store data (flexinode didn't do as much as I needed). So far I've got the basics working pretty well, but I dont see any docs on what hook Drupal calls when creating a new revision. I thought it would be hook_update, but I don't see that running. I want to create a new corresponding version of my data whenever a new revision of the node is created.

Thanks!

which module to use for restricting access to certain categories or taxonomies?

Hello Everyone,

I'm interested in running drupal and just succeeded yesterday in the installation, which went fine. Now I need to find a module that will give me the facility to restrict my users, based on their "group" or "role" to certain content. I don't want groupA to view content intended for groupB for example. I hope I was clear enough for you to understand!

Also I'm planning to have some documents to be exchanged between the users and just downloaded file_manager.module, not sure if it is the right one for that yet but I will be testing it shortly.

Updated spellcheck module - now what

Hi all. I've completly rewritten the old 4.5 spellcheck module. I'm ready to 'release' the module and wonder what I'm supposed to do now. I could create a patch, but there is almost nothing that remains from the old spellcheck module. This is also my first module for Drupal, so I'm hoping I've done everything correctly.

So what should I do now?

Pages

Subscribe with RSS Subscribe to RSS - Module development and code questions