Hi Himai,
UName is session scope. You are confusing
pageContext and
PAGE_CONTEXT. If I do this:
This means your attribute will be available in page scope. But if you do this:
Now you are setting the attribute in session scope i.e. it's the same as doing this:
The
pageContext is an object of type
PageContext and you can check the documentation of
setAttribute method...