I am working on this website of mine in asp.net c# where the data is fetched through the SQL server. and it was working fine till Saturday but now i am getting DIV's getting generated in the data, which i am bringing from database in different sections like country and city and state dropdown.I am attaching an image to show u the div's. Image regarding the error whenever even if i am editing the data ,it generates this tags all over the data, and are getting stored.
Kindly help me out with this.Thanks in advance.
the Code file is
protected void ddlCountry_SelectedIndexChanged(object sender, EventArgs e)
{
if (ddlCountry.SelectedValue == "")
{
ddlState.SelectedIndex = 0;
ddlCity.SelectedIndex = 0;
ddlState.Enabled = false;
ddlCity.Enabled = false;
ddlCountrycode.SelectedIndex = 0;
ddlCountrycode.Enabled = false;
}
else
{
ddlState.Enabled = true;
DataSet ds = Data.spGetStateByCountryId(Convert.ToInt32(ddlCountry.SelectedValue));
ddlState.DataSource = ds;
ddlState.DataTextField = "StateName";
ddlState.DataValueField = "State_Id";
ddlState.DataBind();
DataSet ds1 = Data.spGetCountrycode(Convert.ToInt32(ddlCountry.SelectedValue));
ddlCountrycode.DataSource = ds1;
ddlCountrycode.DataTextField = "CountryCode";
ddlCountrycode.DataValueField = "Country_Id";
ddlCountrycode.DataBind();
ddlCity.SelectedIndex = 0;
ddlCity.Enabled = false;
}
}
and the i am populating the dropdown with this code.
private void PopulateContinentsDropDownList()
{
DataSet ds = Data.spGetCountries();
ddlCountry.DataSource = ds;
ddlCountry.DataTextField = "CountryName";
ddlCountry.DataValueField = "Country_Id";
ddlCountry.DataBind();
ListItem liCountry = new ListItem("Select Country");
ddlCountry.Items.Insert(0, liCountry);
ListItem liState = new ListItem("Select State");
ddlState.Items.Insert(0, liState);
ListItem liCity = new ListItem("Select City");
ddlCity.Items.Insert(0, liCity);
ListItem liCountryCode = new ListItem("Country Code");
ddlCountrycode.Items.Insert(0, liCountryCode);
ddlState.Enabled = false;
ddlCity.Enabled = false;
}
the image for the page where all this is added is Image of dropdownlist