---
title: "How to use ckeditor in mvc."  
description: "How to use ckeditor in mvc."  
author: "Anonymous User"  
published: 2016-09-30  
updated: 2016-09-30  
canonical: https://www.mindstick.com/forum/34188/how-to-use-ckeditor-in-mvc  
category: "c#"  
tags: ["jquery", "mvc"]  
reading_time: 1 minute  

---

# How to use ckeditor in mvc.

We want to use ckeditor .js in [mvc project](https://www.mindstick.com/forum/158706/how-do-you-establish-a-database-connection-in-an-asp-dot-net-mvc-project) please help me.

## Replies

### Reply by Anonymous User

i hope this will help for you.

```
@{
    ViewBag.Title = "Index";
}
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<script src="http://cdnjs.cloudflare.com/ajax/libs/ckeditor/4.2/ckeditor.js"></script>
<script src="http://cdnjs.cloudflare.com/ajax/libs/ckeditor/4.2/adapters/jquery.js"></script>
@using (Html.BeginForm("Index","Home",FormMethod.Post))
{
<div style="width:1000px;">
    <textarea name="TextArea1" id="TextArea1" cols="20" rows="2"></textarea>
</div>
    <input id="Submit1" type="submit" value="submit" />
}

<script>
    $('#TextArea1').ckeditor({
        height: "300px",
        toolbarStartupExpanded: true,
        width: "100%"
    });

</script>
```

\

```
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;

namespace Forum.Controllers
{
    public class HomeController : Controller
    {
        public ActionResult Index()
        {
            return View();
        }

        [HttpPost, ValidateInput(false)]
        public ActionResult Index( FormCollection form)
        {

            var data = form["TextArea1"];

            return View("Index");
        }

    }
}
```

![How to use ckeditor in mvc.](https://www.mindstick.com/mindstickforums/d97cdcfe-1d54-4d95-aecb-ab43a75a624d/images/e86f15a3-3808-438c-97f3-c24924ca214f.png)\
![How to use ckeditor in mvc.](https://www.mindstick.com/mindstickforums/d97cdcfe-1d54-4d95-aecb-ab43a75a624d/images/14b2dba1-ac04-4184-8d69-039116ad85ff.png)\


---

Original Source: https://www.mindstick.com/forum/34188/how-to-use-ckeditor-in-mvc

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
