Question

I am sure that this is extremely easy and probably a one liner but I can't seem to find the answer anywhere.

I am creating a very simple web app in Dashcode (my first time) that has a button, when you press it, it needs to link to a url.

Cannot seem to find anything.

Thank you very much for your time.

Was it helpful?

Solution 4

This ended up being what I needed:

document.location = ("http://www.google.com");

OTHER TIPS

I relied on Apple Developer for this:

function yourHandler(event) {
     widget.openURL("http://store.apple.com/");
}

enter image description here

Try this... First add button event onclick (openURL) Then code follows...

function openURL()
{
  if ( window.widget )
  {
    widget.openURL( “http://www.google.com” );
    return false;
  }
}

Or Try...

{
 widget.openURL('http://www.google.com');
}

Try this too

function myButtonPressHandler(event)
{
  var websiteURL = "http://www.google.com";
  location = websiteURL;
}
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top