MVC newbee here. I have a MVC3 project with a main View (Index.cshtml). From this view you can go to the CreateRemark.cshtml view. You can create and save a remark on this view. In the POST action I have logic to persist the data to the database and then I want to render the Index view again.
I do this at the end of my action CreateRemark by writing:
Return View("Index");
I expected that my URL would look like localhost/ or localhost/Index. But it keeps saying localhost/CreateRemark?id=123, while it does actually render the html which is on the Index view. It renders it wrong though (I haven't investigated fully but it's missing all the images in the buttons and the hierarchical grid misses the 2nd level) and I think I can solve this by making sure I direct the enduser to the Index View in the correct MVC manner. I think I'm doing it wrong.
The GET/POST actions Index and CreateRemark are both in the same Home controller by the way. I think I want a RemarkController later, but haven't done that yet. Sorry.
Can someone point me in the right direction please? Thanks in advance for your help.