File: fwphp/glomodul/blog/msgmkd/altervista012.txt

Recommend this page to a friend!
  Classes of Slavko Srakocic  >  B12 PHP FW  >  fwphp/glomodul/blog/msgmkd/altervista012.txt  >  Download  
File: fwphp/glomodul/blog/msgmkd/altervista012.txt
Role: Documentation
Content type: text/plain
Description: Documentation
Class: B12 PHP FW
Manage database records with a PDO CRUD interface
Author: By
Last change: ver 7.0.1 mnu, msg, mkd FUNCTIONAL namespaces, CRUD PDO trait, pretty URL-s
Date: 1 month ago
Size: 4,343 bytes


Class file image Download
## 12. PHP menu & CRUD code skeleton comparison
Revised november 2019. My articles before this are not needed to use B12phpfw version 6. - just download (there are also many learning examples).

During winter 2019/2020 year (much to late because I tested lot what others did) I made Version 6. of **menu and CRUD PHP code skeleton (own framework named "B12phpfw")** - core code is less than 50 kB.     
I also made posts module **"Msg"** with posts edited with WYSIWYG Markdown SimpleMDE editor (or HTML WYSIWYG Sumernote editor or ... any editor you wish). Msg module is based on B12phpfw, also very small code.      
<br />
B12phpfw code skeleton and Msg application based on B12phpfw  are minimal PHP code to learn (medium knowlege) PHP !
<br />
Why ?  I do not like proposed solutions in  in best php frameworks (Laravel, Simfony, Yii...) and learning sources (internet, books). I think that eg module invoice php code should be in own folder like Oracle Forms form invoice.fmb (not all forms/reports in 3 folders: M, V, C). I think that should be simple/fast/professional :
**globals**, routing, dispaching, classes loading , web rich text editing - it is why I wasted many hours coding my B12phpfw (huge time wasting which should do software authors, not sw users-programers like me).      

Why I do not like proposed solutions and what I did to (I hope) improve them. <span style="color:red;">Red colored features are main reasons for B12phpfw, but I improved also other features.</span> :      

### Compared B12phpfw Msg (blog) module and TraversyMVC blog module and Mini3 module URLs Youtube songs adresses
TraversyMVC (has video) and Mini3 are simplified, with some (many?) differences Laravel, Simfony, Yii... B12phpfw is much more different - see red colored features.

|                                    Feature                                         |                           B12phpfw                                |        TraversyMVC and Mini3        |
| ----------------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------ |
|  1.  <span style="color:red;">**Modules in own folder** like Oracle Forms .fmb</span> |  has - it is main reason for B12phpfw !     |   has not like Mini3 -  all forms/reports in 3 folders: M, V, C |
|  2.  **Name spaced** classes (functional name spacing)  |   has   |   has not -  no functional, no positional (paths)  name spacing, **Mini3 MVC PHP fw** which is in my opinion better than TraversyMVC :  has name spaced classes|
|  3.  **Number of folders** (my opinion)     |  optimal      |  to many like Mini3 |
|  4.  **Minimal PHP code** to learn (medium) PHP  (my opinion) |  optimal (but we could add additional code) |  good but not enough like Mini3 eg see WYSIWYG, globals...|
|  5.  **Functional methods, attr. etc naming** (my opinion)     |  good      |  could be better |
|  6.  <span style="color:red;">**Global classes, methods etc** (my opinion) </span> |  good      |  bad like Mini3 |
|  7.  (Posts edited with any) **WYSIWYG editor** |  has      |  has not like Mini3 |
|  8.  Home_ctr or Home_mdl CRUD layer methods <span style="color:red;">**do not know for underlaying Db_allsites layer PDO** methods, MySql, Oracle...</span> |  has much improved |  has not like  Mini3 |
|  9.  **OOP** |  has      |  has like Mini3 |
| 10.  namespaces (own **PSR-4 (or Composer's) autoloading** classes scripts) |  improved  |  has not, Mini3 has|
| 11.  <span style="color:red;">**All scripts are included**</span> (ee no http jumps except some jumps in other module) |  has      |  has not, Mini3 has, B12phpfw took it from Mini3|
| 12.  **jQuery** only for Bootstrap 5 |  yes  |  yes, Mini3 has own CSS |
| 13.  no **AJAX**, no **JSON** |  yes  |  yes, Mini3 has basic jQuery AJAX explained |
| 14.  server side **validation** |  has |  has like Mini3 |
| 15. **authentification** (log in / out) |  has |  has, Mini3 has not|
| 16. **authorization** (only logged in users may execute some code ee CRUD code...) |  has |  has, Mini3 has not|
| 17. <span style="color:red;">**Own debugging** very simple and useful</span> : msg in pre tag or popup JS msg). **xdebug** also helps. |  has |  has not like Mini3 |
For more information send a message to info at phpclasses dot org.