Page 1 of 1

Javascript random quotes - why can't I have two of them?

Posted: Fri Feb 28, 2025 5:56 pm
by alan_sh
I'm using the ready-to-use javascripts to have randon quotes displayed when the page loads.

No issues if I just have one on a page. But if I have two (I copied one to create the second), only one of the, shows up when I review or publish.

They have different ID's. So, is this a limitation? or is it something I've done?

Alan

Re: Javascript random quotes - why can't I have two of them?

Posted: Fri Feb 28, 2025 6:01 pm
by BaconFries
They have different ID's. So, is this a limitation? or is it something I've done?
The limitation is you can only have one script (javascript) per page. So no you haven't done anything wrong.

Re: Javascript random quotes - why can't I have two of them?

Posted: Fri Feb 28, 2025 6:43 pm
by Pablo
You are correct, some scripts can only be used once per page.
Note that this is also documented in the help.

Re: Javascript random quotes - why can't I have two of them?

Posted: Fri Feb 28, 2025 10:12 pm
by alan_sh
Thanks

Alan