Access and get not published content with Umbraco content API.
Hi all,
First off all I need to say that I am new to umbraco, recently started to exploring it's posibilities.
So far I enjoy using it, easy to instal, develop and there are a loot of questions answered on comunitiy.
Great job umbraco!
I am wondering if there is a way for me to create some custom data repository or something like that?
My demand is to be able to save user's input (this could be some form submit from front office by web site visitors).
I need to save this submited form into umbraco, but I don't want this to be published and visible on front office side.
I know that I am able to save this in content section with content API, but I do not want this data to be published and visible outside backoffice.
So far I tried to just save this users input to centent but not to publish it, in this case I have problem because if content is not publised I cannot access it from content API,
or maybe there is a way to access not published content with content API?
If someone have some idea how this could be implemented please let me know.
Access and get not published content with Umbraco content API.
Hi all,
First off all I need to say that I am new to umbraco, recently started to exploring it's posibilities. So far I enjoy using it, easy to instal, develop and there are a loot of questions answered on comunitiy. Great job umbraco!
I am wondering if there is a way for me to create some custom data repository or something like that? My demand is to be able to save user's input (this could be some form submit from front office by web site visitors). I need to save this submited form into umbraco, but I don't want this to be published and visible on front office side.
I know that I am able to save this in content section with content API, but I do not want this data to be published and visible outside backoffice. So far I tried to just save this users input to centent but not to publish it, in this case I have problem because if content is not publised I cannot access it from content API, or maybe there is a way to access not published content with content API?
If someone have some idea how this could be implemented please let me know.
Thanks in advace.
Hi Marko,
1) The easiest way to save user's input from forms is to use Umbraco Forms
http://umbraco.com/products-and-support/forms/
All data will be stored at Forms section in Umbraco admin, and it's easy to maintain.
2) Of course, you can unpublished data from API. ContentService returns upublished and published nodes.
https://our.umbraco.org/documentation/reference/management/services/contentservice
Thanks,
Alex
For option 2, code sample to show how we can access nodes that are not published and those that are published.
is working on a reply...