XVal validation with Spring.net

I started playing with xVal as a validation framework for an ASP.Net MVC application. I am using Spring.Net IoC container to store my application.

I followed the instructions on Steve Sanderson's blog to check if it worked correctly on the server side. But when I try to work client side I get the following Execution Exception:

Spring.Objects.Factory.NoSuchObjectDefinitionException was unhandled by user code

      

Message = "Object named" Scripts "is not defined: Could not find definition for object [Scripts]"

I assume this is because there is the following code in Site.Masterpage:

<script type="text/javascript" src="<%= ResolveUrl("~/Scripts/jquery-1.2.6.js")%>"></script>
<script type="text/javascript" src="<%= ResolveUrl("~/Scripts/jquery.validate.js")%>"></script>
<script type="text/javascript" src="<%= ResolveUrl("~/Scripts/xVal.jquery.validate.js")%>"></script>

      

Which is what ~ / Scripts / using Spring is trying to resolve.

How do I get either Spring to handle this (that is, what goes into the config XML), or what can I change in Site.Master to prevent this from happening?

+1


a source to share


1 answer


Opps, helped with Steve, I found the answer. Not blindly copy and paste samples from the web, I have jquery-1.3.2.js in my scripts folder, not 1.2.6. By changing the link in the Site.Master file to the correct version number, it all started working.



0


a source







All Articles