UML diagrams of WordPress

I donΒ΄t know any sequence diagram for WordPress but if you decide to built them yourself (which would be appreciated πŸ™‚ ) you may get some inspiration from these sequence diagrams created for Drupal

Trying to get property of non-object β€œ wordpress ”

It looks like the $args passed to the function is not an object for some reason. I can’t see the origin of this problem but for a quick solution, you can add $args = (object) $args; before the first time you use $args, here on line 44 Also, as commented by toscho, dropdown_menu() is not … Read more

Same taxonomy for different object types

Those are different object types that belong to different tables and hence can have same primary key ID. –> Even though these are different types, all are being stored in one table i.e. wp_posts with post_type = the different types. Check the table structure for clarity. So there won’t be any same ID conflict. if … Read more

Extending the WP_Widget_Text class

Think about it, why would WordPress do anything just because you have defined additional class? It’s not magic (neither magical magic or code driven magic). The text widget doesn’t appear simply because class exists. When WordPress loads it runs wp_widgets_init(), which executes register_widget(‘WP_Widget_Text’). So technically you cannot tell it to use different class. What you … Read more

Load classes using spl_autoload_register

Right, to answer my own stupidity. spl_autoload_register is called when you instantiate a class. Moving new water(); from file water.php to file test.php solves the problem. The test.php should then look like this: <?php /* Plugin Name: test Plugin URI: test Description: Version: 1.0 Author: test Author URI: test */ class test_main { public function … Read more

Adding the hook ‘vc_before_init’ inside a object

I found the solution… First I thought the problem had something to do with wrapping the hook inside a class.. But after some more testing (sometimes you need to take a step back), it appears the hook vc_before_init has already fired on the init hook with the (default) priority of 10… My current theme (Salient) … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)