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

selecting checkboxes


 $form['area'] = array(
      '#type' => 'checkboxes',
      '#title' => 'Area',
      '#default_value' =>  '0',
      '#options' => $options_area,
      '#description' => ''
    );

This is just part of my edit page where I fetch all the information from the database and display it in the form elements. I need to be able to check certain checkboxes according to what was retrieved from the database. I cant seem to find a way to this.

I'm using drupal 4.7

Multiple files in video node?

I'm wondering if the new video module supports multiple file views. The module page suggests it does, but I'm specifically wondering if user can have the ability to choose which format they want to view the file in, after they have chosen a node. Example - a list of nodes will display a video thumbnail, user clicks that, then is asked to choose format. Or, alternatively, they see a default format but are given option to see in different format.

Thanks
Brett Gaylor

homelessnation.org

Warning in User.module

Hi..
when i new user add on my site,in my admin/user throws warning...

problem programmatically creating menu callbacks

I'm trying to programmatically generate team pages, and right now I'm getting weird results. Here's a code snippet from my implementation of hook_menu():

$query = db_query("SELECT tid, name FROM {dm_teams_info}");
while($entry = db_fetch_array($query)) {
  $items[] = array(
    'path' => 'teams/' . $entry['tid'],
    'title' => t($entry['name']),
    'callback' => 'dm_teams_teampage',
    'type' => MENU_CALLBACK,
  );
}

Basically, it takes all of the teams and calls dm_teams_teampage whenever the URL teams/{tid} is called (tid being a number). Right now, dm_teams_teampage simply returns the team number (using arg(1)).

I have three test teams in the DB with tid's 1, 2, and 3. When I call ./teams/1, everything works; ./teams/2 says page not found; ./teams/3 says access denied. Any ideas what's causing this error? Can multiple paths not have the same callback? Thanks!

Review Modules?

I know I saw a discussion somewhere on creating a review widget for CCK. I've now searched the site dozens of ways to find it and it seems to have disapeared. Anyone know what I'm talking about who can point me in the right direction?

Thanks!
--Ian

guestbook author links to profile?

I'm modifying the guestbook module to integrate more completely with a custom user profile. I've got it about 90% to where I need it, but I'm stymied by guestbook authors having their user names link back to their guestbooks (the default setting) instead of to their own user profiles (my preferred setting).

Anyone familiar with the inner workings of guestbook and can point me in the right direction?

I can locate the part of the code that FORMATS the author name, but I can't seem to locate where it's deciding what to make the a href. The format code is:

Line 541+

Pages

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