<head>
<script src="http://cdn.ckeditor.com/4.6.2/standard-all/ckeditor.js"></script>
</head>
<?php
//do the mysql connection
//fetch the needed data suppose we have data one $text_content;
//and simply print in textarea
?>
<textarea cols="80" id="editor1" name="editor1" rows="10" > <?php echo $text_content; ?></textarea>
<script>
CKEDITOR.replace( 'editor1', {
uiColor: '#CCEAEE'
} );
</script>