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

Interact with the footer from a view?

2 Answers 54 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Bastien
Top achievements
Rank 1
Bastien asked on 09 Jan 2013, 03:30 PM
Hi,

I've the following footer declared in my index.html page:
<div id="footer" data-role="footer">
      <div data-role="tabstrip">
           <a href="#tabstrip-home" data-icon="home">Posts</a>
           <a href="Test.html" data-icon="action">Activities</a>
      </div>
<ul id="log">
                 
</ul>
</div>
When I stay on index.html there's no problem to change the content of ul#log, but when I'm on the Test.html page (my 2nd tab), when I try to add something with jquery by doing this:
$('#log').prepend('blablabla');
If I read the content of ul#log with jquery, I can see the new 'blablabla' text, but on the screen it's not displayed!?

Can anyone explain me why?

Thanks,
Bastien

2 Answers, 1 is accepted

Sort by
0
Bastien
Top achievements
Rank 1
answered on 10 Jan 2013, 04:11 PM
No one?
0
Accepted
Petyo
Telerik team
answered on 11 Jan 2013, 09:27 AM
Hello Bastien,

The behavior you observe is due to the layout implementation - certain elements are cloned and appended, in order for the transitions to work properly. 

You may obtain the correct reference (assuming that you are handling that in the view show event using the event parameter object):

function onViewShow(e) {
   e.view.element.find("#log");
}

Kind regards,
Petyo
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
General Discussions
Asked by
Bastien
Top achievements
Rank 1
Answers by
Bastien
Top achievements
Rank 1
Petyo
Telerik team
Share this question
or