The module appears to be in complete working order other than on the actual Control Panel page - I'm missing all the images (with the images being replaced by links) resulting in duplicated links.

I can access the control panel images by typing their full URLs, so they are up...

Any ideas?

CommentFileSizeAuthor
#17 controlpanel.path.patch1.66 KBmarkus_petrux

Comments

dreed47’s picture

A fix was commited yesterday that may be related to your problem. Please download the latest 4.7 control panel release and retest.

ALT83’s picture

So far no luck,

How would I go about completely uninstalling the module, (as it appears to have logged/cached my settings) so that I can try a clean reinstall...

Cheers

Alex

dreed47’s picture

I can't think of anything that is being cached that would affect the Control Panel module. If you really want to you can empty the "cache" table in your database and you could also remove any variable starting with "controlpanel" in the "variables" table in the database.

When you are viewing the page that's missing the icons can you view the page source and tell me what the path to the controlpanel image icons looks like?

ALT83’s picture

No luck Im afraid, the src is coming out as:

<div class="control-panel-item control-panel-icon-size-24x24"><a href="node/add"><span style="display:block;"><img src="/modules/controlpanel/images/24x24/control_panel_default.png" alt="create content" title="create content" /><br />create content</span></a></div>

For each of the control panel links.

The strange thing is those images load directly when copied into my browser bar...

This module isn't reliant on image module or anything else is it?

dreed47’s picture

I made a change to the code to use the newly introduced $base_path variable. If you want to test this change you'll need the latest Drupal core code from CVS HEAD, NOT the latest beta build.

ALT83’s picture

Status: Active » Fixed

Great der!

That worked (Drupal CVS + Control Panel CVS combo)

You're golden!

Cheers,

Alex

Patrick Nelson’s picture

Version: 4.7.x-1.x-dev » master
Status: Fixed » Active

This works fine except when you use URL aliases. What I mean is I have used aliases to change all the node/add/XXXX pages on my site to create/XXXX.

Then I created a Control Panel block and placed it in the content region for a page called create/events.

I get exactly the same error as reported in this post (missing all the images (with the images being replaced by links) resulting in duplicated links) and this error reported in the log files:

Type - page not found
Location - /create/modules/controlpanel/images/48x48/node_add_flexinode-10.png
Referrer - http://www.vcommunity.org.uk/create/events
Message - create/modules/controlpanel/images/48x48/node_add_flexinode-10.png not found.

Using 4.7 HEAD in all cases.

Sorry if this post is actually a different bug - just let me know and I'll move it.

dreed47’s picture

Did you try renaming all your node_add_xxx.png images to create_xxx.png?

dreed47’s picture

Sorry, I read your posting too quick. I don't think the image file name is the issue. Looks like it's prepending the "create" path in front of the image path. That would keep it from finding the images. I know you said you were using Drupal HEAD but as of what date? Are you using multi-site? What does your $base_url setting look line in your settings.php file?

Patrick Nelson’s picture

Der,

Thanks for your (last!) reply.

I'm using HEAD that is just about current - the only updates that I haven't applied are those where the only difference between my files and the current CVS HEAD ones are the changes from www.drupal.org to drupal.org.

Everything else is current.

Are you using multi-site?

No

What does your $base_url setting look line in your settings.php file?

$base_url = 'http://www.vcommunity.org.uk'; // NO trailing slash!

dreed47’s picture

The reason I ask about how old your version of HEAD is that the control Panel module uses a global variable called $base_path to resolve it's image file paths. This change was put into CVS on 1/29, AFTER beta 4 was released. As long as you have bootstrap.inc and common.inc files from AFTER 1/29 you should be ok.

Patrick Nelson’s picture

Hi der,

I've got bootstrap.inc 1.87 from 2/10 and common.inc 1.516 from 16/2

DexterMilo’s picture

I just installed this module (newest) on the newest version of Drupal HEAD.

The base_path does not seem to be setting the "/" (i.e. image paths are "modules/etc etc") but if I turn off clean urls the path is set correctly (i.e. ?q=).

If I print base_path in my template it prints "/"

If I go into the module and manually add . '/' . the images of course show.

Hope this helps!

Good luck,

Ryan

markus_petrux’s picture

I think the problem is $base_path is not declared as a global variable in function theme_controlpanel_panel_view().

OTH, you may want to use base_path() instead. It just returns $base_path.

HTH

markus_petrux’s picture

BTW, could you please add the $Id$ tag on top of the .module file? :-)

dreed47’s picture

Yep, no global declaration for $base_path. Thats one problem. There appears to be another problem with way I'm looking for the images files. I'll try to look at this later today.

markus_petrux’s picture

Status: Active » Needs review
StatusFileSize
new1.66 KB

Here's a patch that I believe it fixes this.

dreed47’s picture

Status: Needs review » Fixed

Yep, that's it. Patch looks good. It's applied and committed.

Thanks!

Anonymous’s picture

Status: Fixed » Closed (fixed)