List Methods

Description

The listview refresh method updates the list.

refresh method updates the list to reflect the changes we made.

Example

For instance, if we add a new item to an existing list, we must call "refresh" to rebuild the list items:


// Add an  item to an  existing list and  refresh the list item
$("#list1")
.append('<li><a href="#">Drama</a></li>')
.listview("refresh");

// Add list items to a  new list and  refresh the entire  list 
var markup  = '<li>item  1</li><li>item 2</li>';
$("#list2")
.append(markup)
.listview( "refresh",  true );




















Home »
  jQuery Mobile »
    Tutorial »




jQuery_Mobile
Form
List
Layout
Theme