Solved

tinymce into SQL

Posted on 2012-03-22
1
430 Views
Last Modified: 2012-05-14
Hi,

I have successfully setup Tinymce on my text area and it displays text fine, but when I submit text in it to be saved into my SQL database it removes the tags <p> and replaces with &lt;p&gt;

Is there anyway to stop this??

Code Below

string LongArticle = txtArticle.Text;

tring query1 = "UPDATE smartChimps_news SET date=convert(datetime,'" + dateNew + "',103) , heading='" + Heading + "', LongArticle ='" + LongArticle + "' WHERE newsid='" + newsid + "'";



Regards

Michael
0
Comment
Question by:hayward03
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 9

Accepted Solution

by:
gery128 earned 500 total points
ID: 37753389
You may want to decode text before inserting to database.
Try to use HtmlUtility.HtmlDecode method
0

Featured Post

Instantly Create Instructional Tutorials

Contextual Guidance at the moment of need helps your employees adopt to new software or processes instantly. Boost knowledge retention and employee engagement step-by-step with one easy solution.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Lots of people ask this question on how to extend the “MembershipProvider” to make use of custom authentication like using existing database or make use of some other way of authentication. Many blogs show you how to extend the membership provider c…
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
This video shows how to use Hyena, from SystemTools Software, to update 100 user accounts from an external text file. View in 1080p for best video quality.

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question