
BulletedList菜单生成没有问题,现贴上跳转的代码如下:
protected void BulletedList1_Click(object sender, BulletedListEventArgs e)
{
string sItemValue = (sender as BulletedList).Items[e.Index].Value;
string sItemText = (sender as BulletedList).Items[e.Index].Text;
string sURL = LYFunctionCs.LYFunctionCsClass.cmdScalar("SELECT url FROM yf_listitems WHERE listitem_name='" + sItemText + "' ", ConfigurationManager.ConnectionStrings["yflyzpconn"].ConnectionString); Page.ClientScript.RegisterStartupScript(this.GetType(), "", "<script language=javascript>window.open('" + sURL + "','main');</script>");
}
sURL变量输出结果为:http://localhost/aaa/payquery.aspx
页面跳转结果如图: