Hi, I've got some problems when I want to create a custom page.

When I choose a layout to the page, Drupal send me this error:

warning: realpath() [function.realpath]: Unable to access /var/www/vhosts/my_domain.com/httpdocs/temp/sites/default/files/sites/all/modules/panels/plugins/layouts/flexible/flexible.css in /var/www/vhosts/my_domain.com/httpdocs/temp/includes/file.inc on line 182.

I try with all layouts (flexible, 1 column, ...) and the error is the same.

I use this modules:

* Chaos tools version 6.x-1.8
* Panels version 6.x-3.8

In "configuration site" > "file system" I have this parameters:

- file system path: sites/default/files
- temp path: sites/default/files/tmp
- Public file system
- Transliterate file names during upload.
- Lowercase transliterated file names

Can you help me, please?

PD. Sorry for my english!

Comments

franxo’s picture

Assigned: franxo » Unassigned
franxo’s picture

Component: Page Manager » Plugins system
merlinofchaos’s picture

This is weird. IT should not be looking for files here: "/sites/default/files/sites/all/modules/" -- it's repeating sites.

The only way I can think this would happen is if some thing you are running is changing the current working directory to the files directory. That would break a LOT of things though. But there is something deeply wrong for your system to be doing that, and I don't have any good suggestions.

Doublecheck all of your contrib modules and particularly any custom code you're running, especially if it integrates with some 3rd party PHP software.

franxo’s picture

Thanks for reply, merlinofchaos

Yes, it's weird.

I will follow your advice and doublecheck the modules that i've installed.

Thanks!

franxo’s picture

Hi, another time

I check (disabling and enabling) the modules i've instaled and the error is here again.
I change the "files directory" too, now is "sites/panelar/files".

I can try to debug the error, and I print all sources in function file_check_location (from file.inc) with an "echo":

function file_check_location($source, $directory = '') {
  echo $source."<br>";
  $check = realpath($source);
....

This is the output in website:

sites/all/modules/panels/plugins/layouts/flexible/flexible.css
sites/all/modules/panels/plugins/layouts/flexible/flexible.css
sites/panelar/files/sites/all/modules/panels/plugins/layouts/flexible/flexible.css
sites/panelar/files/ctools/css/4f40b9205e91cd79dce176362ee2f73d.css
css
css
sites/panelar/files/css
css
css
sites/panelar/files/css
languages
languages
sites/panelar/files/languages
js
js
sites/panelar/files/js
languages
languages
sites/panelar/files/languages
languages
languages
sites/panelar/files/languages
js
js
sites/panelar/files/js

The 2 first results are the correct flexible.css, but the 3th result is wrong, the rest of the results are ok.

A few questions:

- Do you know why flexible.css is included three times?
- My web structure is "header", "page" and "footer" that means the "footer" is the problem?
- Or the problem is the third panel that shows the site?

- Do you know what is/are the file/s that calls this function (file_check_location (from file.inc)) to include flexible.css file?

Thanks for all !

nubeli’s picture

I got the same messed up filepath and error. But only when I switched my client's site from one server to another. I suspected it had something to do with the server setup, but I am not sure at this point.

An e.g:

warning: realpath() [function.realpath]: Unable to access /usr/www/example.com/html/ctools/css in /usr/www/example.com/html/includes/file.inc on line 182.