jayantpaliwal 0 Newbie Poster

Hii All,
I want to generate a block of html at runtime through asp.net C# page. After generating the html I am assigning it to litral control text property. But when I see the generated html in browser, my custom html is embedding within "Span" block. This is blocking my jQuery to run properly. So what I want to stop generating default span blocks around my custom html. I tried innerhtml as well with no success.
Here is the code

string html = "";
        for (int i = 1; i < 5; i++)
        {
            html = html + " <div class=\"navigationItem\" id=\""+ i.ToString()+"\" style=\"width: 100px; height: 50px;\">  Tweet 1</div>";
        }
        Literal1.Text = html;

Thanks in advance.

Jayant Paliwal

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.