Submitted by ygerasimov on Fri, 07/25/2014 - 13:41
Today I have had very interesting case with drupal forms having #ajax buttons. One form was working but the other didn't. After some debugging on ajax.js file I have found out that ajax submit buttoms behaviors being attached to forms by id so it is critical that different buttons have different id's. And in my case I have named submit buttons the same name $form['submit'] and in this way they had same id "form-submit". So in order to avoid that only thing you need is to make keys of submit elements in form to be different and then box ajax submission behaviors work as expected.
Submitted by ygerasimov on Mon, 05/19/2014 - 22:40
I have discovered very very nasty bug lately. When you export the panels page and it has taxonomy argument. Settings of argument do have machine name of the taxonomy vocabulary but it ties up to vocabulary id. This means that your panels page can break pretty easy in case you will happen to have your exported vocabulary to have different id. This may happen pretty often if you use features extensively for example when develop project in 'code-driven' way.
Drupal.org ticket https://drupal.org/node/2270505
Submitted by ygerasimov on Mon, 05/12/2014 - 10:47
Devel is a great module that provides a lot of helper funcitons to debug your code. One of them I have discovered lately is ddebug_backtrace().
It gives very nicely formatted backtrace as a message. Great help for development!
Submitted by ygerasimov on Mon, 12/30/2013 - 15:14
I am using vagrant box for developing the project on Symfony (puphpet.com). Locally my webroot files folder mounted at /home/ygerasimov/vagrant/puphpet/puphpet.
In order to debug the project in NetBeans we need to set up folders mapping:
Server path: /var/www/puphpet -- this is folder on the vagrant box where my site is
Project path: /home/ygerasimov/vagrant/puphpet/puphpet -- this is where project folder is mounted on my local machine (host)
Submitted by ygerasimov on Thu, 12/26/2013 - 10:54
Current project I am working on has user profiles using profile2 module. So it is pretty common task to replace all links/references on the site with user's proper name from Profile instead of his drupal username.
This is really easy to achieve using hook_username_alter()
Submitted by ygerasimov on Thu, 12/05/2013 - 13:23
While working on creating Vagrant profile for one of our projects that requires CentOS I have found out that most of puppet drush recepies use drush debian package that of course is not available on CentOS.
The workaround is to use https://drupal.org/project/puppet-drush. The snippets are:
In Puppetfile (I am using http://librarian-puppet.com/)
Submitted by ygerasimov on Tue, 02/26/2013 - 23:12
Submitted by ygerasimov on Wed, 09/12/2012 - 14:00
We all know that Symfony is already in the core of Drupal 8 but how it works and how both systems work? Not that many people understand fully this integration. Me neither but I would like to pubilsh my research notes about how Drupal 8 works now. Surely this material is based on the snapshot of beginning September and I really hope that more things will happen so this information is relevant only for some time.
I don't have any real life experience of the building projects with Symfony so my knowledge is very close to majority of drupal developers.
So lets start.
Submitted by ygerasimov on Wed, 08/01/2012 - 14:24
I would like to announce fifth DrupalCamp Kyiv. Official website of the event is http://camp12.drupal.ua/en. Twitter @drupalcampkyiv #dckyiv12
Camp will be held on 14-15 September 2012 at i-Klass education center that is located in the spectacular part of old Kiev in front of Pechersk Lavra
Submitted by ygerasimov on Fri, 06/01/2012 - 13:11
Services module is a great tool for exposing API's of your website to other applications.
When we work with Services module most of of the changes can be done only in code. But sometimes clients ask to have configurable interface for GET calls we expose. For example client needs some "export" call for his another application that imports data from our site. This is where Services Views module can play its very nice role.