1. Enable mediafront module ( nothing else - not youtube, osmplayer etc. )
2. Create field-collection field in content type
3. Click 'edit' to edit field instance

Results in blank page - log shows

Timestamp: 12/27/2012 04:18:41 PM
Error: TypeError: this._mainWindow.gBrowser is undefined
Source File: resource://unity/observer.js
Line: 80

4. Disable Mediafront module - everything works as expected!

I have run 'drush pm-update' to make sure I'm up to date

CommentFileSizeAuthor
#9 image-module-dependency-1875210.patch754 bytesEnjoyLife
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

drakythe’s picture

Priority: Major » Normal

You are talking about the Field Collection module, and not the Field Group module, correct?

If the above is right, I just tested this and was unable to replicate it using:
Drupal 7.18
Chaos Tools 7.x-1.2
Entity API 7.x-1.0
Field Collection 7.x-1.0-beta5
MediaFront 7.x-2.0-rc3

On a fresh D7 install.

I also did a bit of digging and I can't seem to locate a file by the name of 'observer.js' which is where your error came from. I ran a command line "find" against my whole site file structure and came up empty. Are you positive those are the only modules installed? Any more information you can provide would be helpful.

pangus’s picture

Title: Mediafront breaks field collection » Mediafront breaks field collection on Firefox

Yes, I'm talking about Field Collection, not Field Group.

I've downloaded Chrome and in Chrome everything works fine on that so it's a Firefox issue!

Incidentally, Chrome's a lot faster when loading local web pages; I may be converted.

Anyway, I'm using Firefox 17.0.1 on Ubuntu 12.10.

I've done a fresh D7 install only installing the necessary modules and confirming that my module versions match yours. I think the previous error message I gave was a red herring. I think this observer.js file is something Firefox uses for add-ons so I've disabled all extensions and add-ons. This seems to have cleared the clutter of warnings and errors. I'm now only left with 2.

The first...

Request URL: http://localhost/drupalClean/?q=admin/structure/types/manage/test-type/f...
Request Method:GET
Status Code:HTTP/1.0 500 Internal Server Error

Request Headers 19:05:25.000

User-Agent:Mozilla/5.0 (X11; Ubuntu; Linux i686; rv:17.0) Gecko/20100101 Firefox/17.0
Referer:http://localhost/drupalClean/?q=admin/structure/types/manage/test-type/f...
If-None-Match:"1357602846"
If-Modified-Since:Mon, 07 Jan 2013 23:54:06 +0000
Host:localhost
Connection:keep-alive
Cache-Control:max-age=0
Accept-Language:en-US,en;q=0.5
Accept-Encoding:gzip, deflate
Accept:text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8

Sent Cookie

SESS4de6b7f8633567762053f96f2f965092:jh97Zaw5u72CidUCyJmrRe4UMGdbotnVPsxrka4Rp7Q
SESS29af1facda0a866a687d5055f2fade2c:9eB-0cgtfpnAlhrXOP5X9vQAU7eTUgvxAovP8o1JzT0
has_js:1
Drupal.tableDrag.showWeight:0

Response Headers Δ897ms

X-Powered-By:PHP/5.4.6-1ubuntu1.1
Vary:Accept-Encoding
Server:Apache/2.2.22 (Ubuntu)
Last-Modified:Tue, 08 Jan 2013 00:10:47 +0000
Expires:Sun, 19 Nov 1978 05:00:00 GMT
Etag:"1357603847"
Date:Tue, 08 Jan 2013 00:10:47 GMT
Content-Type:text/html
Content-Length:20
Content-Encoding:gzip
Connection:close
Cache-Control:no-cache, must-revalidate, post-check=0, pre-check=0

The second...

[19:10:48.899] The character encoding of the HTML document was not declared. The document will render with garbled text in some browser configurations if the document contains characters from outside the US-ASCII range. The character encoding of the page must be declared in the document or in the transfer protocol. @ http://localhost/drupalClean/?q=admin/structure/types/manage/test-type/f...

drakythe’s picture

I just checked and my dev box is on ubuntu 12.04 LTS with Firefox 17.0.1 as well, still no errors.

From reading the errors you are getting, it almost looks like the server might not be configured correctly, or perhaps the db is corrupt? Do you have any other dev environments you spin up a test site on to verify the error is specific to your local machine? You might also check your logs to see if there is any further explanation. You can get more information on 500 errors here: http://www.thecpaneladmin.com/php-500-internal-server-errors/

pangus’s picture

Title: Mediafront breaks field collection on Firefox » Mediafront should have Image module dependency

I span up a test site on my shared host and got a much more useful error message...

Fatal error: Call to undefined function image_styles() in drupal/sites/all/modules/mediafront/mediafront.module on line 458

I generally do a minimal install so Image was disabled from the start. I enabled the image module and it works. I tried the same on my local machine and it works too!

So presumably Mediafront should have Image as a dependency.

Any suggestions as to why I don't get the useful error message when I run it locally? As you say, I guess the server isn't configured correctly. I'm an Ubuntu/Linux newby so i guess there's something I've missed. Even more mysteriously, the error shows up on both Chrome and Firefox when using my remote site.

drakythe’s picture

Glad you found the solution to your problem!

As to getting your local server to report errors correctly, I think this might help http://stackoverflow.com/questions/2687730/how-can-i-make-php-display-th...

pangus’s picture

Thanks very much! i'm getting the errors on my local server now.

So how does this work? Do I just leave this issue here and hope that a module developer picks it up and puts in the dependency? Or should I close this and create a new neater issue without most of the above that no one really needs to read?

drakythe’s picture

Nah, changing the name of this issue was enough. If you like you could always edit the first post with a note to say error explanation in is reply #4.

If you are feeling really ambitious, you could always roll a patch to fix the issue yourself. https://drupal.org/node/707484 is how your do that.

EnjoyLife’s picture

Version: 7.x-2.0-rc3 » 7.x-2.x-dev
Status: Active » Needs review

This fixes the Image module dependency issue. I just set Image as a dependency in the .info file. However, I'm new to patches and the formatting may be incorrect in the patch.

EnjoyLife’s picture

Patch attached.