Forum Discussion
JonathanGibson
Qrew Trainee
This reply was created from a merged topic originally titled Calling Multiple URLS with a Javascript Formula Button - used to work, now broken....
For the better part of the last year we've been using a formula button with javascript to call two URLs at once, then reload the page.
One URL sends a text message (via webhook to an external system), while the other edits a record in our database to log the action (the variables $sendText and $logText below, respectively).
I have tested the two individual URLs by putting them into their own buttons, and they continue to work fine, which leads me to think there is something wrong with our Javascript. I suspect it may be relying on assumptions about Quickbase or the page structure which are no longer true with the latest update. Any ideas?
Thanks in advance!
Jonathan
For the better part of the last year we've been using a formula button with javascript to call two URLs at once, then reload the page.
One URL sends a text message (via webhook to an external system), while the other edits a record in our database to log the action (the variables $sendText and $logText below, respectively).
"javascript:" &Up until about a week ago this technique worked with virtually no issues but now it just opens a blank page and does nothing else.
"$.get('" & $logText & "');" &
"$.get('" & $sendText & "',function(){" & "location.reload(true);" & "});" &
"void(0);"
I have tested the two individual URLs by putting them into their own buttons, and they continue to work fine, which leads me to think there is something wrong with our Javascript. I suspect it may be relying on assumptions about Quickbase or the page structure which are no longer true with the latest update. Any ideas?
Thanks in advance!
Jonathan
QuickBaseCoachD
6 years agoQrew Captain
The reason for the JavaScript is that it will refresh whatever page regardless of whether it�s a record or any report.
When you use the method with the nested URLs, the last step has to display either the record or a particular report. So it�s a bit annoying to have to have different versions of the formula URL depending if you are putting the button on a record or a report or an embedded child table on a parent record.
When you use the method with the nested URLs, the last step has to display either the record or a particular report. So it�s a bit annoying to have to have different versions of the formula URL depending if you are putting the button on a record or a report or an embedded child table on a parent record.