🔥 Help: Published doc button - open page in the same tab

Hey Folks, I need some urgent help. I have a published doc, where I am including a ‘Next’ button at the end of each page to create a sort of guided navigation.

The ‘Next’ button opens the right published page (I used open hyperlink and added links to the published doc) – but in a new tab each time, which is confusing.

Is there a way to make it open these in the same tab?

This occurs because the link that you put in the buttons are for the shared version of the doc (the navigation bar keeps in the left part of the screen) instead of the published one.

To accomplish what you are trying, I dont use buttons, but the page reference with @ command and display as a card. Now, when published, you can navigate over this “buttons” without opening a new tab.

pageRef

3 Likes

Aaaah, thank you, thank you!!! I was down to the wire and so grateful for your quick response!

2 Likes

I’m having the same issue with a custom button action. I’m trying to use RunActions(OpenWindow(url)) but it’s always opening in new tab.

I tryed

  1. url(thisDocument(object) + “/slug”) > works on original doc, not on published
  2. url(“/slug”) > didn’t work - goes to https://slug/
  3. url(“my-published-coda-link.com/slug”) > opens in new tab

Is there a way open to open in same tab? I just want users to follow the steps by clicking action buttons.

Hi @Gun_Karagoz – are the links to pages within the same doc, or to pages/links outside the doc?

If the links are the pages within the doc, then @Felipe_Arnhold1 's recommendation to use cards (/link → edit → display as card) solves the issue.

If the link is to a page outside of the doc, then I don’t know a solution to it…

No, this workaround doesn’t solve my issue since i would like to run multiple actions upon a click and navigate user to next page at the end. Pages are in the same doc, I’m just trying to achieve sth like below:

  1. get username in page 1
  2. when submitted (button clicked), add user to a table and time do couple of things and switch to page 2 automatically.
  3. same for page 2 and 3 and I want to put another option to send user back to page1 in the end.

@Gun_Karagoz

  • create object like a line, a controller or a button
  • take the url of that object
  • use a button with openWindow(“link to the object”)
    cheers, christiaan

@Christiaan_Huizer as I said in previous reply, it works on original doc, not on published doc. It opens original doc page in new window from published page.

Hi @Gun_Karagoz , I am out of my depth here…I tried using the hyperlink formula to reveal the published page link with an if statement, but it still seems to open it in a new window.

Might be a question for support?
-A

I found the solution :slight_smile:

OpenWindow(“/_suSOMEID” ) works on both pages (original and published doc.)

I just copied linked to next page and used the last portion in the link starting with _su and didn’t use url function then it worked!

4 Likes

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.