...

View Full Version : seeting a variable in javascript?



akpaga22
09-20-2011, 09:39 PM
Hi friends i have this

var infobox = "<div style='font-size:12px;font-weight:bold; background-color:#E6E6E6;height:100px;width:100%;;filter: alpha(opacity=100)'>" + name + "<br>" + Address + "<br><br> <a href ='wfmprintservice.aspx?CustNumber='"+ Cust_number +">View More Details</a></div>";


i am able to redirect by clicking on the ling but the variable Cust_number is not being passed...Can someone please check if my h ref is being properly set...

Thank you

blaze4218
09-20-2011, 10:08 PM
That's simple enough, you closed your single quote for the href before adding your variable. try this



var infobox = "<div style='font-size:12px;font-weight:bold; background-color:#E6E6E6;height:100px;width:100%;;filter: alpha(opacity=100)'>" + name + "<br>" + Address + "<br><br> <a href ='wfmprintservice.aspx?CustNumber="+ Cust_number +"'>View More Details</a></div>";



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum