I am a codementor
Learn With Me
Search Your Domain Name Here

CMS as Code Management System

Traditionally in web development environment the full form the abbreviation CMS is defined as Content Management System because its main purpose is to manage the content of the web pages of a website. So far unlimited number of CMS have been developed in various server side languages. But I want to redefine the abbreviation CMS as Code Management System – a system using which different types of source code involved in the generation of web pages of a website can be managed easily and systematically. As we all know while developing a dynamic web page we need to integrate HTML, JavaScript, CSS, PHP and SQL code. Integration of all these five components by a single coder is tedious, error prone and time consuming process. It would be nice if these five types of code can be written by five different types of coders and it will be the responsibility of CMS to integrate all these codes and generate web page. The concept of traditional CMS as well as framework is an attempt in this direction. But still 100% separation between all these five components has not been achieved. The separation between HTML and CSS is achieved by maintaining separate stylesheet. Similarly using jQuery, it is possible to write such JavaScript code in a separate file which controls the content of HTML file without need to change the code of HTML file. Separation between HTML, CSS and JavaScripts have been achieved as all these languages are native component of browser – browser itself is the interpreter of HTML, CSS and JavaScript code. But this is not the case with PHP and SQL code. It would be nice if we write code in PHP in the same style of jQuery – that is by selecting an element of HTML code using its ID or Class and then changing its various attributes such as innerHTML, value etc. This can be achieved if our CMS provides such PHP functions using which we can select HTML DOM elements using its Name/Class/ID. I think that php-simple-html-dom-parser can be used for this purpose. Using this library, HTML DOM can be modified at run time. But while accessing/modifying the value of HTML DOM we need to insert/fetch values from the database which require integration of SQL statement in PHP. So for that purpose I think that stored procedures/functions should be defined in database server containing SQL statement and PHP code should only call those stored procedure/functions. In this way no SQL statement will be directly embedded in the PHP code. The PHP functions/classes should be developed in such a way that there is no need to touch the HTML code by the PHP coder, similarly there is no need to touch SQL statements by PHP coder. Likewise the database stored procedure/functions should be defined in such generic way that there is no need to touch PHP code by SQL coder. If such system is developed successfully then it will automatically improve the speed of development of web based application dramatically. Once the HTML code will be finalized by the HTML coder then CSS, JavaScript, PHP and SQL coder will start working parallel and the project will be completed very fast. Naturally such system will have five different types of users – HTML Coder, CSS Designer, JavaScript Coder, PHP Programmer and SQL Coder. HTML code can only be changed by HTML Coder and s/he can only view CSS and JavaScript Codes. CSS Coder can only change CSS code and can view HTML and JavaScript Codes. JavaScript Coder can only modify JavaScript Code and can view HTML/CSS/PHP codes. PHP Coder can only change PHP code but can view rest ALL other codes. SQL coder can change SQL code but can view only PHP code. And in the last there should be a Project Manager which will integrate all these components and generate web based application or website as per client requirements. I don’t know when this system will become reality but I will try to develop a demo of such system and make it live on this website as soon as my regular workload will permit for this.

Leave a Reply

Your email address will not be published. Required fields are marked *

Facebook Auto Publish Powered By : XYZScripts.com