Comment On Keep it Simple and Stupid

Diego G. lives in Argentina and is working with a developer from the USA on a PHP project. Recently they were discussing the merits of handling the communication from the backend to the frontend via XML or JSON. The system used XML elsewhere already, but for the new work it looked like it'd be quicker and easier to work with JSON in the PHP pages. [expand full text]
« PrevPage 1 | Page 2Next »

Re: Keep it Simple and Stupid

2008-11-17 09:03 • by memals (unregistered)
looks an awful (pun intended) lot like http://thedailywtf.com/Articles/XML_vs_CSV__0x3a__The_Choice_is_Obvious.aspx
How many times will history repeat itself ?

Re: Keep it Simple and Stupid

2008-11-17 09:04 • by Claxon
About time too! It's been far too long since we've had someone doing something unspeakable with XML.

Re: Keep it Simple and Stupid

2008-11-17 09:09 • by Anonymous (unregistered)
Should we do something simple, or do something complicated?

Let's do both!

CAPTCHA: Facilisis. Sounds like an infection caused by apps like this.

Re: Keep it Simple and Stupid

2008-11-17 09:10 • by Anonymous (unregistered)
Nice one guys, I had to laugh at this (all too familiar) misuse of XML. Still, I think you need to work on some new article names - this one sounds awfully familar...

http://thedailywtf.com/Articles/Keeping-It-Stupid-Simple.aspx

Re: Keep it Simple and Stupid

2008-11-17 09:24 • by Anonymous (unregistered)
I was attracted to your site because I was looking for a good sample of XJSON. This definitively helps! Thanks.

Re: Keep it Simple and Stupid

2008-11-17 09:24 • by snoofle

<!-- HTML doc to pass an HTML doc -->
<WrapperDocument>
<Destination>htt://TheDailyWTF.com</Destination>
<Sender>snoofle</Sender>
<document>
<http://thedailywtf.com/Comments/AddComment.aspx?ArticleId=6365>
<Comment>
WTF!?
</Comment>
</document>
</WrapperDocument>

Re: Keep it Simple and Stupid

2008-11-17 09:28 • by Mariano (unregistered)
Very funny!!!

Re: Keep it Simple and Stupid

2008-11-17 09:32 • by Santa (unregistered)
TRWTF is "save-date-yyyy":"Oct 27"

Re: Keep it Simple and Stupid

2008-11-17 09:36 • by Zeal_ (unregistered)
Encapsulating JSON in XML? This one should definitely be taken a photo of on a wooden table. On a truck. On a freight train.

Re: Keep it Simple and Stupid

2008-11-17 09:37 • by Dougal (unregistered)
229440 in reply to 229433
You call that HTML? lol

Re: Keep it Simple and Stupid

2008-11-17 09:38 • by J.R. "Bob" Dobbs (unregistered)
As an aside, I just love their very clever JSON date field names. On seeing a name like ".*mmdd", you would be tempted to fill it with something like "1027", without even looking at the documentation, huh? Well, you won't pull that one with these guys (I'm not counting the "yyyy" also being "Oct 27", as it's obviously a typo).

Re: Keep it Simple and Stupid

2008-11-17 09:39 • by dave (unregistered)
Reminds me of the days at uni when one person had the genius idea of storing his MySQL queries in an XML database.

Re: Keep it Simple and Stupid

2008-11-17 09:48 • by 008 (unregistered)
229444 in reply to 229440
Dougal:
You call that HTML? lol


No, I'm pretty sure we call it (a horrible use of) XML.

CAPTCHA: jugis (If you remove the i, then hell yes, please)

Re: Keep it Simple and Stupid

2008-11-17 09:50 • by rohypnol
229445 in reply to 229432
Anonymous:
I was attracted to your site because I was looking for a good sample of XJSON. This definitively helps! Thanks.

They should probably write a prototype for this and name it XMLJSONHTTPRequest which would unpack the XML and create an object hierarchy in JavaScript populating the end-objects with information from JSON strings, all of which is received over a HTTP connection. The library would make things so much simpler when it comes to doing all this...
And if it the server-side only works with the database, they could write the queries on the client and then the library which should keep things As Simple As Possible would be called MySQLXMLJSONHTTPASAPRequestHandler. It would be a very complex thingy that keeps lots of other thingies simple.

Re: Keep it Simple and Stupid

2008-11-17 10:03 • by Mcoder
That's what they get asking.

Remeber, people, the next time you face an unsolluble (there is no "better" option, just options) technical choice and think about asking management, don't!

Re: Keep it Simple and Stupid

2008-11-17 10:04 • by Anonymous (unregistered)
the real wtf is why are they trying to write an actual application using PHP

Re: Keep it Simple and Stupid

2008-11-17 10:11 • by h (unregistered)
"save-date-yyyy":"Oct 27"

Oh yeah, I was so wasted during the year of Oct 27. So wasted, I thought we were still using numbers...

Re: Keep it Simple and Stupid

2008-11-17 10:15 • by Vollhorst (unregistered)
229450 in reply to 229449
h:
"save-date-yyyy":"Oct 27"

Oh yeah, I was so wasted during the year of Oct 27. So wasted, I thought we were still using numbers...


Oct 27 == Dec 23

Don't see a problem here.

Re: Keep it Simple and Stupid

2008-11-17 10:16 • by Anonymous Cow-Herd (unregistered)
229451 in reply to 229448
Anonymous:
the real wtf is why are they trying to write an actual application using PHP


I see what you did there.

CAPTCHA dupe: facilisis

Re: Keep it Simple and Stupid

2008-11-17 10:22 • by SchizoDuckie (unregistered)
229452 in reply to 229450
Vollhorst:
h:
"save-date-yyyy":"Oct 27"

Oh yeah, I was so wasted during the year of Oct 27. So wasted, I thought we were still using numbers...


Oct 27 == Dec 23

Don't see a problem here.


Actually, according to my calc.exe Oct 27 == 33

Re: Keep it Simple and Stupid

2008-11-17 10:26 • by JamesQMurphy
Notice how the vendor is Johann Sebastian Bach. Now I know what inspired Toccata and Fugue in D minor.

Re: Keep it Simple and Stupid

2008-11-17 10:28 • by Vollhorst (unregistered)
229454 in reply to 229452
SchizoDuckie:
Vollhorst:
h:
"save-date-yyyy":"Oct 27"

Oh yeah, I was so wasted during the year of Oct 27. So wasted, I thought we were still using numbers...


Oct 27 == Dec 23

Don't see a problem here.


Actually, according to my calc.exe Oct 27 == 33
Nope.
Oct 33 = Dec 27

Re: Keep it Simple and Stupid

2008-11-17 10:28 • by DaveAronson
> XML or JSON

Therein lies the problem. Should have been "XML xor JSON".

Re: Keep it Simple and Stupid

2008-11-17 10:28 • by ricecake (unregistered)
229456 in reply to 229452
SchizoDuckie:
Vollhorst:
Oct 27 == Dec 23


Actually, according to my calc.exe Oct 27 == 33

Umm, Oct 27 == 2*8 + 7 == 16 + 7 == 23

Re: Keep it Simple and Stupid

2008-11-17 10:30 • by Brian LaPierre (unregistered)
229458 in reply to 229452
SchizoDuckie:
Vollhorst:
h:
"save-date-yyyy":"Oct 27"

Oh yeah, I was so wasted during the year of Oct 27. So wasted, I thought we were still using numbers...


Oct 27 == Dec 23

Don't see a problem here.


Actually, according to my calc.exe Oct 27 == 33


Pray tell how the octal representation is less then the decimal representation when you can't use 8 or 9?

Re: Keep it Simple and Stupid

2008-11-17 10:32 • by John (unregistered)
229459 in reply to 229452
Some trolling that's so clever it's gone over my head?
How can a number represented in a higher base look bigger?

Ah, of course you're using calc.exe
penandpaper.exe is a lot less buggy, but only slightly less buggy than brain.exe

Re: Keep it Simple and Stupid

2008-11-17 10:35 • by Pablo (unregistered)
229460 in reply to 229452
Then it's no surprise that the correct result is 23:

Oct 27 = 2*8 + 7 = 23

At least gcalctool gets it right

Re: Keep it Simple and Stupid

2008-11-17 10:41 • by campkev
229461 in reply to 229459
John:
Some trolling that's so clever it's gone over my head?
How can a number represented in a higher base look bigger?

Ah, of course you're using calc.exe
penandpaper.exe is a lot less buggy, but only slightly less buggy than brain.exe

don't blame it on calc.exe. it returns 23 for me. It was operator error, he did it backwards. dec 27 = oct 33

Re: Keep it Simple and Stupid

2008-11-17 10:47 • by Pendi (unregistered)
229463 in reply to 229460
Pablo:
Then it's no surprise that the correct result is 23:

Oct 27 = 2*8 + 7 = 23

At least gcalctool gets it right


That's why real programmers get confused by Halloween and X-Mas, cause OCT 31 = DEC 25

...

Re: Keep it Simple and Stupid

2008-11-17 10:51 • by starlite (unregistered)
*ouch*
I neer saw THAT coming...

Re: Keep it Simple and Stupid

2008-11-17 10:54 • by mopp (unregistered)
229466 in reply to 229455
DaveAronson:
> XML or JSON

Therein lies the problem. Should have been "XML xor JSON".


Thanks -- you just teached me what xor is for :)

Re: Keep it Simple and Stupid

2008-11-17 11:03 • by sakabako (unregistered)
I got a JSON array of strings of JSON once. I was speechless.

Re: Keep it Simple and Stupid

2008-11-17 11:12 • by John (unregistered)
229470 in reply to 229461
campkev:
John:
Some trolling that's so clever it's gone over my head?
How can a number represented in a higher base look bigger?

Ah, of course you're using calc.exe
penandpaper.exe is a lot less buggy, but only slightly less buggy than brain.exe

don't blame it on calc.exe. it returns 23 for me. It was operator error, he did it backwards. dec 27 = oct 33


To be completely honest, I did it in my head, and then used calc.exe to double check.

Re: Keep it Simple and Stupid

2008-11-17 11:15 • by Stefan W. (unregistered)
JSB is written 'Sebastian' with a single n, which is the real wtf here.

J-Dad Bach = Johann Ambrosius Bach,
J-Son Bach = Johann Sebastian Bach.

Re: Keep it Simple and Stupid

2008-11-17 11:22 • by Calculator (unregistered)
229472 in reply to 229470
Confirmation bias FTW (which is a WTF, but backwards)

Re: Keep it Simple and Stupid

2008-11-17 11:36 • by jimlangrunner
229476 in reply to 229463
Pendi:
Pablo:
Then it's no surprise that the correct result is 23:

Oct 27 = 2*8 + 7 = 23

At least gcalctool gets it right


That's why real programmers get confused by Halloween and X-Mas, cause OCT 31 = DEC 25

...


Shoot. Pity the poor bastage born on halloween, getting presents, and getting teased. Any wonder he doesn't do either anymore?

Re: Keep it Simple and Stupid

2008-11-17 11:40 • by Code Dependent
229477 in reply to 229453
JamesQMurphy:
Notice how the vendor is Johann Sebastian Bach. Now I know what inspired Toccata and Fugue in D minor.
I was inspired by "Air on a G String".

Re: Keep it Simple and Stupid

2008-11-17 11:42 • by ambrosen (unregistered)
229478 in reply to 229437
Santa:
TRWTF is "save-date-yyyy":"Oct 27"

What? "save-date" minus "yyyy"? Looks like a date minus a "yyyy" to me.

Re: Keep it Simple and Stupid

2008-11-17 12:44 • by cellocgw
229484 in reply to 229477
JSB? Move up to the greatest, although least known, member of the family, Philip David Quentin Bach.
(yeah, I know his parents only gave him initials, but he probably gave himself real names later on)

Re: Keep it Simple and Stupid

2008-11-17 13:01 • by Edward Royce (unregistered)
229485 in reply to 229432
Anonymous:
I was attracted to your site because I was looking for a good sample of XJSON. This definitively helps! Thanks.


Is that eXtreme-JSON?

And is it eXtreme enough?

Re: Keep it Simple and Stupid

2008-11-17 13:03 • by Alistair Wall
229487 in reply to 229453
JamesQMurphy:
Notice how the vendor is Johann Sebastian Bach. Now I know what inspired Toccata and Fugue in D minor.


It's a Diskworld allusion: JSB is BSJ backwards.

Re: Keep it Simple and Stupid

2008-11-17 13:05 • by Edward Royce (unregistered)
229488 in reply to 229459
John:
Some trolling that's so clever it's gone over my head?
How can a number represented in a higher base look bigger?

Ah, of course you're using calc.exe
penandpaper.exe is a lot less buggy, but only slightly less buggy than brain.exe


I try but I always get a bluescreen.

Sebastiann?!?

2008-11-17 13:06 • by Drizzt (unregistered)
I'd say TRWTF is the »Sebastiann«, as far as I know the guy was named Johann Sebastian Bach, but after the »creative« definition of the yyyy (which was already noticed), I'll guess that's just a »minor glitch«, which »will be addressed« in one of the upcoming bugfix releases.

Drizzt

Re: Keep it Simple and Stupid

2008-11-17 13:07 • by Edward Royce (unregistered)
229490 in reply to 229484
cellocgw:
JSB? Move up to the greatest, although least known, member of the family, Philip David Quentin Bach.
(yeah, I know his parents only gave him initials, but he probably gave himself real names later on)


Oh yeah? I'll see your Bach and raise you a Barbara Bach!

Re: Keep it Simple and Stupid

2008-11-17 13:10 • by NH (unregistered)
It's all too common to encapsulate one format into XML and then wonder why it not always works as expected.

I have a system where a fixed-record data is encapsulated in XML - and the fixed record contains spaces too, which means that there can be horrible problems if one isn't careful with formatting...

Re: Keep it Simple and Stupid

2008-11-17 13:13 • by ollo (unregistered)
Waiter! There's a JSON in my tagsoup!

Re: Keep it Simple and Stupid

2008-11-17 13:28 • by Duke of New York (unregistered)
Obviously the yank is right and the furener is wrong.

Re: Keep it Simple and Stupid

2008-11-17 13:31 • by Code Dependent
It's not even Friday the 13th, but JSON has gone to hell.

Re: Keep it Simple and Stupid

2008-11-17 13:48 • by drobnox (unregistered)
TRWTF is not enclosing the JSON in a CDATA seection.

Re: Keep it Simple and Stupid

2008-11-17 14:14 • by jeffg
229503 in reply to 229496
Code Dependent:
It's not even Friday the 13th, but JSON has gone to hell.


thedailywtf.com/lame
« PrevPage 1 | Page 2Next »

Add Comment