hi,
i have a form with 3 radio buttons and one submit button.on clicking submit i want to navigate to page corresponding to the radio button selected.How can i achieve this?..

Recommended Answers

All 3 Replies

Hi
use document.location.href property to achieve this.
suppose u want to navigate to page example.html then u can do like this
document.location.href="example.html";

hey thx..i figured it out..usin window.location="url"..it wrks the same way u say..

Though it works, it's an incorrect way of doing things. location property of the window object is an object, not a string. The location object in turn has an href property of type string and hence location.href = "url"; is the correct, location = "url"; is not.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.