Adding link in xml file

Hello everyone,

I’m a photographer and my web designer is temporary unreachable at the moment and I need to urgently add hyperlink to my site.

My site is html and currently I can add new things by editing an existing xml such as the following:

<portfolio>
<items>
<item>
<thumbnail>portfolio/blackwhite/01.jpg</thumbnail>
<preview>portfolio/blackwhite/13_big.jpg</preview>
<description> Sample description </description>
<category>bw</category>
</item>
</items>
</portfolio>

Now I would like to add a hyperlink to it, maybe on Sample description can be changed to Click to Visit with a link to it.

I think the xml file is connected to a .js file so if it’s relevant you can review the code here http://pastebin.com/raw.php?i=D5QrDJv4

Hope you guys can help me out, need to sort this out urgently :mad:

Thanks!! :x

Does replacing <description> Sample description </description> with this do the job?

<description> <a href="link path or URL goes here">Click to Visit</a> </description>

I forgot to mention, when the image is clicked it will display a bigger preview in lightbox.

The description displays in the enlarged light box however the <description> <a href=“link path or URL goes here”>Click to Visit</a> </description> does not work, I can see “Click to Visit” but it’s not clickable :mad:

Can you provide a link to the site?

Hi Victor,

Sorry I’m unable to provide the link to my site because it contains private albums of my client.

I’m thinking maybe I need to add something in the javascript for a new tag like <hyperlink> </hyperlink> and define it’s function as a url

So in the xml file I can put <hyperlink> http://google.com </hyperlink> and it’ll recognize it as a link

There is an “XML and Web Services” section on the forums. You’d probably be better off asking there. (Click the orange flag and ask a moderator to move the thread.)

I think the OP is right and it’s more a javascript question. Adding the new tag to the XML file is easy, the hard part is having the js use that new tag.

Moved the thread to the JS forum

Who built this site? Can’t you contact them to ask them to add the link?

We’ll need to see the HTML too to form an answer yo your question.

I’ve been calling my designer for few days now and he’s temporary unavailable.

On a side note

How do I add a link to the following image so it opens a new window when it’s clicked

  &lt;img src="portfolio/art/1.jpg" width="125" height="125" border="0" alt="" /&gt;