1. 27 Mar, 2006 1 commit
  2. 21 Feb, 2006 1 commit
  3. 26 Jan, 2006 1 commit
  4. 20 Jan, 2006 1 commit
    • Dries's avatar
      - Patch #45530 by Morbus: filter_form shouldn't default to #weight 0 · 8c02d4ec
      Dries authored
      When a form element doesn't specify a #weight, it is assumed internally as #weight 0. However, to ensure that our form elements display visually *as they were defined in the array* we, in form_builder, count the number of elements, divide by 1000, and set that as the weight:
      
      # Assign a decimal placeholder weight to preserve original array order
      if (!isset($form[$key]['#weight'])) {
        $form[$key]['#weight'] = $count/1000;
      }
      
      The above code will set the #weights of elements that have not defined a weight to something like 0 (first element in array definition), 0.001, 0.002, and so on. However, anytime a form element *explicitly* defines a #weight of 0, that #weight is kept at exactly 0, which would cause that form element to appear BEFORE the elements that didn't have a #weight defined (and thus received a #weight such as 0.002).
      
      Consider the following pseudo example:
      
      $form['game_title'] = array(
          '#type' => 'textfield',
          ...
          );
      $form['game_description'] = array(
          '#type' => 'textarea',
          ...
          );
      $form['game_format'] = filter_form(variable_get('game_format', NULL));
      return $form;
      
      Here, we're not definiing weights on our two textfields. We then add an filter_form. The second parameter of the filter_form is $weight, which defaults to 0. After this $form hits form_builder, we have weights 0 (game_title), 0.001 (game_description), and 0 (filter_form) respectively. This is then sorted by weight, which causes filter_form (the third element in the array) to appear BEFORE game_description (0 is lighter than 0.001).
      
      The short lesson is: explicitly defining #weight 0 for a form element is probably a bad idea. This patch changes the default #weight of filter_form to NULL, instead of 0, and also removes any other explicit setting of #weight to 0 in core.
      8c02d4ec
  5. 19 Jan, 2006 1 commit
  6. 18 Jan, 2006 1 commit
  7. 29 Dec, 2005 1 commit
  8. 05 Dec, 2005 1 commit
  9. 23 Nov, 2005 1 commit
  10. 12 Nov, 2005 2 commits
  11. 01 Nov, 2005 1 commit
  12. 11 Oct, 2005 1 commit
  13. 07 Oct, 2005 2 commits
  14. 28 Sep, 2005 1 commit
  15. 23 Sep, 2005 1 commit
  16. 18 Sep, 2005 1 commit
    • Dries's avatar
      - Patch #3986 by James (and Boris :)):consolidated all feed-related settings in one place. · 1dc53d97
      Dries authored
      * adds a "feed settings" section to admin/settings where 2 new settings are introduced:
      * number of items per feed
      * default length of feed descriptions (title only, teaser, full)
      * patches all of core to obey the above - including the new aggregator (out) feeds
      * adds support for adding namespaces in _nodeapi('rss item') - which means things like iTunes RSS and yahoo's media rss can be implemented by the appropriate modules (i.e. audio.module)
      * includes some additional info in the default node feed - specifically the element (links directly to comments) - and dc:creator - to show node author information.
      1dc53d97
  17. 14 Sep, 2005 1 commit
  18. 07 Sep, 2005 1 commit
  19. 29 Aug, 2005 1 commit
  20. 28 Aug, 2005 1 commit
    • Dries's avatar
      - Patch #29785 by Chx: multiple node types were broken so we refactored · c9fc300b
      Dries authored
        part of the node system!  If you have a module that implements node
        types, you'll have to udpate its CVS HEAD version.
      
        We replaced _node_name() and _node_types() by _node().  The new _node()
        hook let's you define one or more node types, including their names.
        The implementation of the _node() hook needs to:
      
         return array($type1 => array('name' => $name1, 'base' => $base1),
                      $type2 => array('name' => $name2, 'base' => $base2));
      
        where $type is the node type, $name is the human readable name of the type
        and $base is used instead of <hook> for <hook>_load, <hook>_view, etc.
      
        For example, the story module's node hook looks like this:
      
          function story_node() {
            return array('story' => array('name' => t('story'), 'base' => 'story'));
          }
      
        The page module's node hook module like:
      
          function page_node() {
            return array('page' => array('name' => t('page'), 'base' => 'page'));
          }
      
        However, more complex node modules like the project module and the
        flexinode module can use the 'base' parameter to specify a different base.
      
        The project module implements two node types, proejcts and issues, so it
        can do:
      
          function project_node() {
            return array(
             array('project_project' => array('name' => t('project'), 'base' => 'project'),
             array('project_issue' => array('name' => t('issue'), 'base' => 'project_issue'));
          }
      
        In the flexinode module's case there can only one base ...
      
        This hook will simplify the CCK, and will make it easy (or easier) to merge
        the story and page module.
      
        In addition, node_list() became node_get_types().  In addition, we created
        the following functions: node_get_name($type) and node_get_base($type).
      c9fc300b
  21. 25 Aug, 2005 1 commit
  22. 31 Jul, 2005 1 commit
  23. 29 Jul, 2005 1 commit
  24. 25 Jul, 2005 1 commit
  25. 17 Jul, 2005 1 commit
  26. 02 Jul, 2005 1 commit
  27. 31 May, 2005 1 commit
  28. 28 Apr, 2005 1 commit
  29. 24 Apr, 2005 1 commit
    • Dries's avatar
      · a76a1e1f
      Dries authored
      - Patch 20910 by chx: centralize print theme page.
      a76a1e1f
  30. 12 Apr, 2005 1 commit
  31. 12 Feb, 2005 1 commit
  32. 29 Jan, 2005 1 commit
  33. 26 Jan, 2005 1 commit
  34. 25 Jan, 2005 1 commit
  35. 16 Jan, 2005 1 commit
    • Dries's avatar
      · 971a0e24
      Dries authored
      - Patch #14731 by chx: made it possible to rewrite node queries.
      971a0e24
  36. 15 Dec, 2004 1 commit
    • Dries's avatar
      - Patch #13907 by Neil: less ways to set the page title. · 2b17b3a9
      Dries authored
         * Less logic in theme code.
         * Encourages use of the menu system.
         * Easier to find where a title or breadcrumb comes from in other people's code because there are less places to look. Look in menu and then grep for the appropriate set function. Looking for calls to theme_page() is hard because there are too many of them.
         * Very slightly more efficient.
      2b17b3a9
  37. 07 Dec, 2004 1 commit
    • Dries's avatar
      · 60352821
      Dries authored
      - Refactored the queue module: removed the queue module's field from the node table.  With help from Gerhard.
      
      - Slight addition to INSTALL.txt with regard to PHP versions.
      
      - Updated/reworded some node type descriptions as per Boris' suggestions.
      
      - Adding missing {} around a table name in update.php.
      60352821
  38. 24 Nov, 2004 1 commit
    • Dries's avatar
      · 4726c931
      Dries authored
      - Patch #13443 by Moshe: got rid of the semi-implemented 'page link' feature. All themes currently support primary and secondary links so page links are now deprecated.  Check your contributed modules and update them accordingly.
      4726c931