elmbrook
asked on
Label replacement in MVC - linefeeds, carraige returns, <br /> replacements.
Hi
I have information from a number of different sources in my database which I would like to display to my user so what I did was I created a query to gather all the information.
To display the information, i did the following:
ViewData.Add("Details",ful lname + "<br />" + partner + "<br />" + address + "<br />" + phone + "<br />" +
cell + "<br /><br /><a href='myhyperlinkpage.aspx ?id=" + id + "'>Edit My Details</a>" );
But it is all formatted incorrectly in the page. The <br /> tags show up as text and my link shows up as <a href='myhyperlinkpage.aspx ?id=2046d6 9cfa888888 015797'>Ed it My Details</a>
How should I be doing this?
I have information from a number of different sources in my database which I would like to display to my user so what I did was I created a query to gather all the information.
To display the information, i did the following:
ViewData.Add("Details",ful
cell + "<br /><br /><a href='myhyperlinkpage.aspx
But it is all formatted incorrectly in the page. The <br /> tags show up as text and my link shows up as <a href='myhyperlinkpage.aspx
How should I be doing this?
you can return all this field in model and handle at client site to display that field.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.