I have a VF page running in SF1. I need to redirect to another page by using javascript. I am using below code
<p><a href="javascript:var x = 'https://cs5.salesforce.com/a06O000000JWnJhIAL'; sforce.one.navigateToURL(x);">Click to open page two.</a></p>
This code is not redirectiong me to the second page but if I remove variabale x and hard code the redirection url it is working Below is the working
<p><a href="javascript: sforce.one.navigateToURL('https://cs5.salesforce.com/a06O000000JWnJhIAL');">Click to open page two.</a></p>
Now the imapct is I cannot make the url dynamic any way to achecive dynamic redirection?