News:

Looking for documentation? Take a look on our wiki

Main Menu

How to get new coders? document and explain

Started by maxispin, September 28, 2016, 05:42:31 AM

Previous topic - Next topic

maxispin

I found old VM 1 code with great way of explaining what is its purpose and what is happening. http://forum.virtuemart.net/index.php?topic=37397.0

Please consider sometimes explain noobies interested in coding what the code is aimed for. It helps others and grows the VM community.

VM 3.0.17.6 | VM 2.0.24c | VM 1.1.9

GJC Web Design

It is simply not possible to explain such basic concepts for an extension like this

the example u give is pure php .. you could google any one of those functions and find what they do

The code base is beautifully standard MVC with a few helpers thrown in .. once you understand how one Controller/Model/View works in VM you understand them all

The code is very clean, well formatted and is to some extent commented

You would do better to learn the basics of php and it functions
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

Milbo

The next problem that we use maybe 3 lines per step. We try to follow the rule, call important variables what they are, even it gets maybe a bit long. On the other hand, try to use for unimportant vars only shortcuts.

Actually the code is quite simpel.
The index.php in the root calls the joomla application, which calls due the "option=com_virtuemart" the index.php in the regarding folder. This is either components/com_virtuemart, or the almost the same just with a trailing administrator, /administrator/components/com_virtuemart.

The index.php there calls first the VmConfig and loads the vm environment. Then we call a controller in index.php/controllers. This controller has usually the same name as the view. A controller calls a task, which defaults to "function display". This calls the view and excecutes a view.html.php in the folder index.php/views/myview. And the file view.html.php calls the layouts.

That is a short description of a call in virtuemart.

But this gives you just a hook to understand where you could start to understand the process. But more important is to learn the vmdebug and vmTrace. We always search for writers http://docs.virtuemart.net/tutorials.html
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/