Ok, so I've got the link working correctly now, I was missing something on my constructor for Html.ActionLink. I've now changed it to the following and it works:
but now the form doesn't post. It doesn't hit the HandleEditMember action in my controller when I post the form, it just hits the RenderEditMember action again.
Thanks for the reply Ismail. My code is pretty much the same, I've even removed all validation on the viewmodel and removed the client validation to make it really simple.
Any post always seems to hit the RenderEditMember method rather than the HandleEditMember
Custom controller with Html.ActionLink issues
Hi All,
I'm having some troubles with a custom controller. When I use Html.ActionLink the URL rendered out are and something looks wrong to me:
and
My source to render links the links in my View are:
Eventually, they should open up forms in a lightbox/popup.
Here is my surface controller:
and here is my partial for _EditUser:
Clicking on the Edit User link brings up the following error:
There is not current PublishedContentRequest, it must be initialized before the RenderRouteHandler executes
I've tried, browsing to ../umbraco/Surface/UserManagerSurface/RenderEditMember?MemberID=1093 and the forms appears as I'd normally expect.
Can somebody please tell me where I'm going wrong?
Thanks
Also, going to ../umbraco/Surface/UserManagerSurface/RenderEditMember?MemberID=1093, the form post doesn't work. It doesn't hit the controller
Ok, so I've got the link working correctly now, I was missing something on my constructor for Html.ActionLink. I've now changed it to the following and it works:
This now takes me to http://localhost:49806/umbraco/Surface/UserManagerSurface/RenderEditMember?MemberID=1093 and displays the form correctly
but now the form doesn't post. It doesn't hit the HandleEditMember action in my controller when I post the form, it just hits the RenderEditMember action again.
Hi,
Mine is not working
Ben,
I have an umbraco 6 site and for a contact form i have
then further down
and then the fields then a submit button
works for me
Thanks for the reply Ismail. My code is pretty much the same, I've even removed all validation on the viewmodel and removed the client validation to make it really simple.
Any post always seems to hit the RenderEditMember method rather than the HandleEditMember
Code here if anybody can help: https://gist.github.com/anonymous/c4a2431281e50e221c9e
is working on a reply...