代码修改后的版本,全部提交
This commit is contained in:
122
Mtxfw.shop/bbs/index.aspx.cs
Normal file
122
Mtxfw.shop/bbs/index.aspx.cs
Normal file
@@ -0,0 +1,122 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Web;
|
||||
using System.Web.SessionState;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using System.Web.UI.HtmlControls;
|
||||
|
||||
namespace Mtxfw.shop.bbs
|
||||
{
|
||||
/// <summary>
|
||||
/// myShoppingCart <20><>ժҪ˵<D2AA><CBB5><EFBFBD><EFBFBD>
|
||||
/// </summary>
|
||||
public partial class index : System.Web.UI.Page
|
||||
{
|
||||
Mtxfw.DAL.Ads daoAds = new Mtxfw.DAL.Ads();
|
||||
protected string ShowConent = "";
|
||||
public Mtxfw.DAL.user_info daoUser = new Mtxfw.DAL.user_info();
|
||||
public Mtxfw.DAL.forum daoforum = new Mtxfw.DAL.forum();
|
||||
public Mtxfw.DAL.bbs daobbs = new Mtxfw.DAL.bbs();
|
||||
Mtxfw.Utility.Config config = new Mtxfw.Utility.Config();
|
||||
protected int IFStores = 0;
|
||||
protected string AdsName01, AdsName02, AdsName03, AdsName04, AdsName05, AdsName06, AdsName07, AdsName08, AdsName09, AdsName10;
|
||||
protected string indexTP01, indexTP02, indexTP03, indexTP04, indexTP05, indexTP06, indexTP07, indexTP08, indexTP09, indexTP10;
|
||||
protected string indexTPLink01, indexTPLink02, indexTPLink03, indexTPLink04, indexTPLink05, indexTPLink06, indexTPLink07, indexTPLink08, indexTPLink09, indexTPLink10;
|
||||
protected void Page_Load(object sender, System.EventArgs e)
|
||||
{
|
||||
// <20>ڴ˴<DAB4><CBB4><EFBFBD><EFBFBD><EFBFBD><EFBFBD>û<EFBFBD><C3BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Գ<EFBFBD>ʼ<EFBFBD><CABC>ҳ<EFBFBD><D2B3>
|
||||
if (!Page.IsPostBack)
|
||||
{
|
||||
Page.Title = "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̳-" + config.webName;
|
||||
Page.MetaDescription = "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̳-" + config.webDescription;
|
||||
Page.MetaKeywords = "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̳-" + config.webKeywords;
|
||||
myDataBind();
|
||||
}
|
||||
}
|
||||
private void myDataBind()
|
||||
{
|
||||
if (Session["MemberId"] != null && Session["MemberIFStores"] != null)
|
||||
{
|
||||
IFStores = int.Parse(Session["MemberIFStores"].ToString());
|
||||
}
|
||||
System.Data.DataSet Ds_Ads = daoAds.GetCacheList("top 50", "utype=N'<27><>̳<EFBFBD><CCB3><EFBFBD><EFBFBD>' Order By AdsSort asc", "bbs_Ads");
|
||||
|
||||
int i = 1;
|
||||
if (Ds_Ads.Tables[0].Rows.Count > 0)
|
||||
{
|
||||
foreach (System.Data.DataRow Dr in Ds_Ads.Tables[0].Rows)
|
||||
{
|
||||
if (i == 1)
|
||||
{
|
||||
indexTP01 = Dr["AdsPic"].ToString();
|
||||
indexTPLink01 = Dr["AdsUrl"].ToString();
|
||||
AdsName01 = Dr["AdsName"].ToString();
|
||||
}
|
||||
if (i == 2)
|
||||
{
|
||||
indexTP02 = Dr["AdsPic"].ToString();
|
||||
indexTPLink02 = Dr["AdsUrl"].ToString();
|
||||
AdsName02 = Dr["AdsName"].ToString();
|
||||
}
|
||||
if (i == 3)
|
||||
{
|
||||
indexTP03 = Dr["AdsPic"].ToString();
|
||||
indexTPLink03 = Dr["AdsUrl"].ToString();
|
||||
AdsName03 = Dr["AdsName"].ToString();
|
||||
}
|
||||
if (i == 4)
|
||||
{
|
||||
indexTP04 = Dr["AdsPic"].ToString();
|
||||
indexTPLink04 = Dr["AdsUrl"].ToString();
|
||||
AdsName04 = Dr["AdsName"].ToString();
|
||||
}
|
||||
if (i == 5)
|
||||
{
|
||||
indexTP05 = Dr["AdsPic"].ToString();
|
||||
indexTPLink05 = Dr["AdsUrl"].ToString();
|
||||
AdsName05 = Dr["AdsName"].ToString();
|
||||
}
|
||||
if (i == 6)
|
||||
{
|
||||
indexTP06 = Dr["AdsPic"].ToString();
|
||||
indexTPLink06 = Dr["AdsUrl"].ToString();
|
||||
AdsName06 = Dr["AdsName"].ToString();
|
||||
}
|
||||
if (i == 7)
|
||||
{
|
||||
indexTP07 = Dr["AdsPic"].ToString();
|
||||
indexTPLink07 = Dr["AdsUrl"].ToString();
|
||||
AdsName07 = Dr["AdsName"].ToString();
|
||||
}
|
||||
if (i == 8)
|
||||
{
|
||||
indexTP08 = Dr["AdsPic"].ToString();
|
||||
indexTPLink08 = Dr["AdsUrl"].ToString();
|
||||
AdsName08 = Dr["AdsName"].ToString();
|
||||
}
|
||||
if (i == 9)
|
||||
{
|
||||
indexTP09 = Dr["AdsPic"].ToString();
|
||||
indexTPLink09 = Dr["AdsUrl"].ToString();
|
||||
AdsName09 = Dr["AdsName"].ToString();
|
||||
}
|
||||
if (i == 10)
|
||||
{
|
||||
indexTP10 = Dr["AdsPic"].ToString();
|
||||
indexTPLink10 = Dr["AdsUrl"].ToString();
|
||||
AdsName10 = Dr["AdsName"].ToString();
|
||||
}
|
||||
i += 1;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user