Page 1 of 1

Having trouble making component visible/invisible

Posted: Thu Mar 07, 2013 6:14 am
by ssquire

I have tried using both jQuery & Javascript to change the visibility of a page component and it doesn't seem to be working (although I'm not perfect and it could be me too).

I simply have a button that when it is clicked an image should become invisible and another should become visible. I even created a test case of a button that when clicked executes the following in Javascript:

document.getElementById("strike_image_81").visible="false";

In jQuery I have:

$('strike_image_81').hide();
$('strike_image_82').show();

What could I be doing wrong for these components to not respond to this code?


Having trouble making component visible/invisible

Posted: Thu Mar 07, 2013 8:53 am
by Kateryna Grynko

Hi Steven,

If strike_image_81 and strike_image_82 are Component names then:
codeTiggzi('strike_image_81').hide();
Tiggzi('strike_image_82').show(); /code
If strike_image_81 and strike_image_82 are the Component IDs then:
code$('#strike_image_81').hide();
$('#strike_image_82').show();/code


Having trouble making component visible/invisible

Posted: Thu Mar 07, 2013 3:51 pm
by ssquire

Thanks Katya! Using the Tiggzi API method worked, since they are component names. Just out of curiosity, how would I access them using the DOM?


Having trouble making component visible/invisible

Posted: Mon Mar 11, 2013 7:26 am
by Maryna Brodina

Hello! Sorry for delay. This should help http://docs.tiggzi.com/javascript-api...