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

Templates are not for forms, correct?

3 Answers 103 Views
Templates
This is a migrated thread and some comments may be shown as answers.
King Wilder
Top achievements
Rank 2
King Wilder asked on 07 Mar 2012, 01:35 AM
I've done some preliminary tests and it seems that Kendo templates shouldn't be used for form elements.  While the templates create the forms fine, it's not possible to reference input elements from jQuery, since it's just created in memory.

In other words, click events from buttons don't work.

I just want some confirmation about this.  If I'm wrong, please clarify.

Thanks,

King Wilder

3 Answers, 1 is accepted

Sort by
0
King Wilder
Top achievements
Rank 2
answered on 07 Mar 2012, 03:48 AM
Nevermind.  I figured it out.

I just changed my jQuery click handler from this:

$(":button").click(function () {
   // some code
});

... to this...

$(":button").live("click", function () {
   // some code
});

The "live" event handler did the trick.
0
Mangesh
Top achievements
Rank 1
answered on 31 Mar 2012, 11:42 PM
Hi,

Even I'm facing the same problem. I'm able to display form correctly, but not able to access the form i.e. I have added input type text by using kendo template but when I run the app, I'm not able to write anything on input box. ? Is this the limitation of using Kendo Template ?

Thanks,
Mangesh
0
Bruce
Top achievements
Rank 1
answered on 03 Apr 2012, 09:44 PM
Surprised that no one has helped on this. Would like to see a solution.
Tags
Templates
Asked by
King Wilder
Top achievements
Rank 2
Answers by
King Wilder
Top achievements
Rank 2
Mangesh
Top achievements
Rank 1
Bruce
Top achievements
Rank 1
Share this question
or