# Accessing session values in rails methods

**URL:** <https://www.ruby-forum.com/t/accessing-session-values-in-rails-methods/143970>\
**Category:** Rails\
**Created:** [July 24, 2008, 8:53am UTC](https://www.ruby-forum.com/t/accessing-session-values-in-rails-methods/143970 "2008-07-24T08:53:51Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![manohar\_amrutkar](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/ecd19e/32.png) [@manohar\_amrutkar](https://www.ruby-forum.com/u/manohar_amrutkar)\
**Post date:** [July 24, 2008, 8:53am UTC](https://www.ruby-forum.com/t/accessing-session-values-in-rails-methods/143970/1 "2008-07-24T08:53:51Z")

</div>

Hello All,

This is something new for me. Please help me to resolve the following  
problem.

I am using Flex in my application of course Flex in rails.

I am using Flex in UI for widgets, where it calls a rails method which  
gives a .rxml file from where it gets the data to put it into the  
widget.

I have used few sessions in my application. When i have a request from  
browser to one of my page i have created few sessions into that method  
and then am displaying my view where i have used that widget which is  
created in Flex. Now, this widget displays some data and to get this  
data it calls a rails method in back-end.

Here, the problem comes, the sessions which i have created in my  
rails method the one which is the current request, am trying to use  
them into this method the one which is called from Flex in back-end.  
These session values are available on local server but not on staging  
server.

And when i was uploading files using these Flex front-end these  
sessions were not available on local server and not on staging in the  
methods which are called in back-end from Flex.

Does anybody have idea about accessing sessions in rails methods, the  
methods which are called in back-end from Flex.

Thanks,  
Manohar
