Step 3: Separating Viewing & Editing Mode

Example file: example3.php.

Then we check, if $edit=’y’, we include GridlessBuilder.js script for editing. If not, we just need to include Gridless CSS framework for viewing (see the comparison between scripts required for viewing and editing in the previous step). Here we implement the checking:

<?php if($edit=='y'){ ?>
<link href="dist/gridlessbuilder.css" rel="stylesheet" type="text/css" />
<?php } ?>
<?php if($edit=='y'){ ?>
<script src="assets/lang/en.js"></script> 
<script src="dist/gridlessbuilder.min.js"></script>
...
<?php } ?>

For the complete code and to try the example, please open in your browser: example3.php.

After editing, we should be able to see the result and leave the editing mode, so we need to separate the viewing and editing mode. For this, we will use the same page with viewing mode as the default and use a querystring ?edit=y to enter the editing mode.

We can read the querystring using:

$edit = $_GET['edit'];

http://localhost/mysite/example3.php

http://localhost/mysite/example3.php?edit=y

About | Privacy | Delivery & Return

Copyright © 2021 Insite Mitra Inovindo. All Rights Reserved.

situs slot situs slot situs slot situs slot situs slot situs slot situs slot situs slot situs slot situs slot situs slot situs slot situs slot situs slot situs slot slot gacor slot gacor slot gacor slot gacor slot gacor slot gacor bengbengtoto bengbengtoto bengbengtoto bengbengtoto bengbengtoto bengbengtoto toto slot toto slot cahayatoto cahayatoto cahayatoto jual toto jualtoto balaitoto mpo slot toto togel toto togel toto togel toto slot toto slot toto slot indosattoto toto slot indosattoto indosattoto jualtoto toto slot cahayatoto Nagihtoto Balaitoto Balaitoto Bengbengtoto Balaitoto Balaitoto Balaitoto Mineraltoto Mineraltoto Mineraltoto Mineraltoto Nagihtoto Mineraltoto indosattoto indosattoto ohtogel ohtogel indosattoto Indosattoto Nagihtoto