if i have no right use the flag "Accepted",please hide it
I just added this to my sites/all/themes/mytheme/template.php file and it worked after clearing the theme registry:

function mytheme_preprocess_flag(&amp;$variables) {
  // Do something here
  dpm($variables);  // Pretty print $variables if you have the Devel module installed
}


That should give you a nudge in the right direction.