Drupal Planet

Posts that are aggregated to the Drupal Planet feed.

Making Wordpress and Drupal configuration files easier for development and production environments

Simplifying Wordpress and Drupal configurationAt last year's Drupalcon in Denver there was an excellent session called Delivering Drupal.  It had to do with the oftentimes painful process of deploying a website to web servers.

Don't get burned by PayPal disputes and digital goods (especially with Drupal + Ubercart)

Recently, a user filed a dispute against one of my digital subscription-based websites.  Having never dealt with a PayPal dispute before, I went in not knowing what to expect.  I examined the user's account in Ubercart and they had definitely paid via PayPal and the IPN information was sent back to the site that the order had been successful.  The user had also received the digital subscriber role.  PayPal contacted me noting the user had filed a dispute against me that they did not receive the product.  However, I could see that they very clearly had.

Remove the Media6degrees tracking link from the AddToAny Drupal Module

I noticed this happening while I was getting a site ready with the AddToAny Drupal module.  Pages would randomly hang in my dev environment and it was trying to contact Media6degrees.  After some Googling I found this was a third party tracking cookie being installed with the AddToAny module.  To disable it in Drupal 7, go to the modules page and click "Configure" next to AddToAny.  Under additional options near the bottom, paste this:

Using Drupal Webform submission data

Redirect webform submissions to a dynamic URL in Drupal 6

If you need a way to redirect webform submissions to a dynamic URL in Drupal 6, using the Webform PHP module can work well with Webform 3.x.  I recommend only using post processing conditionals on select fields if possible with Webform PHP since you need to enable the permission to "use PHP for additional processing" for users who submit webforms (typically anonymous).

Here's the process:

JQuery Dropdown Menu Styling in Drupal

DrupalSN posted a nice guide to styling exposed View dropdown menus with a JQuery plugin and some stylish CSS.  The guide there worked perfectly except for the step where he hid the submit button.  I changed this:

.views-exposed-form label,
.jquery_dropdown_page .views-exposed-form .form-submit {
  display: none;
}

to this:

Using a nid argument in a block view in Drupal 6

I had a bit of an issue with this since I'm used to using arguments on view pages.  To use node id as an argument with a block view you cannot simple use the "Hide view / Page not found (404)" under "Action to take if argument is not present".  Instead, do the following:

International Orders with Authorize.net

I recently ran into an issue where international customers could not checkout properly in Ubercart, a fully featured Drupal ecommerce solution.  I was using Authorize.net as the credit card processer.  To allow international customers to be verified with Authorize.net, do the following in your merchant account:

CCK field as a view argument in Drupal 6

I found this trick during the development of Acton Institute's new Drupal-ized website.  I wanted to be able to list out other articles by the same author and show it on a sidebar.  Here's the setup:

  • Article authors are CCK nodereference fields to a separate author content type

How does one then construct a view that thinks the author is a CCK field and not the actual node's author?  It's a lot easier than I thought.  The only thing you need to have in your view is an argument with a little PHP magic.

Syndicate content