As I've said before in my custom views filter handlers tutorial, views is amazing. Today I was writing a custom style plugin. I got the plugin to show up in the list of available formats, but whenever I saved the form, it wouldn't stick.
Google Analytics Module Settings
Drupal's Google Analytics Module is great. There are a few settings though that I recently found out you'll want to pay closer attention to. First is the "Pages" section of the configuration form, which allows you to only include/exclude Google Analytics tracking code on certain pages. The default settings are to exclude the code on the following pages.
What is #attached
I've been doing a lot more Behat testing recently. As my tests have gotten more complex, I've discovered that it was only a matter of "luck" that my earlier tests were properly cleaning up after themselves. What I mean, is that during my tests I fill out and submit a node form, checking that I successfully created it and that the appropriate users can see it. After each scenario you want to clean up any data that was created so you can run the test again and get the same result.
This is another post in my challenge to learn something new every day and then share that in a blog post.
This is fairly simple, but even though I'm comfortable with regular expressions, I was not familiar with the "?:" syntax (aka: question mark colon). I was working on some Behat tests using the MinkExtension, and this is used fairly often in the code
This was actually a couple weeks ago, but it is still fresh enough in my memory that I find it interesting and therefore worth sharing.
I had a Django Model that looked something like this:
This is a quick one that I learned from a co-worker. He was in the MySQL shell and instead of ending his query with a semi-colon, like I normally use, he used
\G. The results are interesting, instead of results showing in rows with the fields as columns, results are displayed vertically. Each record is separated by a row number and each field is on a newline with the field name.
"Normal" Query Syntax
SELECT * FROM `actions` LIMIT 3;
It's always been my motto to never stop learning. I also think it is important to share what you've learned with others. I don't think this could be more important then it is as a developer.
Joining me for our 14th ToadCast is Chris Trahey where we talk about doing what is right for your clients and the benefits of developers as technical sales. We also discuss notification overload, the anxiety surrounding a desire to know everything, and managing your todo list.