Perhaps you could use the Approved Color data type where you can define some colors, and then your content users can choose between the colors that you have set up on the Approved Color data type.
When you need to get data out in Razor you can use @CurrentPage.PropertyAlias of the color picker for the dynamic version and for the strongly typed Razor example, I think it should look something like this @Model.Content.GetPropertyValue<string>("PropertyAlias")
The color picker you have referenced is that something you have found in an external jquery library or where is it from? It should be possible to make a custom property editor, which makes it possible to pick the color - But perhaps you can just use the already created spectrum color picker? https://our.umbraco.org/projects/backoffice-extensions/spectrum-colour-picker
How to set color picker in umbraco 7.2.4
Hi,
I am using umbraoc 7.2.4
i want to use below like color picker
can any one used same then please share your thoughts.
Regards,
Mehul Gajjar.
Hi Mehul,
Perhaps you could use the Approved Color data type where you can define some colors, and then your content users can choose between the colors that you have set up on the Approved Color data type.
Try to see this documentation. https://our.umbraco.org/documentation/using-umbraco/backoffice-overview/property-editors/Built-in-Property-Editors/Color-Picker this documentation uses the Umbraco 4/6 UI but the setup should be the same in Umbraco 7.
When you need to get data out in Razor you can use @CurrentPage.PropertyAlias of the color picker for the dynamic version and for the strongly typed Razor example, I think it should look something like this @Model.Content.GetPropertyValue<string>("PropertyAlias")
Hope this can be a solution for you.
/Dennis
Hi Mehul
The color picker you have referenced is that something you have found in an external jquery library or where is it from? It should be possible to make a custom property editor, which makes it possible to pick the color - But perhaps you can just use the already created spectrum color picker? https://our.umbraco.org/projects/backoffice-extensions/spectrum-colour-picker
/Jan
Hi Jan,
I have install this package and its working fine.
https://our.umbraco.org/projects/backoffice-extensions/spectrum-colour-picker
it is very clean and easy to get color code.
Thanks
Mehul Gajjar.
is working on a reply...