I need to see if this is possible. We have a site with a certain document type which needs an extra button along with save. The client wants to save a page and then, separately, export it as XML.
I cannot offer any code that has been tried or anything as at this stage I am just trying to se if it is even possible and how would you go about it?
I have a plugin called MemberLogin which does this kind of task.
It creates a custom action, renders a html page with some content and a button which executes some code.
Another "easy" option would be to create a custom property editor that has the export button + functionality. That way you can place it on eg. an "Export" tab and wrap the UI anyway you like :)
I am marking Rune's answer as the solution only because it was easier for me to implement in a very quick test (only doing a spec for a job at this stage, so just needed to make sure it was possible). In the end, we might do it as an Action but for now Thanks to all who offered ideas.
Add button to admin document types
Hi there
I need to see if this is possible. We have a site with a certain document type which needs an extra button along with save. The client wants to save a page and then, separately, export it as XML.
I cannot offer any code that has been tried or anything as at this stage I am just trying to se if it is even possible and how would you go about it?
Thanks for any pointers
it is possible to add a custom action to the context menu : https://our.umbraco.org/forum/extending-umbraco-and-using-the-api/78088-add-custom-action-in-content-edit-page
It seems a bit harder to inject a button. Haven't seen a (nice) example of that being done.
Hi,
I have a plugin called
MemberLogin
which does this kind of task. It creates a custom action, renders a html page with some content and a button which executes some code.You can find the source code on github: https://github.com/Mivaweb/MemberLogin/tree/master/src/MemberLogin
In the root folder you will find a file called
Bootstrapper.cs
which adds the custom action.Hope this helps.
/Michaël
Ooh that seems like an option. I had never even considered the Actions but I don't really see why it couldnt work.
I just want to avoid having them have to go to a custom area and doing it there, it really would be best to have out all on the one screen.
I'm away without laptop at the moment but when I'm back in the office I'll check it out. Thanks!!
Another "easy" option would be to create a custom property editor that has the export button + functionality. That way you can place it on eg. an "Export" tab and wrap the UI anyway you like :)
Hey mister hacker,
That would give a "button"-property on the pages. Is there anyway to avoid that?
Can you specify steps?
Thanks to both of you. I will have to look at both options.
I am marking Rune's answer as the solution only because it was easier for me to implement in a very quick test (only doing a spec for a job at this stage, so just needed to make sure it was possible). In the end, we might do it as an Action but for now Thanks to all who offered ideas.
Hi Hawthorn,
thanks for sharing it on the community!
Have a nice day.
/Michaël
is working on a reply...