Posted By

jknight42 on 04/22/10


flash banner ads clickTag

Versions (?)

Who likes this?

1 person have marked this snippet as a favorite


Check for multiple types of clickTag variables

 / Published in: ActionScript


This snippet will check for multiple spellings of clickTag variable. Some systems use clickTag and others use clickTAG. Using this code will allow your banner to be used on either type of system without having to re-edit the code. "clickable_button" is the instance name of a movieclip or button on the stage.

  1. clickable_button.onRelease = function() {
  2. if(_level0.clickTag!=undefined) {
  3. getURL(_level0.clickTag, "_blank");
  4. } else if(_root.clickTAG!=undefined) {
  5. getURL(_level0.clickTAG, "_blank");
  6. } else {
  7. trace("no clickTag or clickTAG specified!");
  8. }
  9. }

Report this snippet  

You need to login to post a comment.