Forum Discussion

GregoryGebhardt's avatar
GregoryGebhardt
Qrew Cadet
5 years ago

Javascript Reload stopped working.

Hopefully this is in the right place...

Formulat URLs...I have used multiple urls with some nice javascript (provided on this forum) for well over a year now but now the code seems to be having some problems.  Anyone else having problems as of late?

No errors when button clicked. No errors when the urls are fired individually (via response). Chrome & Edge.  

Code:

"javascript:" &  

"$.get('" & $url & 

"'),$.get('" & $urltwo &

"'),$.get('" & $urlthree &

"',function(){" &  

"location.reload(true);" &  

"})" 



------------------------------
Greg
------------------------------
  • Does this fail on all records or does it fail sensitive to data in one record?

    ------------------------------
    Mark Shnier (YQC)
    Quick Base Solution Provider
    Your Quick Base Coach
    http://QuickBaseCoach.com
    mark.shnier@gmail.com
    ------------------------------
    • GregoryGebhardt's avatar
      GregoryGebhardt
      Qrew Cadet

      Mark, I believe it so far it was isolated to just a couple of records (but the feature is used less often).  I'm keeping and eye on all our other apps to make sure.  I  made sure to URLENCODE() the 'data' that was being pushed.  I copied the button link and took the urls directly out of the link and ran independently and it worked just fine.  It was the combination of the two with the java that seemed to cause the issue. BTW these were AddRecords in 2 different tables, all tables in the same app.

      I was suspect on the 'data' as well (if that is where you were going) but as I'm mostly ignorant with Java...is there a chance that the 'data' and url build could cause the Java to fail? (i.e. some weird character or length of data being pushed)  If so I'll go back and review the 'data' more carefully to see if there is any weird anomalies. 



      ------------------------------
      Gregory Gebhardt
      ------------------------------
      • MarkShnier__You's avatar
        MarkShnier__You
        Icon for Qrew Legend rankQrew Legend
        Yes, look for unusual data especially like a single quote.  I have found I need to strip those out of the data using search and replace before using in a URL formula with that JavaScript refresh.

        ------------------------------
        Mark Shnier (YQC)
        Quick Base Solution Provider
        Your Quick Base Coach
        http://QuickBaseCoach.com
        mark.shnier@gmail.com
        ------------------------------
    • GregoryGebhardt's avatar
      GregoryGebhardt
      Qrew Cadet
      Brilliant, Thanks for the direction. Makes total sense.

      ------------------------------
      Greg
      ------------------------------