Hello,
I'm stripping this js script out so that it can work in my specific case that is to have a 'pretend' progress bar before a next code comes in. However, I don't know how to call this because the Progressive bar script is automatically activate when loaded
How can I change the document.observe('dom:loaded', function() to a function so that I can call to when needed?
thanks!
I'm stripping this js script out so that it can work in my specific case that is to have a 'pretend' progress bar before a next code comes in. However, I don't know how to call this because the Progressive bar script is automatically activate when loaded
Code:
<span id="element6">[ Loading Progress Bar ]</span>
<script type="text/javascript">
function progressLoad() {
document.getElementById('element6').style.display='';
// second manual example : multicolor (and take all other default paramters)
manualPB2 = new JS_BRAMUS.jsProgressBar(
$('element6'),
100,
{
barImage : Array(
'images/bramus/percentImage_back4.png',
'images/bramus/percentImage_back3.png',
'images/bramus/percentImage_back2.png',
'images/bramus/percentImage_back1.png'
),
onTick : function(pbObj) {
switch(pbObj.getPercentage()) {
case 100:
callme();
//alert('Progressbar full at 100% ... maybe do a redirect or sth like that here?');
break;
}
return true;
}
}
);
}, false);
</script>
How can I change the document.observe('dom:loaded', function() to a function so that I can call to when needed?
thanks!