using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

public partial class etwuser_sendnews : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        HttpCookie GetCookie = Request.Cookies["cookEtwuser"];
        if (Request.Cookies["cookEtwuser"] == null)
        {
            Response.Redirect("../index.aspx");
        }
        else
        {
            Datawebsite();
        }
    }
    public void Datawebsite()
    {
        HttpCookie GetCookie = Request.Cookies["cookEtwuser"];
        DataSet ds = DbHelperSQL.Query("select u.userid,w.website from etw_user u inner join etw_web w on u.userid=w.usernameid where u.username='" + GetCookie["username"].ToString() + "'");
        if (ds.Tables[0].Rows.Count > 0)
        {
            Repeater1.DataSource = ds.Tables[0].DefaultView;
            Repeater1.DataBind();
        }
    }
}
