Win a copy of Practical SVG this week in the HTML/CSS/JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

HFSJ : Confusing "if you took this expression out of the tag, it would return null"

 
Seetharaman Iyer
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

I don't understand this statement from HFSJ Page 519,
"if you took this expression out of the tag, it would return null"


Tag Handler is setting the attribute "message" at page scope, so it's straight forward that once this tag is invoked, it'll be available in page scope, so even outside of the tag also, it must be visible. If this's the case, how would it return null while accessing from outside the tag.

In the below snippet, both of expression are producing the (same) result.


I don't know what I'm missing. Please show me some light on this?

Thanks in advance,
Seetha...
 
I have always wanted to have a neighbor just like you - Fred Rogers. Tiny ad:
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!