simpleCE v.0.7 Docs

What is simpleCE

simpleCE is a simple Content-Management System with front-end editor mode. That means, you can directly edit its contents, files and images in the view in which you would see your website as a normal user. There is also no complex back-end, no complicated settings or other hindrances. The system has been so designed that one need not familiarize oneself with a complex template or theme system, because there are none. Templates can be designed individually through separate PHP Includes.

The actual system offers an ID-based elements system; you can thus incorporate editable texts, images and file elements into all your PHP files, easily and without much expenditure. The editor interface and Light Box functions are managed and integrated autonomously by the system.

Features:

Installation

Installing simpleCE is considerably simpler and only comprises a couple of short steps. Copy the "simpleCE" folder to the main structure of your web page, so that this folder can be called something like: www.example.com/simpleCE/

If the simpleCE folder is now completely uploaded to your web space, you can call the installation script, which is accessible at: www.example.com/simpleCE/setup/

Now follow the instructions on the screen and execute the installation script to the end:

In the top area of the list, the properties of your system are checked; all elements should be shown in green, so that simpleCE will be installed smoothly.

In the first screen, select your language; after this point, the configuration is sub-divided into two areas:

System configuration
Enter the required details in the field user name / password, which you would like to use later to log on to your simpleCE system. In the HTML mode, select the HTML version of your web page. The following two fields should be automatically populated by the system, but you should still check them. In the field URL to the web page, enter the HTTP address of your web page and in the simpleCE directory, the server path to the simpleCE installation.

MySQL database
Enter here the data for your MySQL Server and the name of the database in which simpleCE is to be installed. The standard MySQL Server is localhost. For all other information, contact your web host.

If you have entered both areas completely and correctly, click on the "Install now…" button.

IMPORTANT: Remember to delete the /setup/ directory from the simpleCE directory after the installation.

System Update

To update an existent simpleCE installation to the new version 0.7 you need to download the latest version from CodeCanyon.

Copy the new files from your local simpleCE folder to your webspace and overwrite the old files but without the config.php and /setup/ - /uploads/ folders.

Integrating simpleCE into your web page

The integration of simpleCE into your web page is as easy as the installation; the first thing to do is to incorporate some standard functions before you can pass the content elements.

The first prerequisite that your web page must necessarily fulfill is that it should be based on PHP. So your files should be called, for example, index.php and not, say, index.html or index.htm.

Now if you add the following require instruction in the first line of your PHP file: <?php require_once('simpleCE/frontend.php'); ?> and make a call to your web page, it should give an error message Check the folder structure from the Installations Script.

In the next step, add the standard functions of simpleCE to the web page:

This function <?php $simpleCE->head(); ?> (use <?php $simpleCE->head(false); ?> instead to disable the Colorbox Styles and Scripts in the frontend) must be copied to the <head> </head> area of the website and the function <?php $simpleCE->footer(); ?> before the closing </body> tag.

If both functions are integrated and the require instruction is included, you can begin to incorporate the editable simpleCE elements, which cover: text, image, file and loop elements.

IMPORTANT: Please note that, in the following course, all IDs in functions must be unique numbers in the complete web page. The numbers themselves can be freely defined.

Text element

The text element offers the option to incorporate texts into the web page in three variants: short text, long text and long text with editor.

The complete function has the following structure:

<?php $simpleCE->text( ID , Editor-Modus (optional), [other options]); ?>

An example of the simple function with the minimum parameter ID, the ID must be a number and unique in the entire web page, except when you wish to output the same element with the same content at different locations:

<?php $simpleCE->text( 10 ); ?>

If the function is only called with the ID parameter, the large text is incorporated without editor. The settings possible as Editor mode parameter are as follows: "short" for a short text field, "long" for a large text field without editor or "editor" for a large text field with CKEditor.

The optional parameter must be defined as array; it can contain the keys "before" and "after"; "before" indicates the HTML code that is outputted by the text and "after" indicates the HTML code which is outputted after the text. Both before and after are only outputted if the text field is not blank. Here is an example for the complete function with all parameters:

<?php $simpleCE->text( 10, 'short', array('before'=>'<h2>', 'after'=>'</h2>') ); ?>

Image element

You can use the image function to incorporate a complete image upload in the front-end using Light Box function; the function structure is as follows:

<?php $simpleCE->image( 20, [other options]); ?>

The ID must be a number and unique in the whole web page; except when you wish to output the same element with the same content at different locations.

The alternative options must be defined as array and can contain two key elements: phpThumb and target.

phpThumb can contain all parameters that are made available via phpThumb (e.g.: w=140&h=185); please also see the phpThumb documentation in this regard: http://phpthumb.sourceforge.net/.

target indicates the destination of the link, in case the image is linked in the front-end, the following are possible: _self, _parent or _blank.

Here is a complete example with optional parameters:

<?php $simpleCE->image( 20, array('phpThumb' => 'w=140&amp;h=185', 'target' => '_blank') ); ?>

File element

The File element allows uploading of various files and automatically positions a download link in the front-end; the function is constructed as follows:

<?php $simpleCE->file( 30, [other options] ); ?>

The ID must be a number and unique in the whole web page, except when you wish to output the same element with the same content at different locations.

As alternative options, "target" and "class" can be set; in the case of options, they can be transferred to the normal HTML attributes target="" and class=""; here is a complete example:

<?php $simpleCE->file( 30, array('target'=>'_blank', 'class'=>'sce_link_own_class') ); ?>

Loop function

The Loop function allows repetition and new creation of certain functions, for example for image galleries or news pages. The structure is as follows:

<?php $simpleCE->loopStart( ID ); while( $simpleCE->loopController() ){ ?>

In this area, you are free to incorporate as many HTML elements, as well as simpleCE functions as you need.

<?php $simpleCE->loopStop(); } ?>

The ID must, like all other elements, also be unique.

Logging in the administrative area and working with simpleCE

To reach the administrative area of simpleCE, first call the Login at the following web address: www.example.com/simpleCE/

Log in with the details defined at the time of installation and you will again reach your web page, but in the editing mode. Now the pertinent editing tips are displayed next to all elements, which can also be edited.

The heading area will show the control bar; you reach the Control Center there, this Help, the Logout and you can reload the page to make changes.

You will find some information in the Control Center about your simpleCE installation, as well as a tool for database optimization; you can find more relevant information in this regard in the Control Center.

Change the admin theme

After you've installed simpleCE open you config.php and have a look at line #19:
define('design', 'ui-lightness'); "ui-lightness" stands for the orange design and "smoothness" for the grey one.

Change system branding

After you've installed simpleCE open you config.php and have a look at line #20:
define('branding', ''); - There you can type your new branding like define('branding', 'Company');

Rename simpleCE folder

To rename the simpleCE folder proceed as follows: Install the system in the usual way. After the succeed setup you need to open the config.php. There you can change the folder names in line #10 and #11: sce_root und sce_folder. Then you can rename the folder itself.