I am quite surprised I have to make this question because I expected other people would have encountered the same as me. Maybe I didn’t put in the right keywords in the search engine, or maybe I have no idea what I am doing. 😛
Anyways,
I have a Spring view resolver bean which appends ‘.jsp’ to a String returned from a method which gets a request. What I would like to do is add an anchor to the String so I can scroll to a certain element in the page, if I do it now I get page not found error.. can anyone give me some advice how to do this?
Thanks in advance!
Davey
What I have done is, put my (needed) modelAttributes in the sessionAttribute (Thanks @Boris Treukhov) and sent a redirect to another controller with an anchor (e.g. site/edit#123). In this method I get the data out the Session and put it in the model, then Returning the page.
Thanks everyone for the help!