当前位置: 代码迷 >> JavaScript >> javascript:openurl() 有关问题
  详细解决方案

javascript:openurl() 有关问题

热度:307   发布时间:2012-03-28 15:40:03.0
javascript:openurl() 问题
<a   href= "javascript:OpenURL( 'fee_query.do?method=xxx&current_company_id= "+current_company_id+ " '); "> <img   src= "images/right_03.gif "   width= "178 "   height= "25 "   border= "0 "> </a>


连接一个字符串总是报错~

------解决方案--------------------
<a href= "javascript:OpenURL( 'fee_query.do?method=xxx&current_company_id= '+current_company_id) "> <img src= "images/right_03.gif " width= "178 " height= "25 " border= "0 "> </a>

------解决方案--------------------
current_company_id,全局变量?

我习惯这样写 <a href= "# " onclick=doChangeURL()>
//---------script段
function doChangeURL(){
window.location.href= "fee_query.do?method=xxx&current_company_id= "+current_company_id;
}
  相关解决方案