Can anyone recommend the easiest way to toggle the display of an element remotely? I won't have access to the server so I was wondering if there is a way to remotely toggle the display of an element, in this case from solid to faded? I'm using dashcode and I don't know how cross domain policy impacts this.
$(document).ready(function(hideStuff) {
$('.image2_template').css({ 'opacity' : 0.1 });
$('.text3_template').css({ 'opacity' : 0.1 });
I’m doing the same sort of thing in a Dashcode widget… I have a version.js
file on the widget’s website, and if that file reports a newer version number than what the user’s using, they’ll see a prompt to update. What I did was basically this:
In the callback function for the AJAX query, check whatever you need to; if your display needs to change, then go ahead and do
document.getElementById("image2_template").style.setProperty("opacity", 0.1);
or whatever you need to do.
Note that you will need access to some server somewhere in order for this to work.