Start New Discussion Reply to this Discussion Getting the Redirecton correct in HTML5
i have a webpage in html5 with various divs made into pages with data-role="page" and each page having id="second" "third etc...
Now i want to use the inbuilt validations..but for that i have to use the form tag...which redirects my pages to the html5 homepage..which is undesirable...can anyone help.
<div data-role="page" id="third" data-theme="b" >
<a href="#first" data-role="button" data-transition="fade" data-inline="true">Go home</a>
<form id="test" name="myForm" method="POST">
<div data-role="header" data-theme="b"> <h1>What Is Your Name ?</h1>
</div>
<div data-role="content" data-theme="b">
<div data-roie="fieldcontain" data-theme="b">
<input type="text" name="name" id="name" value="" required />
</div>
<button onClick="submit_form(this.form)">submit</button>
</div>
</form>
<div data-role="footer" data-theme="b"> <h1>This is a Copyrighted Product</h1>
</div>
</div>
submit_form fn is a javascript function to check for validation and redirect to mobile page
10 Months Ago
Last Updated
Related Article: Correct HTML5 Format
is a Web Design, HTML and CSS discussion thread by ello that has 4 replies and was last updated 5 months ago.
thak123
Newbie Poster
10 posts since Jul 2012
Reputation Points: 0
Solved Threads: 0
Skill Endorsements: 0
ShadyTyrant
Junior Poster
133 posts since Nov 2009
Reputation Points: 12
Solved Threads: 20
Skill Endorsements: 0
I used action="mypage.html#fourth"but i get only the url changed but the display in the browser still remains of the home page
pageToPostBackTo.html
thak123
Newbie Poster
10 posts since Jul 2012
Reputation Points: 0
Solved Threads: 0
Skill Endorsements: 0
Only two things I can think of is try removing the hash id. Or more likely instead of using the <button> tag, try using <input type="submit"> instead
ShadyTyrant
Junior Poster
133 posts since Nov 2009
Reputation Points: 12
Solved Threads: 20
Skill Endorsements: 0
© 2013 DaniWeb® LLC
Page rendered in 0.0687 seconds
using 2.68MB