Welcome Guest, Not a member yet? Register   Sign In
Installing Ckeditor
#6

(This post was last modified: 08-18-2019, 06:19 AM by Wouter60.)

In CI, you never address php files directly. All url's must point to a controller and a method inside that controller (unless you need the index method).
The textarea that you want to combine with CKEditor must be in a view.
You load the view in a controller.

Example:
View is (...)\application\views\test_ckeditor.php

Controller is (...)\application\controllers\Editor.php
(Keep in mind that a controller must have a name that starts with a capital letter).
PHP Code:
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class 
Editor extends CI_Controller
{
 
 function test()
 
 {
 
    $this->load->view('test_ckeditor');
 
 }


Now, the url is https://spokaneesl.com/editor/test
This will show you the page with the CKEditor textarea. The "editor" segment in the url is the controller; the "test" segment is the method (= function) inside the controller.
Reply


Messages In This Thread
Installing Ckeditor - by ronniebel - 08-16-2019, 09:13 PM
RE: Installing Ckeditor - by Avega Soft - 08-17-2019, 12:10 AM
RE: Installing Ckeditor - by ronniebel - 08-17-2019, 08:20 PM
RE: Installing Ckeditor - by Avega Soft - 08-17-2019, 08:28 PM
RE: Installing Ckeditor - by website - 08-17-2019, 02:28 PM
RE: Installing Ckeditor - by Wouter60 - 08-18-2019, 03:56 AM
RE: Installing Ckeditor - by InsiteFX - 08-18-2019, 04:23 AM
RE: Installing Ckeditor - by ronniebel - 08-19-2019, 12:52 PM



Theme © iAndrew 2016 - Forum software by © MyBB