Skip Navigation

[Resolved] button "submit" in creed forms open post in target="_blank"

This support ticket is created 4 years ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 - -
13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 - -

Supporter timezone: America/New_York (GMT-04:00)

This topic contains 5 replies, has 2 voices.

Last updated by Christian Cox 4 years ago.

Assisted by: Christian Cox.

Author
Posts
#1888969

I have a form cred showing the post (via content template).

Is it possible to make the submit button open the published post in a new window?

#1889105

Hello, there's nothing built-in to Forms that will open a new browser tab or window when submitting the Form. In some browsers, you can hold down Control (or Command, on a Mac) when pressing the submit button to submit the Form in a new tab, but that's browser-specific. You would have to configure the Form to display the post after submission.

#1889485
stamp2.jpg

But I have configured the form to show the post.
However, the post opens in the usual form tab while I would like it to open in a new tab

#1889747

Right, as I said this is not a built-in feature of Forms. In some browsers you can hold down Control (or Command on a Mac) to force the Form to submit in a new page, but this is browser- and OS-specific. There is no option in Forms to open in a new tab or browser window.

#1889795

and it is not possible even through Js, filter and the like?

#1889927

There is no public JavaScript API for Toolset Forms, so there is limited support for manipulating a form with JavaScript. The Forms PHP API can help you change the redirection URL after Form submission, but it is not intended to help open a new window when the Form is submitted. That would require changing the target attribute of the form tag produced by Forms. You might be able to add a target attribute to the form tag produced by Forms using JavaScript, but that is not supported here in the support forums because as I said there is no public JavaScript API for Forms. You could try something like this: https://www.w3schools.com/jsref/prop_form_target.asp, but I can't guarantee it will work exactly like you want. Without a public JavaScript API for Forms, support is limited here and this is considered an undocumented, unofficial workaround with no guarantees.