See the Mailing lists or Drupal Issue queue. There are also various working groups on groups.drupal.org

node_prepare(), filters and theming

Please forgive me if this post seems naive or if it isn't really valid material for the Development forum. I'm new to Drupal and I'm just finding my feet.

I developed a module to produce a specific node type that will form the core of my site and I used the node_example.module as a frame work to guide me through the important steps. However I had lots of problems with theme tags not being passed to the browser from my code.

Is pagination for nodes being included in the next release -- 4.7?

Is pagination for nodes being included in the next release -- 4.7? I think this is a very basic feature which should be implemented.

Delete notification

I'm writing a module that makes use of information created/maintained by the profile module.
For completeness, it would be useful to know when a field was deleted through the admin interface.
Right now I have something like this added to the profile.module code:

Fatal error: Only variables can be passed by reference in user.module on line 1293

Hey everyone,

I'm kinda new to drupal just installed it today as my personal website and ran into a problem. When I log in as admin go to Administer > Access Control > Configure I get the following error:

Fatal error: Only variables can be passed by reference in c:\Inetpub\wwwroot\modules\user.module on line 1293

I'm not familiar enough with the product yet to give much info so if you need any additional info let me know and will try and get it.

There is a mention of a few patches out but not sure where to find those or how to apply them.

Why is the $edit = $_POST['edit'] notice ommited?

In Drupal, many functions use the following code:

function foo() {
  if ($edit = $_POST['edit']) {
    // let's do stuff with the post variables
  }
}

Using the Drupal way of coding for my own projects, I used the same $edit = $_POST['edit'] line in one of my websites. PHP then returned me "Notice: Undefined index: edit in C:\Program Files\Apache2\htdocs\shop\login.php on line 5" every time when the page was loaded directly from the browser (so: no form data was submitted).

Static link support for menus?

I made a small change to theme_menu_item_link (includes/menu.inc) which will allow you to enter a static link to be displayed as a menu item.

Original:

function theme_menu_item_link($item, $link_item) {
  return l($item['title'], $link_item['path'], array_key_exists('description', $item) ? array('title' => $item['description']) : array());
}

New:

function theme_menu_item_link($item, $link_item) {
  $link = '';

  if(substr($link_item['path'], 0, 5) == "link:") {
    $link_item['path'] = substr($link_item['path'], 5);

    // This needs to be a new function in common.inc - such as "static_link" or such
    // static_link($item['title'], $link_item['path'], array_key_exists('description', $item) ? array('title' => $item['description']) : array());
    // -Start-
    $text = $item['title'];
    $url = substr($link_item['path'], 5);
    $attributes = array_key_exists('description', $item) ? array('title' => $item['description']) : array();
    $link = '<a href="/'. check_url($url) .'"'. drupal_attributes($attributes) .'>'. ($html ? $text : check_plain($text)) .'</a>';
    // -End-
  }
  else {
    $link = l($item['title'], $link_item['path'], array_key_exists('description', $item) ? array('title' => $item['description']) : array());
  }
  return $link;
}

Themed menu links will need to be updated as well (eg. mytheme_menu_link_item) as well as the Theme Engines.

Pages

Subscribe with RSS Subscribe to RSS - Deprecated - Drupal core