Page 1 of 1

Generating html from string & onclick is not firing

Posted: Wed Jul 30, 2014 3:45 am
by deveu

I am generating html from string and have a evnt in html onclick
onclick is not working
pls let me know why

var myString = '

Code: Select all

                             label_reward_name_content 
                             label_reward_description_content 
                             label_required_points_content 

                                  a class="Reward_btn_reward" name="btn_reward" rel="nofollow" 
                                Reward Now 
                                 /a 

                                   a class="Reward_btn_reward_send_register_sms" name="btn_reward_send_register_sms" rel="nofollow" 
                                Send register sms 
                                 /a 

                       ' 

function make_reward(k)
{
alert(1);
}


Generating html from string & onclick is not firing

Posted: Wed Jul 30, 2014 4:01 am
by Alena Prykhodko

Hello,

Please check whether there are some errors in browser console (F12).