I don't know if this might cause problems later and/or in other places, but I thought I would post it anyway. I usually move the module and theme directory from commons over to sites/all. I have to move this file back to the commons profile in order to complete installation.

CommentFileSizeAuthor
#5 1912164.commons.no_hardcode_path.patch547 bytesjpontani
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

ezra-g’s picture

Status: Active » Postponed (maintainer needs more info)

Can you describe how to reproduce this error?

Topcheese’s picture

Status: Active » Postponed (maintainer needs more info)

Yes, what I do is remove the modules and theme directory from the commons profile and place them under the sites/all directory. I then create a directory under the sites/all/modules directory named commons to place the commons modules.

I run the install and the process stops at that error until I moved that file back. Here is the complete error.
Fatal error: require_once(): Failed opening required 'profiles/commons/themes/contrib/commons_origins/commons_origins.palettes.inc' (include_path='.;\xampp\php\PEAR') in C:\xampp\htdocs\profiles\commons\commons.profile on line 160

Edit: My mistake, I forgot that what I did was edit the path in commons.profile, and not move the file back.

ezra-g’s picture

Status: Postponed (maintainer needs more info) » Active

So to confirm you only get this error when you rearrange the filesystem?

Topcheese’s picture

Status: Postponed (maintainer needs more info) » Active

Probably so as that is the only way that I have been installing it from day one.

Edit: Well, not the only way, but it has been the main way that I install it to test out for multi-site.

jpontani’s picture

Status: Active » Needs review
FileSize
547 bytes

Attached a patch that uses the drupal_get_path function to find the path to the commons_origins theme without having to hardcode it.

ezra-g’s picture

Thanks, jpontani. Have you tested this patch?

IIRC, I didn't use drupal_get_path() because the theme isn't enabled at that point in the installer.

jpontani’s picture

I tested it once and it worked, I'm about to test it again right now as I test some other stuff that I needed a fresh install for.

jpontani’s picture

Just ran it again and it worked for me. The theme is already in the system registry before it even gets to that step so the drupal_get_path will return a valid path.

ezra-g’s picture

Status: Needs review » Reviewed & tested by the community

Great - Seems RTBC then :).

jpontani’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.