1

Closed

Problems with '.' in control name and id

description

we're using MVC preview 2 with the bindinghelper, which uses the syntax <objecttype>.<attributename> as the id and name for the UI controls.
this causes a problem because the javascripts created with validator toolkit look like
  v.settings.rules.<objecttype>.<attributename> 
  instead of v.settings.rules.controlname
which is obviously not valid.
I was forced to do a dirty hack, replacing '.' with '$' in key names in the ValidationSet.CreateClientScript for rules and messages, which furthermore forced me to update jQuery.Validation.js :-(
 
do you have any other idea?
 
thanks in advance,
stefan
Closed Sep 17, 2009 at 3:03 PM by jbaurle

comments

smadep wrote Apr 9, 2008 at 5:32 PM

well, the hack works ... but I have a bad feeling about this! ;-)

JokerLash wrote Apr 16, 2008 at 8:39 AM

I also walked into this problem, on CodeProject someone else posted a different solution to this problem.

http://www.codeproject.com/KB/aspnet/MvcValidatorToolkit.aspx?msg=2494716#xx2494716xx

wrote Sep 17, 2009 at 3:03 PM

wrote Feb 13, 2013 at 10:16 PM

wrote May 16, 2013 at 4:04 AM