This project is archived and is in readonly mode.

#1169 ✓resolved
Michael Grundkötter

Element.uid vs. forms

Reported by Michael Grundkötter | February 6th, 2011 @ 02:13 PM | in 2.0 (closed)

The Native.UID value which is assigned to each element does not work for forms which contain an input element with that name. (see example page: http://blog.aplusmedia.de/moo-uid-error/)

If I then use store/retrieve on that form it will still work BUT only if I do NOT have more than one form of that structure! Imagine a structure of a dynamic website where multiple forms like this are used (like in a backend to edit something). We use Form.Request for that which uses occlude() which uses store/retrieve. ALL forms will share the same Request object, as the lookup key for retrieve() will be the same "HTML input" instead of different integers.

May be fixed renaming the "uid" property of Element to something more obscure.

Comments and changes to this ticket

  • Arian

    Arian February 8th, 2011 @ 12:06 AM

    • State changed from “new” to “open”
    • Milestone set to 1.4.0
    • Assigned user set to “Christoph Pojer”
    • Milestone order changed from “885” to “0”

    Only thing I can think of would be renaming uid to something else.

    For now just don't use uid as id in forms. Unfortunately forms has this annoying legacy behavior.

  • mattcoz

    mattcoz February 12th, 2011 @ 10:07 PM

    I think that it would make sense to rename it to $uid. This would be consistent with the $family property.

  • Christoph Pojer

    Christoph Pojer April 16th, 2011 @ 09:52 AM

    • Milestone changed from 1.4.0 to 2.0
    • Milestone order changed from “1” to “0”
  • super-mario

    super-mario May 19th, 2011 @ 02:39 PM

    Here a small workaround for this bug.
    That works for me.

    Form.Request = new Class({
        Extends: Form.Request,
        occlude: function(property, element) {
            return false;
        }
    });
    
  • ibolmo

    ibolmo January 19th, 2012 @ 09:32 AM

    • State changed from “open” to “resolved”

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

Shared Ticket Bins

Pages