Quick question. Anyone have an idea how one might increase the number of menu weights available in the node editor and in the menu editor from the current 21 items (-10 through to 10) to a larger number? I suspect it is the same bit of code that generates this menu, but I'm darned if I can find it :|

Thanks in advance.

Comments

sparr’s picture

imho, the weights system is a hack. feels like a weekend project feature. what id love to see is a G2-like feature that keeps the current weight system, so nothing breaks, but makes it invisible, with the user-facing functionality allowing arbitrary element reordering and new weights are calculated in the background.

sorry for not helping with your request, but you tweaked one of my sore spots

halfer’s picture

Err, well, glad you had the opportunity to get that off your chest. Anyone got a suggestion?

vm’s picture

what about the weight.module in the contrib area ? I thought its intention was to do just this type of thing.

halfer’s picture

... I don't think I have come across that one before. Thanks very much, I will look into it :)

rezus’s picture

Go to the system.module and modify line 77.
For example:

$type['weight'] = array('#input' => TRUE, '#delta' => 30, '#default_value' => 0);

4kant’s picture

After this I got the the rank from -30 to 30.

But then all fields with a weight higher than 10 vanished in the edit form.
Why?

Where can I adjust this for the output?

4k

4kant’s picture

OK- Found this post:
http://drupal.org/node/117274#comment-703669
Some posts later in this thread there is also a tiny module (I did not try it...)

4k

sebastianrs’s picture

@sparr: Drupal is built up by community contributions... so why don't you suggest a definite plan to replace the weight system with something better? I'm sure there is a better and more automatic solution, but it would need at least a few developer willing to code and integrate that system throughout the Drupal core. The first step would be to devise a solution for the this :)