html - Display new page in jquery mobile through button click -


I am using jQuery mobile and when I click on the button try to display the second page / div I am doing How do you use the button properly? Do I need to link to a JavaScript function somehow?

  & lt; Body & gt; & Lt; Div data-role = "page" id = "pageon" & gt; & Lt; Div data-role = "main" square = "ui-content" & gt; & Lt; Form & gt; & Lt ;! - Some text boxes - & gt; & Lt; Button onclick = "store ()" a href = "# pagetwo" type = "button" id = "savebtn" & gt; Store the data and give it & lt; / Button & gt; & Lt; / Form & gt; & Lt; / Div & gt; & Lt; / Div & gt; & Lt; Div data-role = "page" id = "pagetwo" & gt; & Lt; Div data-role = "main" square = "ui-content" & gt; & Lt ;! - Performance graphs with textbox data - & gt; & Lt; / Div & gt; & Lt; / Div & gt; & Lt; / Body & gt;  

  1. First, store data function store () {$. Ajax ("Url:" data collection ", success: function () {$ (" body "). Page Container (" Change ", $ (" # pagetwo "), {Infection:" Slide "}}}}} }}
  2. Take the page to your other page on success in the example code above
  3. On your second page you will need to get the data you saved
  4. < / Ol>

Comments

Popular posts from this blog

java - org.apache.http.ProtocolException: Target host is not specified -

java - Gradle dependencies: compile project by relative path -

ruby on rails - Object doesn't support #inspect when used with .include -