Jump to content

CASPIO app provided has old script - is there new version?


Recommended Posts

Hello for the CASPIO "Signs of Spring" photo app there's embedded JS that's not updated for the new window.onload requirement.

Can new code be provided please?

Here's what is currently there:

<script>
window.onload = function() {

window.open('[@cbBridgeServer]/dp.asp?AppKey=[@app:Public_Gallery_DP_AppKey]&category=[@category]&author=[@author]','_parent'); 

}
</script>

<!-- THIS IS WHAT I UPDATED IT TO, BUT STILL ERRORS OUT -->
<!-- I assume the window.open call is the problem?? -->

<script type="text/javascript">
document.addEventListener('DataPageReady', function (event) {
window.open('[@cbBridgeServer]/dp.asp?AppKey=[@app:Public_Gallery_DP_AppKey]&category=[@category]&author=[@author]','_parent'); 

});
</script>

Thanks, Geoff

Link to post
Share on other sites

Hi @geoffdude,

 

I believe that you have an issue with Javascript since Datapage URL link has changed after 10.0 Caspio Release

You can try to use the following script:

<script type="text/javascript">
document.addEventListener('DataPageReady', function (event) {
window.open('[@cbBridgeServer]/dp/[@app:Public_Gallery_DP_AppKey]?category=[@category]&author=[@author]','_parent'); 

});
</script>

Hope this helps.

Regards,

@Vitalikssssss

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...