Rock the Drop has the single mission to make others' experiences with Drupal much simpler. As we continue to build custom Drupal sites, we encounter challenging situations that require REAL know-how with the cool blue drop. As our knowledge expands, so does yours.
Stick around... it only gets better.
We are also front- and back-end Drupal Themers, Developers and PHP coders; available for development in NYC and abroad with no limit on size and scope.

Error: Already Exists in Active Configuration

Received this error on "Business" theme after moving a site from standalone to multisite config in Drupal 8:

"... already exists in active configuration"

I don't think it matters which theme (or module ??) it was. Just the fact that I couldn't get a contributed theme to RE-install on my site. Even clearing cache and other tricks I've learned along the Drupal path... didn't work.

Drupal 8 - Override Base Theme CSS

Used to be that you could simply override a stylesheet by simply removing it from your .info file (Drupal 7).
Drupal 8 has an entire new set of rules for this. Stylesheets, by default, load because it's part of your base - makes sense. At least until you want to eliminate that stylesheet in favor of your own theme's styles.

In Drupal 8, you now have a concept of libraries... which basically tells Drupal which set of tools are required to build your site. Hidden deep (not really that deep) in this toolbox is a directive:


Drupal 8 Multisite - End Your Startup Confusion

In the previous versions, you could simply create the necessary directories ( and files/ for instance) in order to get Drupal to look for the proper config and files for the correct multisite currently requested in the browser.

In Drupal 8.2.6, there's a "required" sites.php file that must exist in order for any of this to work. In my opinion (I'm sure someone somewhere has the same opinion), this file should NOT be required... but it is. Let's look at an excerpt:

Drupal 8 Install Error - Important Links and Roles Disappear

Playing with a Drupal 8 install for the first time, I decided to just go the "grungy" route and do the minimal install. After all, I'm a DRUPAL Developer.. and I know the ins and outs of it. Not just a PHP Developer that supposedly knows everything...

Whatever, the nightmare started when I made that decision.

Attach an existing file to a node programmatically

 * Code that will enable attachment of a pre-existing file on the filesystem
 * to a node that requires it. 
function attach_file(&$node, $file_location, $lang = 'en') {
  global $doc_base_path;

  $file_location = str_replace('\\','/', $file_location);

  $actual_file = $doc_base_path . "/" . stripslashes($file_location);
  if (!file_exists($actual_file)) {
    print "**** FILE NOT FOUND ****\n";
    print $actual_file;
    print "^^^^ FILE NOT FOUND ^^^^\n";
  } else {

    print "File GOOD\n";
    print "Filesize: " . filesize($actual_file);

Import and Translate Drupal 7 Taxonomy Terms

But you'll never get those pesky entity titles !!

It'll take a bit of doing. And it took me sooo long to work out. Several modules will get you close... but not complete. Infact, I gotta revisit this post because I think it even depends on some detail in the order in which you do things. Perhaps tomorrow.

Here's the awesome Drupal module combination that I end up using:

Attach an Existing File to a Node... Programmatically

and the need to consider languages / translations.

Hi!! I'm excited 'cause I just spent another hour figuring out something that wasn't exactly rocket science... but a fairly obscure solution for my "special case".

killed my menu with hook_menu_alter

Then I couldn't access any admin pages. Meaning of course that I could not then clear my caches... INCLUDING the menu cache to restore it.

Truncating the database cache tables also did nothing to help.

Hindsight tells me I could have investigating rebuilding the registry... maybe.

What fixed it was simply running /update.php

Of course, it helps if you're logged in already as user 1 /admin. I couldn't even log out actually, because that access goes through the menu module as well.

Mess up your modules, Mess up your registry...

and mess up your Drupal site "permanently". Not Really.

I screwed up my Drupal project one day by copying my modules directory and forgetting to move it out of it's parent directory. Details are unimportant.

The point is, I cleared my cache and did a few other things and Drupal started looking for modules in a location that was unavailable. Needless to say (I hope needless anyway), the system and registry tables were out of sync with some of the modules.
Fixing (or so I thought) the registry table manually was unsuccessful.

line 2295 of C:\devstack\www\tourBuilder\includes\

variable_get - Provide a default.. OR ELSE!!

Warning: Invalid argument supplied for foreach() in form_type_checkboxes_value() (line 2295 of ...\includes\


Subscribe to RSS