Jump to content

CK editor


Go to solution Solved by Ch0cu3r,

Recommended Posts

Did you look here first before posting

http://docs.ckeditor.com/#!/guide/dev_installation

 

Did you look here first before posting

http://docs.ckeditor.com/#!/guide/dev_installation

thanks for help. i got it now.But how to display the textarea content from database using ckeditor.

Link to comment
https://forums.phpfreaks.com/topic/284383-ck-editor/#findComment-1460689
Share on other sites

i did it.......

 

 

<html>
<head>
<script src="../ckeditor.js"></script>
</head>
<?php
$conn=mysql_connect("localhost","root","")or die(mysql_error());
mysql_select_db("regis")or die(mysql_error());
print_r($_GET);
$p_id=$_GET['p_id'];
$query=mysql_query("SELECT p_content FROM admin_page WHERE p_id='$p_id'")or die(mysql_error());
$row=mysql_fetch_array($query,MYSQL_ASSOC);
?>
<textarea cols="80"  id="p_content" name="p_content" rows="10" >

    <?php echo $row['p_content']; ?>

</textarea>


//print_r ($row['p_content']);



</html>

Link to comment
https://forums.phpfreaks.com/topic/284383-ck-editor/#findComment-1460692
Share on other sites

<html>
<head>
<script src="http://localhost:81/assignment/ckeditor/ckeditor.js"></script>
</head>
<body>
<div style='padding-top:50px'>
  CKEDITOR:
<div>
<div>
<?php
$conn=mysql_connect("localhost","root","")or die(mysql_error());
mysql_select_db("regis")or die(mysql_error());
$p_id=$_GET['p_id'];
$query=mysql_query("SELECT p_content FROM admin_page WHERE p_id='$p_id'")or die(mysql_error());
$row=mysql_fetch_array($query,MYSQL_ASSOC);
?>
<textarea cols="80"  id="p_content" name="p_content" rows="10" >

    <?php echo $row['p_content']; ?>

</textarea>
</div>
<script type='text/javascript'>
      CKEDITOR.replace( 'p_content' );
</script>

</body>





</html>

Link to comment
https://forums.phpfreaks.com/topic/284383-ck-editor/#findComment-1460704
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.