NavigateUrl="Product.aspx?ID=http://item.taobao.com/auction/item_detail.jhtml?item_id=4e1cc7b5a4cf6ee8a802cb29e173dd01&x_id=0db1&received_or_posted=0&buyer_or_seller=0&wwdialog=bbxxbbmc"
  为什么我Product.aspx页面接收到的值只有"http://item.taobao.com/auction/item_detail.jhtml?item_id=4e1cc7b5a4cf6ee8a802cb29e173dd01",求解答,为什么值只传了一半啊?

解决方案 »

  1.   

    你这样写它会把&x_id=0db1 &received_or_posted=0 &buyer_or_seller=0 &wwdialog=bbxxbbmc 都当成参数
    你取值就只有前面的值了
      

  2.   

    NavigateUrl="Product.aspx?ID='http://item.taobao.com/auction/item_detail.jhtml?item_id=4e1cc7b5a4cf6ee8a802cb29e173dd01&x_id=0db1&received_or_posted=0&buyer_or_seller=0&wwdialog=bbxxbbmc'"这样在里面加上单引号试试
      

  3.   

     我实际用的是这种方法,从数据库读取的值,但是只有这条记录出现问题,请教该怎么解决!NavigateUrl='<%# "Product.aspx?ID="+Eval("CurrentPage") %>'
      

  4.   


    另外一些也成了Product.aspx页面的参数了,也就是ID="http://item.taobao.com/auction/item_detail.jhtml?item_id=4e1cc7b5a4cf6ee8a802cb29e173dd01"
    x_id="0db1"
    received_or_posted="0"
    buyer_or_seller="0"
    wwdialog="bbxxbbmc"因为你的Url没有用UrlEncode转义
      

  5.   

    参数是 用&分割的,你的 被分成多个参数了,当作一个参数,js的escape。<a href="javascript:window.location.href='Product.aspx?ID='+escape('<%# Eval("value") %>')">HyperLink</a><a href="javascript:window.location.href='Product.aspx?ID='+escape('http://item.taobao.com/auction/item_detail.jhtml?item_id=4e1cc7b5a4cf6ee8a802cb29e173dd01&x_id=0db1&received_or_posted=0&buyer_or_seller=0&wwdialog=bbxxbbmc')">HyperLink</a>