Hyperlinks for one image

G

Guest

I have inserted a 'More Info' image where the results of a database field
called Deeplink would normally appear. The filed 'Deeplink' is an URL to
someone elses website. I have had a go and this is the code that I have so
far.

The idea is that the 'More Info' image appears eveytime but with a different
URL depending on which 'Deeplink' field is return from the results.

<a href="fpdb/fpnwind.mdb?DeepLink='<%=FP_FieldURL(fp_rs,"DeepLink")%>'">
<img border="0" src="images/MoreInfo.2.gif" width="98"height="30"></a></td>

An example of one deeplink is:

When I publish and test it looks like it is going to work but then doesn't,
the link behind the image is purely to the image file.
 
R

Ronx

<a href="<%=FP_FieldURL(fp_rs,"DeepLink")%>"><img border="0"
src="images/MoreInfo.2.gif" width="98"height="30"></a>

is nearer to the correct sytax, but it depends on exactly what is
contained by the DeepLink field.

Your link will atempt to download the database.
--
Ron Symonds - Microsoft MVP (FrontPage)
Reply only to group - emails will be deleted unread.
FrontPage Support: http://www.frontpagemvps.com/


Graham said:
I have inserted a 'More Info' image where the results of a database field
called Deeplink would normally appear. The filed 'Deeplink' is an URL to
someone elses website. I have had a go and this is the code that I have so
far.

The idea is that the 'More Info' image appears eveytime but with a different
URL depending on which 'Deeplink' field is return from the results.

<a
 
G

Guest

I tried this but when I click on the 'More Info' gif it's URL is the path for
where the image is stored. What I want it to do is to pick up the URL from
the database field 'Deeplink' and go to that URL instead.

An example of an URL from the deeplink field is:

http://www.dgm2.com/m/flowers2send/...m/DetailContent.asp?refcode=DGM&lProductID=83

Any ideas
--
Many thanks

Graham


Ronx said:
<a href="<%=FP_FieldURL(fp_rs,"DeepLink")%>"><img border="0"
src="images/MoreInfo.2.gif" width="98"height="30"></a>

is nearer to the correct sytax, but it depends on exactly what is
contained by the DeepLink field.

Your link will atempt to download the database.
--
Ron Symonds - Microsoft MVP (FrontPage)
Reply only to group - emails will be deleted unread.
FrontPage Support: http://www.frontpagemvps.com/


Graham said:
I have inserted a 'More Info' image where the results of a database field
called Deeplink would normally appear. The filed 'Deeplink' is an URL to
someone elses website. I have had a go and this is the code that I have so
far.

The idea is that the 'More Info' image appears eveytime but with a different
URL depending on which 'Deeplink' field is return from the results.

<a
 
T

Thomas A. Rowe

What Ronx has provided you is the correct format for the link.

You need to select the image in design / normal view, then right click, select Hyperlink properties
and then enter the following as the hyperlink:

<%=FP_FieldURL(fp_rs,"DeepLink")%>

and then set the frame target value to New Window.
--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
==============================================
If you feel your current issue is a results of installing
a Service Pack or security update, please contact
Microsoft Product Support Services:
http://support.microsoft.com
If the problem can be shown to have been caused by a
security update, then there is usually no charge for the call.
==============================================

Graham said:
I tried this but when I click on the 'More Info' gif it's URL is the path for
where the image is stored. What I want it to do is to pick up the URL from
the database field 'Deeplink' and go to that URL instead.

An example of an URL from the deeplink field is:

http://www.dgm2.com/m/flowers2send/...m/DetailContent.asp?refcode=DGM&lProductID=83

Any ideas
 
G

Guest

I tried this and the code now reads:

<a target="_blank" href="'<%=FP_FieldURL(fp_rs,"DeepLink")%>'"><img
border="0" src="images/MoreInfo.2.gif" width="98" height="30"></a>

But when you hover over the image the URL shows my sites URL and then the
deeplink URL (have a look at my test page
http://www.hobbies4you.co.uk/Testing4.asp)

I really do appreciate all your help.
 
T

Thomas A. Rowe

Do you by chance have a base URL set in the head section of this page, if so delete it.

Also change you link to the following:

<a href="<%=fp_rs("DeepLink")%>" target="_blank"><img border="0" src="images/MoreInfo.2.gif"
width="98" height="30"></a>

Mainly, remove the single quotes from around the URL.
--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
==============================================
If you feel your current issue is a results of installing
a Service Pack or security update, please contact
Microsoft Product Support Services:
http://support.microsoft.com
If the problem can be shown to have been caused by a
security update, then there is usually no charge for the call.
==============================================
 
S

Stefan B Rusynko

That will clean up his code but his main problem is the data in the database is bad returning garbage links like

http://www.hobbies4you.co.uk/'http:...tailContent.asp%3frefcode=DGM%26lProductID=83'

And the pages are also badly malformed html
--

_____________________________________________
SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
"Warning - Using the F1 Key will not break anything!" (-;
To find the best Newsgroup for FrontPage support see:
http://www.frontpagemvps.com/FrontPageNewsGroups/tabid/53/Default.aspx
_____________________________________________


| Do you by chance have a base URL set in the head section of this page, if so delete it.
|
| Also change you link to the following:
|
| <a href="<%=fp_rs("DeepLink")%>" target="_blank"><img border="0" src="images/MoreInfo.2.gif"
| width="98" height="30"></a>
|
| Mainly, remove the single quotes from around the URL.
| --
| ==============================================
| Thomas A. Rowe (Microsoft MVP - FrontPage)
| ==============================================
| If you feel your current issue is a results of installing
| a Service Pack or security update, please contact
| Microsoft Product Support Services:
| http://support.microsoft.com
| If the problem can be shown to have been caused by a
| security update, then there is usually no charge for the call.
| ==============================================
|
| | >I tried this and the code now reads:
| >
| > <a target="_blank" href="'<%=FP_FieldURL(fp_rs,"DeepLink")%>'"><img
| > border="0" src="images/MoreInfo.2.gif" width="98" height="30"></a>
| >
| > But when you hover over the image the URL shows my sites URL and then the
| > deeplink URL (have a look at my test page
| > http://www.hobbies4you.co.uk/Testing4.asp)
| >
| > I really do appreciate all your help.
| > --
| > Many thanks
| >
| > Graham
| >
| >
| > "Thomas A. Rowe" wrote:
| >
| >> What Ronx has provided you is the correct format for the link.
| >>
| >> You need to select the image in design / normal view, then right click, select Hyperlink
| >> properties
| >> and then enter the following as the hyperlink:
| >>
| >> <%=FP_FieldURL(fp_rs,"DeepLink")%>
| >>
| >> and then set the frame target value to New Window.
| >> --
| >> ==============================================
| >> Thomas A. Rowe (Microsoft MVP - FrontPage)
| >> ==============================================
| >> If you feel your current issue is a results of installing
| >> a Service Pack or security update, please contact
| >> Microsoft Product Support Services:
| >> http://support.microsoft.com
| >> If the problem can be shown to have been caused by a
| >> security update, then there is usually no charge for the call.
| >> ==============================================
| >>
| >> | >> >I tried this but when I click on the 'More Info' gif it's URL is the path for
| >> > where the image is stored. What I want it to do is to pick up the URL from
| >> > the database field 'Deeplink' and go to that URL instead.
| >> >
| >> > An example of an URL from the deeplink field is:
| >> >
| >> >
http://www.dgm2.com/m/flowers2send/...m/DetailContent.asp?refcode=DGM&lProductID=83
| >> >
| >> > Any ideas
| >> > --
| >> > Many thanks
| >> >
| >> > Graham
| >> >
| >> >
| >> > "Ronx" wrote:
| >> >
| >> >> <a href="<%=FP_FieldURL(fp_rs,"DeepLink")%>"><img border="0"
| >> >> src="images/MoreInfo.2.gif" width="98"height="30"></a>
| >> >>
| >> >> is nearer to the correct sytax, but it depends on exactly what is
| >> >> contained by the DeepLink field.
| >> >>
| >> >> Your link will atempt to download the database.
| >> >> --
| >> >> Ron Symonds - Microsoft MVP (FrontPage)
| >> >> Reply only to group - emails will be deleted unread.
| >> >> FrontPage Support: http://www.frontpagemvps.com/
| >> >>
| >> >>
| >> >> | >> >> > I have inserted a 'More Info' image where the results of a database
| >> >> field
| >> >> > called Deeplink would normally appear. The filed 'Deeplink' is an
| >> >> URL to
| >> >> > someone elses website. I have had a go and this is the code that I
| >> >> have so
| >> >> > far.
| >> >> >
| >> >> > The idea is that the 'More Info' image appears eveytime but with a
| >> >> different
| >> >> > URL depending on which 'Deeplink' field is return from the results.
| >> >> >
| >> >> > <a
| >> >> href="fpdb/fpnwind.mdb?DeepLink='<%=FP_FieldURL(fp_rs,"DeepLink")%>'">
| >> >> > <img border="0" src="images/MoreInfo.2.gif"
| >> >> width="98"height="30"></a></td>
| >> >> >
| >> >> > An example of one deeplink is:
| >> >> >
| >> >> > When I publish and test it looks like it is going to work but then
| >> >> doesn't,
| >> >> > the link behind the image is purely to the image file.
| >> >> >
| >> >> > --
| >> >> > Many thanks
| >> >> >
| >> >> > Graham
| >> >>
| >> >>
| >> >>
| >>
| >>
| >>
|
|
 
G

Guest

Thomas,

This worked a treat when I used it with a small sample of data. I have used
it on larger quantities and I get the following error.

ADODB.Recordset error '800a0cc1'

Item cannot be found in the collection corresponding to the requested name
or ordinal.

/_fpclass/fpdblib.inc, line 48

I have look at line 48 and it looks to me as though the error is because one
or more feilds are empty but they are not?

Any ideas?
 
S

Stefan B Rusynko

The error means your table does not have field by that name
See http://www.aspfaq.com/show.asp?id=2275
- or your DBRW doesn't know you are using that field
--

_____________________________________________
SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
"Warning - Using the F1 Key will not break anything!" (-;
To find the best Newsgroup for FrontPage support see:
http://www.frontpagemvps.com/FrontPageNewsGroups/tabid/53/Default.aspx
_____________________________________________


| Thomas,
|
| This worked a treat when I used it with a small sample of data. I have used
| it on larger quantities and I get the following error.
|
| ADODB.Recordset error '800a0cc1'
|
| Item cannot be found in the collection corresponding to the requested name
| or ordinal.
|
| /_fpclass/fpdblib.inc, line 48
|
| I have look at line 48 and it looks to me as though the error is because one
| or more feilds are empty but they are not?
|
| Any ideas?
| --
| Many thanks
|
| Graham
|
|
| "Thomas A. Rowe" wrote:
|
| > Do you by chance have a base URL set in the head section of this page, if so delete it.
| >
| > Also change you link to the following:
| >
| > <a href="<%=fp_rs("DeepLink")%>" target="_blank"><img border="0" src="images/MoreInfo.2.gif"
| > width="98" height="30"></a>
| >
| > Mainly, remove the single quotes from around the URL.
| > --
| > ==============================================
| > Thomas A. Rowe (Microsoft MVP - FrontPage)
| > ==============================================
| > If you feel your current issue is a results of installing
| > a Service Pack or security update, please contact
| > Microsoft Product Support Services:
| > http://support.microsoft.com
| > If the problem can be shown to have been caused by a
| > security update, then there is usually no charge for the call.
| > ==============================================
| >
| > | > >I tried this and the code now reads:
| > >
| > > <a target="_blank" href="'<%=FP_FieldURL(fp_rs,"DeepLink")%>'"><img
| > > border="0" src="images/MoreInfo.2.gif" width="98" height="30"></a>
| > >
| > > But when you hover over the image the URL shows my sites URL and then the
| > > deeplink URL (have a look at my test page
| > > http://www.hobbies4you.co.uk/Testing4.asp)
| > >
| > > I really do appreciate all your help.
| > > --
| > > Many thanks
| > >
| > > Graham
| > >
| > >
| > > "Thomas A. Rowe" wrote:
| > >
| > >> What Ronx has provided you is the correct format for the link.
| > >>
| > >> You need to select the image in design / normal view, then right click, select Hyperlink
| > >> properties
| > >> and then enter the following as the hyperlink:
| > >>
| > >> <%=FP_FieldURL(fp_rs,"DeepLink")%>
| > >>
| > >> and then set the frame target value to New Window.
| > >> --
| > >> ==============================================
| > >> Thomas A. Rowe (Microsoft MVP - FrontPage)
| > >> ==============================================
| > >> If you feel your current issue is a results of installing
| > >> a Service Pack or security update, please contact
| > >> Microsoft Product Support Services:
| > >> http://support.microsoft.com
| > >> If the problem can be shown to have been caused by a
| > >> security update, then there is usually no charge for the call.
| > >> ==============================================
| > >>
| > >> | > >> >I tried this but when I click on the 'More Info' gif it's URL is the path for
| > >> > where the image is stored. What I want it to do is to pick up the URL from
| > >> > the database field 'Deeplink' and go to that URL instead.
| > >> >
| > >> > An example of an URL from the deeplink field is:
| > >> >
| > >> >
http://www.dgm2.com/m/flowers2send/...m/DetailContent.asp?refcode=DGM&lProductID=83
| > >> >
| > >> > Any ideas
| > >> > --
| > >> > Many thanks
| > >> >
| > >> > Graham
| > >> >
| > >> >
| > >> > "Ronx" wrote:
| > >> >
| > >> >> <a href="<%=FP_FieldURL(fp_rs,"DeepLink")%>"><img border="0"
| > >> >> src="images/MoreInfo.2.gif" width="98"height="30"></a>
| > >> >>
| > >> >> is nearer to the correct sytax, but it depends on exactly what is
| > >> >> contained by the DeepLink field.
| > >> >>
| > >> >> Your link will atempt to download the database.
| > >> >> --
| > >> >> Ron Symonds - Microsoft MVP (FrontPage)
| > >> >> Reply only to group - emails will be deleted unread.
| > >> >> FrontPage Support: http://www.frontpagemvps.com/
| > >> >>
| > >> >>
| > >> >> | > >> >> > I have inserted a 'More Info' image where the results of a database
| > >> >> field
| > >> >> > called Deeplink would normally appear. The filed 'Deeplink' is an
| > >> >> URL to
| > >> >> > someone elses website. I have had a go and this is the code that I
| > >> >> have so
| > >> >> > far.
| > >> >> >
| > >> >> > The idea is that the 'More Info' image appears eveytime but with a
| > >> >> different
| > >> >> > URL depending on which 'Deeplink' field is return from the results.
| > >> >> >
| > >> >> > <a
| > >> >> href="fpdb/fpnwind.mdb?DeepLink='<%=FP_FieldURL(fp_rs,"DeepLink")%>'">
| > >> >> > <img border="0" src="images/MoreInfo.2.gif"
| > >> >> width="98"height="30"></a></td>
| > >> >> >
| > >> >> > An example of one deeplink is:
| > >> >> >
| > >> >> > When I publish and test it looks like it is going to work but then
| > >> >> doesn't,
| > >> >> > the link behind the image is purely to the image file.
| > >> >> >
| > >> >> > --
| > >> >> > Many thanks
| > >> >> >
| > >> >> > Graham
| > >> >>
| > >> >>
| > >> >>
| > >>
| > >>
| > >>
| >
| >
| >
 
G

Guest

Stefan & Thomas

Everything working fine now. I really appreciate your help.
--
Many thanks

Graham


Stefan B Rusynko said:
The error means your table does not have field by that name
See http://www.aspfaq.com/show.asp?id=2275
- or your DBRW doesn't know you are using that field
--

_____________________________________________
SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
"Warning - Using the F1 Key will not break anything!" (-;
To find the best Newsgroup for FrontPage support see:
http://www.frontpagemvps.com/FrontPageNewsGroups/tabid/53/Default.aspx
_____________________________________________


| Thomas,
|
| This worked a treat when I used it with a small sample of data. I have used
| it on larger quantities and I get the following error.
|
| ADODB.Recordset error '800a0cc1'
|
| Item cannot be found in the collection corresponding to the requested name
| or ordinal.
|
| /_fpclass/fpdblib.inc, line 48
|
| I have look at line 48 and it looks to me as though the error is because one
| or more feilds are empty but they are not?
|
| Any ideas?
| --
| Many thanks
|
| Graham
|
|
| "Thomas A. Rowe" wrote:
|
| > Do you by chance have a base URL set in the head section of this page, if so delete it.
| >
| > Also change you link to the following:
| >
| > <a href="<%=fp_rs("DeepLink")%>" target="_blank"><img border="0" src="images/MoreInfo.2.gif"
| > width="98" height="30"></a>
| >
| > Mainly, remove the single quotes from around the URL.
| > --
| > ==============================================
| > Thomas A. Rowe (Microsoft MVP - FrontPage)
| > ==============================================
| > If you feel your current issue is a results of installing
| > a Service Pack or security update, please contact
| > Microsoft Product Support Services:
| > http://support.microsoft.com
| > If the problem can be shown to have been caused by a
| > security update, then there is usually no charge for the call.
| > ==============================================
| >
| > | > >I tried this and the code now reads:
| > >
| > > <a target="_blank" href="'<%=FP_FieldURL(fp_rs,"DeepLink")%>'"><img
| > > border="0" src="images/MoreInfo.2.gif" width="98" height="30"></a>
| > >
| > > But when you hover over the image the URL shows my sites URL and then the
| > > deeplink URL (have a look at my test page
| > > http://www.hobbies4you.co.uk/Testing4.asp)
| > >
| > > I really do appreciate all your help.
| > > --
| > > Many thanks
| > >
| > > Graham
| > >
| > >
| > > "Thomas A. Rowe" wrote:
| > >
| > >> What Ronx has provided you is the correct format for the link.
| > >>
| > >> You need to select the image in design / normal view, then right click, select Hyperlink
| > >> properties
| > >> and then enter the following as the hyperlink:
| > >>
| > >> <%=FP_FieldURL(fp_rs,"DeepLink")%>
| > >>
| > >> and then set the frame target value to New Window.
| > >> --
| > >> ==============================================
| > >> Thomas A. Rowe (Microsoft MVP - FrontPage)
| > >> ==============================================
| > >> If you feel your current issue is a results of installing
| > >> a Service Pack or security update, please contact
| > >> Microsoft Product Support Services:
| > >> http://support.microsoft.com
| > >> If the problem can be shown to have been caused by a
| > >> security update, then there is usually no charge for the call.
| > >> ==============================================
| > >>
| > >> | > >> >I tried this but when I click on the 'More Info' gif it's URL is the path for
| > >> > where the image is stored. What I want it to do is to pick up the URL from
| > >> > the database field 'Deeplink' and go to that URL instead.
| > >> >
| > >> > An example of an URL from the deeplink field is:
| > >> >
| > >> >
http://www.dgm2.com/m/flowers2send/...m/DetailContent.asp?refcode=DGM&lProductID=83
| > >> >
| > >> > Any ideas
| > >> > --
| > >> > Many thanks
| > >> >
| > >> > Graham
| > >> >
| > >> >
| > >> > "Ronx" wrote:
| > >> >
| > >> >> <a href="<%=FP_FieldURL(fp_rs,"DeepLink")%>"><img border="0"
| > >> >> src="images/MoreInfo.2.gif" width="98"height="30"></a>
| > >> >>
| > >> >> is nearer to the correct sytax, but it depends on exactly what is
| > >> >> contained by the DeepLink field.
| > >> >>
| > >> >> Your link will atempt to download the database.
| > >> >> --
| > >> >> Ron Symonds - Microsoft MVP (FrontPage)
| > >> >> Reply only to group - emails will be deleted unread.
| > >> >> FrontPage Support: http://www.frontpagemvps.com/
| > >> >>
| > >> >>
| > >> >> | > >> >> > I have inserted a 'More Info' image where the results of a database
| > >> >> field
| > >> >> > called Deeplink would normally appear. The filed 'Deeplink' is an
| > >> >> URL to
| > >> >> > someone elses website. I have had a go and this is the code that I
| > >> >> have so
| > >> >> > far.
| > >> >> >
| > >> >> > The idea is that the 'More Info' image appears eveytime but with a
| > >> >> different
| > >> >> > URL depending on which 'Deeplink' field is return from the results.
| > >> >> >
| > >> >> > <a
| > >> >> href="fpdb/fpnwind.mdb?DeepLink='<%=FP_FieldURL(fp_rs,"DeepLink")%>'">
| > >> >> > <img border="0" src="images/MoreInfo.2.gif"
| > >> >> width="98"height="30"></a></td>
| > >> >> >
| > >> >> > An example of one deeplink is:
| > >> >> >
| > >> >> > When I publish and test it looks like it is going to work but then
| > >> >> doesn't,
| > >> >> > the link behind the image is purely to the image file.
| > >> >> >
| > >> >> > --
| > >> >> > Many thanks
| > >> >> >
| > >> >> > Graham
| > >> >>
| > >> >>
| > >> >>
| > >>
| > >>
| > >>
| >
| >
| >
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Adding text over a graphic image 4
how can i center everything 4
Gallery problem 12
Web Site Code Anomally? 1
Frontpage 2000, browser trouble 5
<a href ...> not working 8
A HUGE GAP 3
Inserting html for ad redirect 6

Top