I would seriously recommend against XML. While I agree it won’t be going away for this stuff, it should. It’s easy to get XML wrong or to make it fit a particular cognitive bias for what data should look like. Or to pile on schemata and namespaces and make a beast so goofy it requires a manual to formulate a basic API request and parse the results.

JSON is nude Arrays, Hashes, Strings, Integers, and Booleans. It is what it is and it’s UTF-8. I would *never* use XML as the serialization or data layer in a project if I had the choice. And I resent the hoops through which I have to jump due to it being every Java hackers first choice.

Ajax was only XML at first, hence the “x.” Today hardly anyone is doing it in anything but JSON. It wasn’t a corporate agenda that did that, it was path of least resistance and fewest bugs.

More than KISS, I’d say use the abstractions that abound. There are a couple dozen *excellent* JS kits now that take away the pressure of having to deal with browser nonsense. There are as many nice CSS templates which will gracefully adjust to monitor size, be it a phone or a cinema display. The guts of a CMS can be written in Catalyst/REST or Mojo or Dancer or Amon2 or… in a week by anyone who has experience; mix in Oauth2 or something and you don’t even have to keep formal user accounts or manage password issues. A beginner might need three months…and that includes getting help when necessary, but it is worth it and doing it on your own means you become more employable should you choose to go that route.


In reply to Re^7: Are there any issues with JSON by Your Mother
in thread Are there any issues with JSON by taint

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.