Localized label for textbox title in a form

Posted by Community Admin on 04-Aug-2018 07:33

Localized label for textbox title in a form

All Replies

Posted by Community Admin on 15-Jun-2016 00:00

Hello,

Is it possible to create localized label in multiple langages and use it as title for a textbox field in  a form ?

Thanks for your help

Posted by Community Admin on 15-Jun-2016 00:00

If i correct understood you question, sitefinity supports it out of the box.

You can create form, translate it to another language and rename labels. 

I attached example with  EN ans ES form translation

Posted by Community Admin on 15-Jun-2016 00:00

Thank you for your answer. Yes it is a solution but is there another way to do that with resource file ? Without creating mulitple forms in each langages ?

Posted by Community Admin on 15-Jun-2016 00:00

Hi, 
Out of the box this is not possible.

You could however create a custom form field where you have total control over and implement something like for example:;

...
    public class CustomField : FieldControl, IFormFieldControl
    
        #region Constructor
        /// <summary>
        /// Initializes a new instance of the CustomField class.
        /// </summary>
        public CustomField()
        
            var resources = ResourceManager.GetManager();
            this.Title = resources.GetResourceOrEmpty(Thread.CurrentThread.CurrentCulture, "FormResources", "myCustomFormField").Value;
        
...
            

Screenshot: http://screencast.com/t/jMBdOMQK07x


Some additional information links;
www.sitefinity.com/.../creating-custom-form-field-controls-with-sitefinity-thunder

https://github.com/Sitefinity/feather/wiki/How-to-create-custom-forms-field



Regards,
Dimitri Cools
Telerik
 
Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Sitefinity CMS Ideas&Feedback Portal and vote to affect the priority of the items
 

This thread is closed