Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Ckeditor Example
<script src=""></script>
<textarea style="display:none;" id='terms_of_conditions' name='terms_of_conditions' > {{$content}} </textarea>
<button type="button" id="submit" class="btn btn-info">Save<div class="ripple-container"></div></button>
$(document).ready(function () {
CKEDITOR.replace( 'terms_of_conditions' );
CKEDITOR.config.allowedContent = true;
CKEDITOR.config.contentsCss = _base_url + '/css/terms-style.css';
document.querySelector( '#submit' ).addEventListener( 'click', () => {
const editorData = CKEDITOR.instances['terms_of_conditions'].getData();
type: 'POST',
url: _base_url + "/terms-of-service",
dataType: 'json',
data: {_token:_token,content:editorData},
success: function (response) {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.