neo4j-devtools / neo4j-desktop

The Neo4j Graph Platform, on your desktop OS.
19 stars 1 forks source link

Graph App can not redirect when access www.neo4j.com failed #79

Closed lixuanxian closed 4 years ago

lixuanxian commented 4 years ago

Steps

  1. Enable Development mode
  2. Add & Open "Neo4j Browser"
  3. Open "App developer tools"
  4. Use console. Try the code

Use window.localtion.href

window.location.href = 'https://gitgud.io/help?neo4jDesktopGraphAppRootPath=&neo4jDesktopGraphAppId=graphxr'

Use a tag

function openURL(url, target) {
    let a = document.createElement("a");
    a.setAttribute("href", url);

    a.setAttribute("target", target);

    a.setAttribute("id", "openURL");
    a.innerHTML = "openURL";
    a.click();
}

openURL('http://neo4jdesktopiconissues.code4demo.com?neo4jDesktopGraphAppRootPath=&neo4jDesktopGraphAppId=graphxr','_self')

Or

<a herf="http://neo4jdesktopiconissues.code4demo.com?neo4jDesktopGraphAppRootPath=&neo4jDesktopGraphAppId=graphxr" target="_self">Test Click redirect </a>

Our online app need redirect, but it is easy failed when access www.neo4j.com failed.