Wednesday, 7 August 2013

Change the style class of an with AJAX

Change the style class of an with AJAX

I've managed to get AJAX working so that PHP is executed on click of an
image, however, I want this result to be shown visually in real time
without the page reloading so I'd like to change the class of my <img>
tags on click.
My image tag is currently something like <img title="<?=$game['name']?>"
class="game_<?=$complete?>" src="<?=$gameimgurl?>"> and I'd like to change
it onclick with PHP/AJAX.
Is this possible? Thanks! :D

No comments:

Post a Comment