Closed (fixed)
Project:
Menu HTML
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Reporter:
Created:
3 May 2010 at 18:29 UTC
Updated:
19 Jul 2012 at 00:01 UTC
Jump to comment: Most recent file
This module is no nice, it's perfekt for adding id's and Classes to menu items. Please port it to drupal 7, I think it couldn't be very difficult, or is it? I'm sorry, my php knowledge is very small..
| Comment | File | Size | Author |
|---|---|---|---|
| #7 | menu_html-7.x.tar_.gz | 650 bytes | Josephnewyork |
| #6 | menu_html-fix_node_form-788722-6.patch | 470 bytes | lucascaro |
| #4 | html-menu.png | 126.63 KB | stevieb |
| #2 | port_to_d7.patch | 1.44 KB | Island Usurper |
Comments
Comment #1
killes@www.drop.org commentedI may do that when I find some time...
Patches are welcome...
Comment #2
Island Usurper commentedTa-da!
Comment #3
gagarine commentedComment #4
stevieb commentedafter updating a site from d6 - d7
I get the following errors with the patch in #2
Notice: Undefined index: original_item in menu_html_form_alter() (line 8 of .../sites/all/modules/menu_html/menu_html.module).
also the tick box "Allow html" keeps reverting to unselected
the links from the d6 site still show - properly formatted - but new links don't accept the html (see img)
Comment #5
lucascaro commentedWell, this worked for me dor drupal 7.12 so maybe the only thing missing is an upgrade path for d6 -> d7?
Comment #6
lucascaro commentedAfter using it for a while, I saw the error message reported by stevieb when editing a node, it seems to come from the line 8 at menu_html.module:
in particular from the part that reads || strpos($form_id, '_node_form') > 0 since it's trying to edit the node form whi doesn't have an element named 'original_item'.
There are 2 solutions to this bug.
a) removing the condition and not triggering the behavior on node_forms. Unless there is a particular reason to alter that form, this should be the chosen solution.
b) handle node_form correctly and alter the right element, which I couldn't find so far.
I'm locally doing a) and I'll post a patch here so other people can test it.
Comment #7
Josephnewyork commentedDidn't look and see this post before I wrote the D7 version, but I attached my D7 version of this if anyone is interested. Lightly tested, working fine. Code very similar to original 6.
Comment #8
jive01 commentedI can confirm that the above module works like a charm for D7. Be warned, the tar inside is marked menu_html-7.x.tar_ so I had to rename the file.
Please make this an official port.
Comment #9
gagarine commentedI just push my version.... please open new bug and keep this one close.
Comment #10
stevieb commentedjust to confirm the patch in #6 works
Comment #11
gagarine commented@stevieb you can use the 7.x-1.x-dev version on the project page. I will release a stable one after some peoples use it...