activating access hyperlink from asp

N

niv

i have a database, one of the fields is a hyperlink to a
htm file.
i want to activate it automaticly as the asp file is loaded
no click is needed.so that the background of the BODY part
will remain and that text will be of the htm file.
Both the background and the htm file are one record in the
database, i tried:
<BODY backgound='<%details("background")%>' HREF=<%details
("htmfile")%>'>
the background field is a text field, containing the gif
file address, and the htmfile is a hyperlink field ,
linked to the htm file. and i need to activate automaticly,
can you help me?
thanks a lot
niv
 
K

Ken Schaefer

Your question does not make sense. If you mean that the HTML page's contents
are stored in the database, then you should do:

<body style="background-color: <%=details("background")%>;">
<%=details("htmlfile")%>
</body>

If you want the current page to be *redirected* to a different URL, then you
can do:

<html>
<head>
<meta http-equiv="refresh" content="0;URL=<%=details("htmlfile")%>">
</head>
</html>

However, you can't display the current page (and set the background for the
current page), and display some other page as well...

Cheers
Ken

: i have a database, one of the fields is a hyperlink to a
: htm file.
: i want to activate it automaticly as the asp file is loaded
: no click is needed.so that the background of the BODY part
: will remain and that text will be of the htm file.
: Both the background and the htm file are one record in the
: database, i tried:
: <BODY backgound='<%details("background")%>' HREF=<%details
: ("htmfile")%>'>
: the background field is a text field, containing the gif
: file address, and the htmfile is a hyperlink field ,
: linked to the htm file. and i need to activate automaticly,
: can you help me?
: thanks a lot
: niv
 
N

niv

the code line
<%=details("htmfile")%> in :

<body style="background-color: <%=details("background")%
<%=details("htmlfile")%>
</body> does not activate the file which its hyperlink is
written in the "htmfile" field
how do i activate it and make it the content of the BODY
part?
pls help
tanks a lot
niv
 
K

Ken Schaefer

I'm sorry, I do not understand what "include and activate" it means. If you
mean get the content from *another*, external HTML file (which is located on
some other webserver), and include it in your current HTML page - you can't
do that like you are trying to do. Please go and read a HTML reference,
since it'll make things much clearer.

You'll need to use a server-side object to issue a HTTP request for the
remote resource, read in the remote server's response, parse out the stuff
you don't want, and Response.write() the rest to the body of the document.

Cheers
Ken

: the code line
: <%=details("htmfile")%> in :
:
: <body style="background-color: <%=details("background")%
: >;">
: <%=details("htmlfile")%>
: </body> does not activate the file which its hyperlink is
: written in the "htmfile" field
: how do i activate it and make it the content of the BODY
: part?
: pls help
: tanks a lot
: niv
:
:
:
: >-----Original Message-----
: >Your question does not make sense. If you mean that the
: HTML page's contents
: >are stored in the database, then you should do:
: >
: ><body style="background-color: <%=details("background")%
: >;">
: > <%=details("htmlfile")%>
: ></body>
: >
: >If you want the current page to be *redirected* to a
: different URL, then you
: >can do:
: >
: ><html>
: > <head>
: > <meta http-equiv="refresh" content="0;URL=<%
: =details("htmlfile")%>">
: > </head>
: ></html>
: >
: >However, you can't display the current page (and set the
: background for the
: >current page), and display some other page as well...
: >
: >Cheers
: >Ken
: >
: >: >: i have a database, one of the fields is a hyperlink to a
: >: htm file.
: >: i want to activate it automaticly as the asp file is
: loaded
: >: no click is needed.so that the background of the BODY
: part
: >: will remain and that text will be of the htm file.
: >: Both the background and the htm file are one record in
: the
: >: database, i tried:
: >: <BODY backgound='<%details("background")%>' HREF=<%
: details
: >: ("htmfile")%>'>
: >: the background field is a text field, containing the gif
: >: file address, and the htmfile is a hyperlink field ,
: >: linked to the htm file. and i need to activate
: automaticly,
: >: can you help me?
: >: thanks a lot
: >: niv
: >
: >
: >.
: >
 

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

Members online

Forum statistics

Threads
473,744
Messages
2,569,482
Members
44,900
Latest member
Nell636132

Latest Threads

Top