I have a custom module, in a javascript file that is located in the js folder of the module, I captured a value from a previously written function using an if statement. Ex: if($numb==6) show this img else show this img.
I need to access this value/var so I can display a particular image on my tpl.php when it loads.
How can I accomplish this in drupal7?