flash[:notice] not working

Hi,     anybody please help me out,am using rails 3 but using this flash[:notice] doesnot works, i have used this in controllers. any idea ? please help.

Regards, Manoj

Have a look at the Rails Guide on debugging, it will show you techniques you can use to debug your code to find why it is not working.


Paste your code…

Loganathan S. wrote in post #1075308:

Paste your code...

Sent from Samsung Mobile.

Hi, here is my code below, @user is saved successfully but not flash doesnot works. I have wrote this in userscontroller

    if @user.save       flash[:notice] = "Your account has been created."       redirect_to signup_url     else       flash[:notice] = "There was a problem creating you."       render :action => :new     end

redirect_to signup_url, flash: {   notice: "Your account has been saved" }

there shouldn’t be any issue with your code. how do you display the flash messages?