Domo.Navigate

Hi, this is related to this other post

https://dojo.domo.com/t5/Domo-Developer/Domo-Javascript-Navigation/m-p/43888#M1305

 

This is the structure of my app:

tree.JPG

 

My index.html is my main page, it has a button that when clicked I want it to navigate to second.html

 

Code for my button is:

 

<input type="button" value="Search" id="Search" class="d-inline p-2 btn btn-info" onclick="Segunda()">

Code in the Segunda function is:

 

 

function Segunda(){
domo.navigate('/page/1626710393/second');
}

I've tried with 

domo.navigate('/page/1626710393/second.html');
domo.navigate(second');
domo.navigate('/second');
domo.navigate('second.html');
domo.navigate('/second.html');
 
and none of the mentioned above work.
 
Any ideas on how to solve this? I don't want to have to publish second.html in a separate project, because that will make me loose communication with my dataset created by the App DB engine.
 
Thanks in advance.
 

 

Tagged:

Comments

  • Jarvis
    Jarvis Domo Employee

    Hello!

     

    The domo.naviate function is to navigate to other pages within Domo, and authorized domains (see https://developer.domo.com/docs/dev-studio-references/domo-js#domo.navigate for supported domains). Depending on what you are trying to do with this other HTML document, you could use conditional rendering in CSS to show and hide different HTML elements based on user interaction with your app. 

     

    Hope that helps point you in the right direction! 

This discussion has been closed.