I use:
Content Construction Kit (CCK) 6.x-2.9
ImageCache 6.x-2.0-rc1
Views 6.x-2.16

This was the code I had before changing to unlimited:
<a href="http://beta.findtoilet.dk/content/gr%C3%A5-br%C3%B8dre-torv-kejsergade-2">sites/default/files/images/3/2011/03/biggraabroedretorv.jpg</a>

Now I get:
<a href="http://beta.findtoilet.dk/beta.findtoilet.dk/sites/default/files/images/sites/default/files/images/3/2011/03/biggraabroedretorv.jpgsites/default/files/images/3/2011/03/biggraabroedretorvtest.jpg"><div class="field-item field-item-0"><a href="/content/gr%C3%A5-br%C3%B8dre-torv-kejsergade-2">sites/default/files/images/3/2011/03/biggraabroedretorv.jpg</a></div><div class="field-item field-item-1"><a href="/content/gr%C3%A5-br%C3%B8dre-torv-kejsergade-2">sites/default/files/images/3/2011/03/biggraabroedretorvtest.jpg</a></div></a>

You can see here where there are 2 images uploaded http://beta.findtoilet.dk/content/gr%C3%A5-br%C3%B8dre-torv-kejsergade-2 and the XML files is here http://beta.findtoilet.dk/xml/term/2/K%C3%B8benhavn

It looks like this in View: http://tinemuller.dk/div/imagefield.jpg

Edited: 4 March - Forgot to mention why it's important I get XML to functioning. An Android app is being programmed for me and programmer use this XML-file.

Comments

tinem’s picture

Issue summary: View changes

???

tinem’s picture

Could it have something to do with Group multiple values? Don't know how to use this and where to read about it. Someone help, please? We need to get the Android app finished.

quicksketch’s picture

Category: bug » support

This question has more to do with Views than it does with ImageField, but I'll answer it here since it seems unlikely you'd get a response in the flooded Views queue.

The problem here is that the value of your "Link path" option includes "example.com/sites/default/files/images/[field_image_fid]", but the formatter you have specified for this field is "Path to file". This means that the token [field_image_fid] contains the value "sites/default/files/images/path/to/file.png". So when the whole link is built out, it's example.com/sites/default/files/images/sites/default/files/images/path/to/file.png. So basically, Drupal has done exactly what you told it to do, even though it doesn't make any sense.

To solve this problem, just change the Link Path to not include the full file path. It should simply be http://example.com/[field_image_fid].

tinem’s picture

Thanks a million for trying to help.

I now changed to Link path: beta.findtoilet.dk/[field_image_fid]

but think the code still looks strange here with two images:

<a href="http://beta.findtoilet.dk/beta.findtoilet.dk/sites/default/files/images/3/2011/03/biggraabroedretorv.jpgsites/default/files/images/3/2011/03/biggraabroedretorvtest.jpg"><div class="field-item field-item-0"><a href="/content/gr%C3%A5-br%C3%B8dre-torv-kejsergade-2">sites/default/files/images/3/2011/03/biggraabroedretorv.jpg</a></div><div class="field-item field-item-1"><a href="/content/gr%C3%A5-br%C3%B8dre-torv-kejsergade-2">sites/default/files/images/3/2011/03/biggraabroedretorvtest.jpg</a></div></a>

Edited: 5 March 10:41 - domain in start showed twice
http://beta.findtoilet.dk/beta.findtoilet.dk
biggraabroedretorv.jpgsites
jpg and sites is not splitted
and maybe also a lot more strange code

When I look in .CSV file for Copenhagen http://beta.findtoilet.dk/csv/term/2/K%C3%B8benhavn.csv it looks like this for two images
sites/default/files/images/3/2011/03/biggraabroedretorv.jpgsites/default/files/images/3/2011/03/biggraabroedretorvtest.jpg
biggraabroedretorv.jpgsites
jpg and sites is not splitted here either

Maybe it is CSS I need to change but to what and where?

tinem’s picture

quicksketch’s picture

I now changed to Link path: beta.findtoilet.dk/[field_image_fid]

You have to start with http:// otherwise Drupal thinks that "beta.findtoilet.dk" is a directory name.

tinem’s picture

Thanks, now it looks like this:

<a href="http://beta.findtoilet.dk/sites/default/files/images/3/2011/03/biggraabroedretorv.jpgsites/default/files/images/3/2011/03/biggraabroedretorvtest.jpg"><div class="field-item field-item-0"><a href="/content/gr%C3%A5-br%C3%B8dre-torv-kejsergade-2">sites/default/files/images/3/2011/03/biggraabroedretorv.jpg</a></div><div class="field-item field-item-1"><a href="/content/gr%C3%A5-br%C3%B8dre-torv-kejsergade-2">sites/default/files/images/3/2011/03/biggraabroedretorvtest.jpg</a></div></a>

Still - biggraabroedretorv.jpgsites and don't know if all the code is at it should be for an android programmer to use.

quicksketch’s picture

Maybe what's happening here is some kind of recursive behavior? You're putting a field's value in as a link to itself, maybe that's what's causing the doubling up?

Maybe your best bet with all of this is just to use a formatter that allows you to show the path to the file and have it be linked at the same time. What's wrong with just using the "Generic file" formatter that shows you the file name and links to the file at the same time? Do you need to show the whole path as the text of the link?

quicksketch’s picture

Status: Active » Fixed

Closing after lack of activity.

Status: Fixed » Closed (fixed)

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

Anonymous’s picture

Issue summary: View changes

A message about why I need XML-file