Where is the include coming from?
The includes of the system map out the dependencies of the system, which files depend on which, which subsystem depends on which. When working with a system, it’s always useful to map out the dependencies before hand.
Here are some examples:
WordPress 2.2.1
http://wordpress.org
MediaWiki 1.12
http://www.mediawiki.org/
phpBB 3.0
http://www.phpbb.com/
phpMyAdmin 2.9.1.1
http://www.phpmyadmin.net/
Symfony 1.1
http://www.symfony-project.org/
Zend Framework 1.5.2
http://framework.zend.com/
CakePHP
http://www.cakephp.org/
CodeIgniter
http://codeigniter.com/
Seagull Framework
http://seagullproject.org/
(Demian Turner)
[...] Alguém imaginou e postou aqui. [...]
Cairo’sBlog
August 4, 2008 at 12:40 am
Thanks for you blog – always very interesting!
I was working on include graphs to show my team
the mess they created. Wrote a Java program for this.
What tool are you using for the analysis and creation
of the graphs shown here?
Regards – Martin
Martin
August 4, 2008 at 6:36 am
I’m using Inclued and Graphviz.
Federico
August 4, 2008 at 9:21 am
Thanks a lot!
Very interesting blog though.
Alexander Schmidt
August 4, 2008 at 11:48 am
Could you post a CodeIgniter map too ?
Mihai Georgescu
August 4, 2008 at 11:59 am
Nice post. Trying to follow all the includes and requires is not an easy task. This is a good resource for understanding how the apps work. Thanks for the post.
Scott Spear
August 4, 2008 at 1:33 pm
Thanks for the comments :)
@Mihai: Yes, I’ll add it tonight.
Federico
August 4, 2008 at 1:38 pm
Nice blog post. Useful. Can you be troubled to do drupal? ;)
Lei Teh
August 4, 2008 at 2:11 pm
@Lei: Added to my list.
Federico
August 4, 2008 at 2:12 pm
Drupal and CodeIgniter would be great! ++++
Blake
August 4, 2008 at 4:26 pm
Excellent work.
jesusvld
August 4, 2008 at 6:01 pm
Are the applications you’re running the frameworks against equivalent in functionality? I see some files included on the ZF app that may or may not be included in standard applications. It’d be good to run these graphs such that similar functionality is compared.
Matthew Weier O'Phinney
August 4, 2008 at 6:16 pm
Is there a chance for you to associate the execution time of each file? (using the profiling of XDebug)
JoaoJose
August 4, 2008 at 7:43 pm
[...] no blog do Cairo, um cara fez um mapa de todos os arquivos importados pelos métodos include e require do PHP. Ele fez um teste com várias aplicações, confira abaixo o do CakePHP. Gráfico de dependências [...]
Gráfico de includes
August 4, 2008 at 8:24 pm
@Matthew
You are right, ZF includes more functionality. That’s because I’m using the graph from this post. The idea was to show the workflow of the framework. But yes, I guess I can add more functionality to CakePHP and Symfony, and while I’m at it, upgrade Symfony to version 1.2.
Federico
August 5, 2008 at 12:39 am
I second the Drupal (6.x?) map :)
Great article!
Shawn
August 5, 2008 at 2:15 am
Great! Very usefull
But I’m confusing about: phpMyAdmin 5.0.45
Latest stable version: phpMyAdmin 2.11.8.1
handyblogger
August 5, 2008 at 5:29 am
Great work!
does anybody know if there is a windows version for the Inclued library ?
Gjergji
August 5, 2008 at 7:22 am
Not that I know of.
@handyblogger: Well spotted, thanks :)
Federico
August 5, 2008 at 8:30 am
@Federico Thank you for adding CodeIgniter ;) Looks great.
Mihai Georgescu
August 5, 2008 at 12:56 pm
[...] that could ease a bit the decision is this comparison made here. It;s based on the number of include calls made by the boot-up of the framework. Some examples can [...]
Care2x Devlopment Blog
August 5, 2008 at 9:32 pm
[...] Includes of the system map out of the dependencies of the system. [ Here [...]
Everyone should get a 2nd chance
August 6, 2008 at 6:54 am
I think every framework and CMS should hire to you make one of these for people new to the systems.
This makes it so easy to trace.
David
August 6, 2008 at 6:27 pm
Awesome work!
Its interesting to consider if there can be any valuable info gleaned just by comparing the thumbnails.
WordPress & Cake have very flat, slim organizations.
Zend Framework has a very deep and wide org.
Codeigniter, Symfony & phpBB organiztions are slim and shallow.
Brad
August 6, 2008 at 7:57 pm
[...] Блог PHP::Impact опубликовал очень интересную подборку диаграмм. [...]
Диаграммы взаимосвязей
August 7, 2008 at 8:43 am
Seems like Zend Framework is the most decoupled of the lot?
Kenny Lee
August 8, 2008 at 5:03 am
[...] PHP::Impact ( [str Blog] ) map for all the includes in CodeIgniter from the time the framework [...]
Lasercake
August 8, 2008 at 5:48 am
please make a graph for kohanaphp!
Dude
August 8, 2008 at 6:47 pm
@Kenny Lee: That’s right.
@Dude: If I’m not wrong, Kohana is a fork of CI, right? I’m guessing the designs are similar.
Federico
August 9, 2008 at 9:23 am
[...] a tightly-coupled framework (you can get a feel for this by viewing Federico Cargnelutti’s dependency graphs for some common PHP [...]
Frameworks vs. Libraries in PHP | David Otton
August 9, 2008 at 7:20 pm
kohana is no longer a fork of ci. it has been completely rewritten in 2.0
Dude
August 9, 2008 at 11:36 pm
[...] Where is the include coming from? [...]
rpsblog.com
August 10, 2008 at 10:35 pm
@Dude: I’ve just finished browsing Kohana’s source code and you are right, I didn’t find any traces of CI.
Federico
August 10, 2008 at 11:34 pm
[...] Where is the include coming from? Shows the module dependencies for different open-source projects – very eye-opening. [...]
GrantPalin.com
August 11, 2008 at 4:04 am
wow good job!
sibirya
August 11, 2008 at 12:36 pm
Link to Image for symfony 1.1 doesn´t work.
Can you write a little tutorial how to use Inclued and Graphviz ?
good job!
Omar
August 11, 2008 at 5:16 pm
Very interesting. Would it be possible to generate graphs for CMS like Joomla, Drupal and Typo3?
Pascal
August 13, 2008 at 1:15 am
[...] Interessante questo post [...]
Digital Design News
August 14, 2008 at 8:00 am
Thanks for the mention of Inclued, what a great way to get a snapshot of the development style of a PHP project. Here’s the depgraph for Seagull, http://seagullfiles.phpkitchen.com/seagull_depgraph.png, the shape seems closest to symfony at first glance.
I think another really important metric, on the subject of framework file structures, is number of included files. This Seagull project has 63, which is mostly dependent on the number of blocks loaded, and caching being disabled. A much simpler project I have in zpf 1.5 loads 89 files but feels much slower. Totally agreed that Zend’s “use at will” approach with minimal coupling is the way to go.
Demian Turner
August 14, 2008 at 6:16 pm
Very interesting, thanks Demian :)
Federico
August 14, 2008 at 11:12 pm
could you post joomla 1.5 map as well .. thanks :D
adwin
August 16, 2008 at 5:56 am
[...] diese ihre Dateien, wie sind sie aufgebaut. Es gibt einige nette Grafiken, auch zum Zend Framework. -> Where the Include coming From [...]
Yangtze
August 18, 2008 at 11:59 am
The Magento (ecommerce) includes diagram should be added to the list. They’re fairly hideous. I didn’t create the view, but you can grab it from here:
http://example.preinheimer.com/dump/magento.png
(Image size: 5.5MB. Right click and select Save As…)
Scott
August 23, 2008 at 5:41 am
Thanks Scott. There’s a lot going on there. I’m sure Magento users are going to find it useful.
Federico
August 23, 2008 at 11:48 am
Thanks you for your article!
I just wonder how did you build these include scheme?
Did you use any special tools for that?
grakoff
August 28, 2008 at 4:23 pm
Yes, Inclued:
http://pecl.php.net/package/inclued
http://t3.dotgnu.info/blog/tags/inclued/
And Graphviz:
http://www.graphviz.org/
Federico
August 28, 2008 at 7:32 pm
Hi Frederico, thanks for the article – very insightfull.
I’d like to have a closer look at the diagrams for ZF and Symphony but the links doesn’t seem to work. Is that something there might be a solution to because I’d really like to investigate them further :)
Kind regards
Christian Aarø Rasmussen
Christian Aarø Rasmussen
August 30, 2008 at 3:58 pm
It seems to be working fine now. WordPress stores all the images in Amazon’s S3, so there’s not much I can do about it.
Federico
August 30, 2008 at 6:06 pm
This is awesome! :P
Napolux
September 1, 2008 at 6:22 pm
[...] questi grafici che mostrano tutti gli “include” e i “require” della versione 2.2.1 di WordPress e di altri [...]
Napolux
September 3, 2008 at 11:30 am
[...] Dependencies maps for popular PHP-based software – if you ever wanted to see how a certain file is used in WordPress, that’s a great way to finally find out [...]
Perfect Blogger
September 21, 2008 at 10:52 am
CodeIgniter looks “light”.
As there wasn’t any graph for Joomla yet, I decided to generated one: http://www.joomlavue.com/blog/14-joomla-files-includes
It is based on Joomla 1.5.7
eddy
October 3, 2008 at 5:54 pm
Thanks eddy, I’ll add it to the post.
Federico
October 4, 2008 at 12:05 am
[...] of PHP::Impact ( [str Blog] ), here’s a detailed “map” of the CodeIgniter system’s file structure when [...]
Good Idea, Bad Idea
October 24, 2008 at 12:32 am
Cool! but I really need the OSCommerce’s graph!!
Can someone help?
Thanks
Johnny
December 15, 2008 at 4:39 am
[...] Where is the include coming from? [...]
Top Posts 2008
January 10, 2009 at 2:29 pm
[...] arquitectura y funcionamiento son muy simples y es muy liviano para el servidor. Les invito a que comparen su flujo de código contra los de otros frameworks. 12 de February de 2009 a las 07:07 pm — Enlace permanente a esta entrada [...]
Actualización de CodeIgniter — Sanbor
February 13, 2009 at 4:45 am
[...] Dépendance graphique d’un “Hello World” sur Zend Framework (gif). À comparer avec d’autres frameworks php [...]
iWeb Blog
March 26, 2009 at 12:00 pm
@Johnny A little late but I just blogged about the Inclued extension and put a graph of osCommerce.
Then I noticed this lovely article thanks to @tychay :)
Heres the link: http://short.ie/pecl-inclued
Che
April 27, 2009 at 5:28 pm
Excellent! Handy info which will give better understanding of Frameworks.. This is missing even in Framework docs.. I wonder how u get all these..?
dinesh
July 1, 2009 at 6:30 am