Pictures for multisite is broken because each picture is saved inside a site's site.com local files directory, and the only way to share these folders is to symlink them. Rather than doing that, is it possible to use URL Replace to rewrite the user picture directory to an all site accessible parent directory, such as public_html/pictures? Thanks.

CommentFileSizeAuthor
#3 Untitled.jpg14.13 KBFlying Drupalist

Comments

fgm’s picture

Indeed. This is a most significant use of the module. Typically:

  • choose a prefix you'll always apply to the HREF and SRC attributes you'll want to rewrite, like "/images"
  • configure url_replace_filter to replace /images/ with http://www.example.com/public_html/pictures/
  • insert images as <img src="/images/foo.png" alt="some explanation" />
  • they'll be rewritten to access the absolute URL you defined, like public_html/pictures

If this answers your question, please set to the issue status to "fixed"

fgm’s picture

Assigned: Unassigned » fgm
Status: Active » Postponed (maintainer needs more info)

Forgot to set status

Flying Drupalist’s picture

StatusFileSize
new14.13 KB

Hi, thanks!

Some problems I have: the replace filter table has only 1 column, different from what I see in the screenshot. I attached what I see.

Also, since pictures (I mean profile pictures/avatars), are part of profile, would editing an input format really help? Thanks.

fgm’s picture

Yes, this is a bug fixed by the patch in #330640: Module configuration screen is not themed. It is only cosmetic anyway. Without the patch, the left column is on rows 1, 3, 5 and the right column is on rows 2, 4, 6. You can apply the patch, or just not worry, and set the left element on row one, and the right on row two, and it works just fine.

Or you can apply the patch, or just paste this at the end of the module, and clear cache:

function url_replace_filter_theme() {
  return array(
    'url_replace_filter_settings_form' => array(
      'arguments' => array('form' => NULL),
    ),
  );
}
Flying Drupalist’s picture

Thank you, now that I understand more about this module, I don't think it works for user profiles though.

fgm’s picture

Actually no: the default textarea fields in profile.module do not have an input format, so no filter can apply to them : they are always submitted to check_plain() during the render process (see includes/form.inc#theme_textarea).

If you want to use advanced content for profiles, you might want to check http://drupal.org/project/profileplus and/or http://drupal.org/project/content_profile

fgm’s picture

Status: Postponed (maintainer needs more info) » Fixed

No answer from requester in two weeks. Assuming issue fixed.

Status: Fixed » Closed (fixed)

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

ShadowMonster’s picture

Category: support » bug

On 6.19 (don't know if on previous also) after fresh install this module from dev (where path is applied) this problem is not fix. Maybe cause template but I don't think so - I use Pixture reloaded

warning: Parameter 1 to theme_url_replace_filter_settings_form() expected to be a reference, value given in /public_html/includes/theme.inc on line 656.

PHP 5.3 compatibility issue

fgm’s picture

Status: Closed (fixed) » Postponed (maintainer needs more info)

I suspect you are using PHP 5.3, aren't you ?

ShadowMonster’s picture

Yep. I alredy know that this is PHP 5.3 compatibility issue just for let other know also.

fgm’s picture

Assigned: fgm » Unassigned

Module maintainer is now Mathiaz.sk; unassigning myself.

fgm’s picture

Issue summary: View changes
Status: Postponed (maintainer needs more info) » Fixed

This now works even on 5.4.

Status: Fixed » Closed (fixed)

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