W3C home > Mailing lists > Public > public-webapi@w3.org > May 2006

Re: XHR constructor example

From: Anne van Kesteren <annevk@opera.com>
Date: Sun, 14 May 2006 13:06:11 +0200
To: "Daniel Schierbeck" <daniel.schierbeck@gmail.com>
Cc: "Web APIs WG (public)" <public-webapi@w3.org>
Message-ID: <op.s9jfslem64w2qv@id-c0020.oslo.opera.com>

On Sat, 15 Apr 2006 19:41:41 +0200, Daniel Schierbeck  
<daniel.schierbeck@gmail.com> wrote:
> The current example[1] of an XMLHttpRequest constructor,
>   var r = new XMLHttpRequest();
> is fine and all, but the variable name `r' strikes me as a bit odd.
> I know it's not the job of the W3C to teach best programming practices,
> but at least using somewhat descriptive variable names in examples would
> not be out of order. This is better:
>   var request = new XMLHttpRequest();
>
> [1] http://www.w3.org/TR/2006/WD-XMLHttpRequest-20060405/#xmlhttprequest

Given that it doesn't have to be a request I think 'r' is saver or perhaps  
just 'x'...

Cheers,

Anne


-- 
Anne van Kesteren
<http://annevankesteren.nl/>
<http://www.opera.com/>
Received on Sunday, 14 May 2006 11:06:41 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 8 January 2008 14:18:55 GMT