473,398 Members | 2,427 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,398 software developers and data experts.

Question this

What does this mean:

element.multi_selector = this;

I is used in this javascript class:
http://the-stickman.com/web-developm...-file-element/

I understand that this line is adding a reference to the object but can
someone explain me why this is important and what is it used for?

Marcel
Apr 23 '07 #1
2 1125
Marcel Molenaar wrote:
What does this mean:

element.multi_selector = this;

I is used in this javascript class:
http://the-stickman.com/web-developm...-file-element/

I understand that this line is adding a reference to the object but can
someone explain me why this is important and what is it used for?

Marcel

Alright I am going to venture out on a limb on this one, but I think it
has something to do with closures.

Or just in general having a spare to insert when 'this' is no longer in
scope with the object you may be wanting.

Then again my understanding of closures is about 20%.

--
-Lost
Remove the extra words to reply by e-mail. Don't e-mail me. I am
kidding. No I am not.
Apr 23 '07 #2

"-Lost" <ma****************@techie.comwrote in message
news:Hv******************************@comcast.com. ..
Marcel Molenaar wrote:
>What does this mean:

element.multi_selector = this;

I is used in this javascript class:
http://the-stickman.com/web-developm...-file-element/

I understand that this line is adding a reference to the object but can
someone explain me why this is important and what is it used for?

Marcel

Alright I am going to venture out on a limb on this one, but I think it
has something to do with closures.

Or just in general having a spare to insert when 'this' is no longer in
scope with the object you may be wanting.

Then again my understanding of closures is about 20%.

--
Ok thanks, i understand your explanation but can you give me an example or
further explanation?

The file in which this is used can be downloaded from
http://the-stickman.com/files/multiple-file-element.zip and it is used in
the file multifile.js at line 68

Marcel
Apr 24 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Mohammed Mazid | last post by:
Can anyone please help me on how to move to the next and previous question? Here is a snippet of my code: Private Sub cmdNext_Click() End Sub Private Sub cmdPrevious_Click() showrecord
4
by: Mohammed Mazid | last post by:
Can anyone please help me on how to move to the next and previous question? Here is a snippet of my code: Private Sub cmdNext_Click() End Sub Private Sub cmdPrevious_Click() showrecord
3
by: Stevey | last post by:
I have the following XML file... <?xml version="1.0"?> <animals> <animal> <name>Tiger</name> <questions> <question index="0">true</question> <question index="1">true</question> </questions>
11
by: billnospam | last post by:
Is it possible to overload operators in vb.net? Is it possible to do programmer defined boxing on byvalue variables in vb.net?
2
by: amelia170 | last post by:
I am creating a database with a yes or no answer for question 1. Based on that answer, (if they answer yes) they will answer question 2, then three....However, if they answer no to question one, I...
3
by: Ekqvist Marko | last post by:
Hi, I have one Access database table including questions and answers. Now I need to give answer id automatically to questionID column. But I don't know how it is best (fastest) to do? table...
1
by: chiefs | last post by:
I'm tyring to get the output of the Question # with last question at the end. Here is the code: Instead of printing the # after the Question, it prints the ASCII Characters. /* print question#...
15
by: Gary Peek | last post by:
Can anyone tell us the browsers/versions that exhibit errors when tables are nested too deeply? And how many levels of nesting produces errors? (not a tables vs CSS question)
37
by: Prafulla T | last post by:
Assume that an integer pointer x is declared in a "C" program as int *x; Further assume that the location of the pointer is 1000 and it points to an address 2000 where value 500 is stored in 4...
0
by: knorth | last post by:
If you submit the best question for the workshop at LinkedData Planet, you'll win admission to the conference, including keynotes by W3C Director Sir Tim Berners-Lee and IBM CTO for Information...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.