Results 1 to 3 of 3

Thread: Invalid content was found starting with element 'annotation-driven'

  1. #1
    Join Date
    Aug 2011
    Location
    UK, Leeds
    Posts
    26

    Question Invalid content was found starting with element 'annotation-driven'

    Hi All

    I'm very new to Spring MVC and trying to plumb it with Hibernate. I'm having bit of hard times at the moment, can someone please help me with this error. It appears in servlet-context.xml on <annotation-driven />;

    Code:
    cvc-complex-type.2.4.a: Invalid content was found starting with element 'annotation-driven'. One of '{"http://www.springframework.org/
     schema/beans":description, "http://www.springframework.org/schema/beans":import, "http://www.springframework.org/schema/beans":alias, 
     "http://www.springframework.org/schema/beans":bean, WC[##other:"http://www.springframework.org/schema/beans"]}' is expected.
    Many thanks

  2. #2
    Join Date
    Jul 2012
    Location
    Pittsburg,PA
    Posts
    2

    Default

    Please share the servlet-context.xml. Seems you are using a wrong namespace for <annotation-driven />.
    Regards
    AbhishekD

  3. #3
    Join Date
    Aug 2011
    Location
    UK, Leeds
    Posts
    26

    Default

    Thanks abhishek for your reply I've managed to get it sorted after pulling few of my hair out. I wasn't closing the tags properly e.g <beans:bean>...</beans:bean>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •