开发者

Drupal outputs the image tag as the title and alt of the image's wrapper

开发者 https://www.devze.com 2023-01-29 18:13 出处:网络
Something really weird is going on with a Drupal 6 project I\'ve \"inherited\". In a few of the views it there\'s a bunch of thumbnails and each one of these thumbnails is wrapped in an anchor tag.

Something really weird is going on with a Drupal 6 project I've "inherited".

In a few of the views it there's a bunch of thumbnails and each one of these thumbnails is wrapped in an anchor tag.

Here's where it gets weird.

The title and alt attributes of that wrapper anchor are equal to the image tag.

In the Screenshot below, I am hovering over the Catalogs & Booklets thumbnail:

http://files.droplr.com/files/42950815/yuRq.hover.jpg

I took a screenshot of the so开发者_开发技巧urce code too:

http://files.droplr.com/files/42950815/Sxy0.sauce.jpg

I can't find anything in the view that would create this problem:

http://files.droplr.com/files/42950815/v9U8.view.jpg

But then again, I'm extremely rusty when it comes to Drupal.

Does anyone have an idea why this could be happening and where I could find the code responsible for this output?


First bet is to take a look at theme, I'm almost certain that what's causing this is one or more of:

  • Custom views template file
  • Preprocess function for the view, like themename_preprocess_views_view_fields
  • Theme function override.

All of this happens in a view template file, you can check the view's theme information to find out which templates are used, or the theme's template.php file.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号