CodeCharge Studio
search Register Login  

Web Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> General/Other

 CK Editor used with ASP.net C# Inmotion

Print topic Send  topic

Author Message
innonet

Posts: 55
Posted: 02/06/2011, 3:00 PM

Well, sometimes things are sooooooooooo simple. We just incorporated the latest CK Editor into one of our ASP.net C# Inmotion Projects.

Here is how to do it:

(1) Upload the latest CK Editor Version to the root of your webserver

(2) Create a Record and make sure the field you want to use for the CK Editor is a TEXT AREA. Open the page and switch to HTML View

(3) Add the following script line between the <head></head>
<script type="text/javascript" src="../ckeditor/ckeditor.js"></script>
Make sure that the path to the ckeditor.js script is accurate !!

(4) Add the CK Editor Class to the Text Area. It should look as follows:
<textarea class="ckeditor" id="TextareaID" rows="3" cols="50" name="{Work_Desc_Name}">{Work_Desc}</textarea></td>

Variations:

(1) Using the BASIC Toolbar
Add <script>CKEDITOR.config.toolbar='Basic'</script> BEFORE the text area. There are two toolbars right now. If you don't add this script line then the default toolbar will be used.

It should like like:

<script>CKEDITOR.config.toolbar='Basic'</script>
<td><textarea class="ckeditor" id="TextareaID" rows="3" cols="50" name="
{Work_Desc_Name}">{Work_Desc}</textarea></td>

(2) Using a different SKIN
Add <script>CKEDITOR.config.skin='v2'</script> BEFORE the text area. "v2" is the skin name. Right now there are only three skins available.

It should look like:

<script>CKEDITOR.config.skin='v2'</script>
<td><textarea class="ckeditor" id="TextareaID" rows="3" cols="50" name="
{Work_Desc_Name}">{Work_Desc}</textarea></td>

Compile and upload and you are ready to roll. So bloody simple. And the CK Editor is so much faster and precise than the stone old FCK Editor.

Please let me know if you need help. Can send a project file if required.
View profile  Send private message
ckroon

Posts: 869
Posted: 02/07/2011, 8:26 AM

Thanks!
I am using PHP but I am sure the html codes are the same.
I was struggling with getting the toolbar to change.. gonna have to go try this.

_________________
Walter Kempees...you are dearly missed.
View profile  Send private message
FRMK

Posts: 38
Posted: 03/05/2013, 12:23 PM

Quote innonet:
Well, sometimes things are sooooooooooo simple. We just incorporated the latest CK Editor into one of our ASP.net C# Inmotion Projects.

Here is how to do it:

(1) Upload the latest CK Editor Version to the root of your webserver

(2) Create a Record and make sure the field you want to use for the CK Editor is a TEXT AREA. Open the page and switch to HTML View

(3) Add the following script line between the <head></head>
<script type="text/javascript" src="../ckeditor/ckeditor.js"></script>
Make sure that the path to the ckeditor.js script is accurate !!

(4) Add the CK Editor Class to the Text Area. It should look as follows:
<textarea class="ckeditor" id="TextareaID" rows="3" cols="50" name="{Work_Desc_Name}">{Work_Desc}</textarea></td>

Variations:

(1) Using the BASIC Toolbar
Add <script>CKEDITOR.config.toolbar='Basic'</script> BEFORE the text area. There are two toolbars right now. If you don't add this script line then the default toolbar will be used.

It should like like:

<script>CKEDITOR.config.toolbar='Basic'</script>
<td><textarea class="ckeditor" id="TextareaID" rows="3" cols="50" name="
{Work_Desc_Name}">{Work_Desc}</textarea></td>

(2) Using a different SKIN
Add <script>CKEDITOR.config.skin='v2'</script> BEFORE the text area. "v2" is the skin name. Right now there are only three skins available.

It should look like:

<script>CKEDITOR.config.skin='v2'</script>
<td><textarea class="ckeditor" id="TextareaID" rows="3" cols="50" name="
{Work_Desc_Name}">{Work_Desc}</textarea></td>

Compile and upload and you are ready to roll. So bloody simple. And the CK Editor is so much faster and precise than the stone old FCK Editor.

Please let me know if you need help. Can send a project file if required.


God bless you for posting this. Thank you so much.

_________________
FR
View profile  Send private message
cvboucher

Posts: 191
Posted: 04/05/2013, 9:44 PM

innonet,

I was able to successfully implement this in VB.Net InMotion but if I regenerate the page CCS keeps inserting {page:pathToRoot} in front of the src path in step 3 and it stops working. Did you experience this and were you able to overcome it? I don't know if it would make a difference but I'm using Designs instead of styles.

<script type="text/javascript" src="{page:pathToRoot}/ckeditor/ckeditor.js"></script>

Also, when I submit the page I get the following error.

Quote :
A potentially dangerous Request.Form value was detected from the client (ctl00$Content$EmailTemplateType$ctl00$Instructions="<p>Note Use $ before...").

In the past I set the Validate Request page property to false but it doesn't seem to fix it in this situation. Again, could be because I'm using designs instead of styles. Just wondering if you experienced this and how you overcame it.

Thanks,
Craig
View profile  Send private message

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Internet Database

Visually create Web enabled database applications in minutes.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.