This is a migrated thread and some comments may be shown as answers.

Spell Check an HTML SELECT

2 Answers 25 Views
Spell
This is a migrated thread and some comments may be shown as answers.
Tom Opgenorth
Top achievements
Rank 1
Tom Opgenorth asked on 25 May 2010, 05:24 PM
Hello, I'm wondering if it's possible for RadSpell to check and correct the spelling inside an HTML SELECT element?  For example, say I have this HTML snippet:
<select title="Select the correct answer in the pull-down." style="max-width: 650px;" class="pulldown_choice_options" id="sel_choice_0" tabindex="0">
<option value="forezt">forezt</option><option value="G">G</option><option value="d">d</option><option value="e">e</option><option value="f">f</option></select>

Notice the incorrectly spelled word "forezt". 

Now to add a twist to this, say I have several SELECT elements, all with the same options. Would it be possible to get RAD spell check treat all the SELECT's as one?  i.e.  look only at the first SELECT element and it's OPTIONs, but then correct the spelling in all the other SELECT elements with the class id of pulldown_choice_options.

We're using jQuery, ASP.NET MVC

Hope this makes sense.

TIA

2 Answers, 1 is accepted

Sort by
0
Rumen
Telerik team
answered on 26 May 2010, 03:16 PM
Hi Tom Opgenorth,

You can spellcheck the items of the select element but you cannot update the values of the inner option tags, because the spellchecker is designed to correct the text of form input / textbox / textarea elements only.

What you can do is to implement your own custom text source that will help you to spellcheck the select options and after getting the returned by the spellchecker suggestion using the get_text method to programmatically update the item values of the select elements. See these articles for more information:

http://www.telerik.com/help/aspnet-ajax/spell_checkingcustomsource.html
and
http://www.telerik.com/help/aspnet-ajax/spell_howtomutlipletextareas.html

Greetings,
Rumen
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
0
Tom Opgenorth
Top achievements
Rank 1
answered on 26 May 2010, 03:20 PM
Thanks a bunch for the answer, and for the tip. I already have a rudimentary "custom text source" because although I have multiple selects they all display the same data, so sounds like that is the way to go for me.
Tags
Spell
Asked by
Tom Opgenorth
Top achievements
Rank 1
Answers by
Rumen
Telerik team
Tom Opgenorth
Top achievements
Rank 1
Share this question
or