Opened 17 years ago

Last modified 7 years ago

#120 new refactoring

replace ["..."] with dot notation in JS

Reported by: christoph Owned by: mapbender_dev@…
Priority: major Milestone:
Component: core Version:
Keywords: Cc:

Description

toJSONString() does not work with ... syntax!

Change History (5)

comment:1 by marcjansen, 17 years ago

I've got some questions:

  1. What is meant by ["..."]-syntax vs. dot-syntax?
    anyObject.newProperty = "new value";
    instead of
    anyObject["newProperty"] = "new value"

  2. Which toJSONString is meant?
    anyObject.toJSONString();
    or the (at least planned)
    toJSONString(anyObject);

comment:2 by christoph, 17 years ago

  1. correct. I tried converting the map object to JSON via toJSONString(), and the entries for the arrays created with the bracket syntax were omitted. I had to use the dot syntax. Now I realize why JSLint always complains about the bracket syntax.
  1. I mean the anyObject.toJSONString from json.js, which itself is from www.json.org

comment:3 by christoph, 16 years ago

Milestone: 2.5 release3.0 release

comment:4 by christoph, 16 years ago

  1. we now use $.toJSON(anyObject) from extensions/jqjson.js

comment:5 by astrid_emde, 7 years ago

Milestone: 3.0 release

Ticket retargeted after milestone deleted

Note: See TracTickets for help on using tickets.