I’m struggling with Flash Data in CodeIgniter.
I basically want to:
add a category to a database
redirect user back to a page
show a success pop-up message “Your category has been created”
So far I can add the category successfully to the db and the user input is validated correctly, only thing is I don’t know how to create the pop up success message. (I don’t want to load a success view), just redirect back to where they came from and show small message in the top corner or something.
Is flash data the right way to go?
In your controller:
In the view: