Menu

#8 Name mangling not JavaScript safe

1.0RC1
open
None
5
2001-09-14
2001-09-14
No

If a name attribute of an entry starts with a digit,
the generated name for images will start with an
digit, too. This leads to errors if one tries to use
it in JavaScript as name for an object, e.g. for
mouseOver effects.

Discussion

  • Peter Becker

    Peter Becker - 2001-09-20

    Logged In: YES
    user_id=41603

    If multiple sections contain entries with the same name the
    name mangling breaks, too. I guess the best way to solve
    this problem is to just use a counter and call the
    images "img1", "img2" and so on. Makes debugging the
    javascript slightly harder but this should be safe.

     
  • Peter Becker

    Peter Becker - 2001-09-28

    Logged In: YES
    user_id=41603

    The problem with the digit should be fixed in CVS but we
    definitely need a better name mangling scheme.
    Currently "19 abc" and "99 abc" will be both changed
    to "_9_abc", safe in themself but a conflict if they are
    both used.

     

Log in to post a comment.