473,379 Members | 1,170 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,379 software developers and data experts.

Is there a way of doing this server-side?

I use ASP and I need to know how to attaches an Iframe Id with its page so I
can load menu options ( eg. 1.htm, 2.htm, 3.htm, ect...) into the Iframe
from any given page on my website.
The problem is for me that I cannot use _top because I am not always on the
page that holds the Iframe in question ( page_iframe.htm ). that holds the
Iframe ( Iframe001). I can load any given page into the iframe only when I
am on ( page_frame.htm.)

Now what if I am on index.asp and I have a menu with sub options. I want
those sub options (eg, 1.htm, 2.htm, 3.htm..ect..) to load into Iframe001
which is located on ( page_frame.htm ) How do we do that?

Here is one idea but its client-side . Is there a better way to do it
server-side?

--------------Client side code----------------------------
- From Menu -
<a href="mainpage.asp?ifp=subpage.asp">Click</a>

mainpage.asp -
<%
ifpsrccode="document.getElementbyid.Iframe001.src= '" & request("ifp") & "'"
%>
<html>
....
<body onload="<%=ifpsrccode%>">
<iframe id=Iframe001 name=Iframe001></iframe>
....
</html>
--------------End of client side code----------------------

Thanks in advance for reading this post. :)

Paul

Jul 22 '05 #1
6 1434
Gazing into my crystal ball I observed "Paul"
<pa***********@sympatico.ca> writing in
news:1P*******************@news20.bellglobal.com:
I use ASP and I need to know how to attaches an Iframe Id with its page
so I can load menu options ( eg. 1.htm, 2.htm, 3.htm, ect...) into the
Iframe from any given page on my website.


<snip>

I hate to say this, but, you need to rethink this unless you are working on
an Intranet. Iframes have the same problems as regular frames (as you have
discovered), and javascript navigation will fail for visitors without
javascript enabled, like Google.
--
Adrienne Boswell
http://www.cavalcade-of-coding.info
Please respond to the group so others can share
Jul 22 '05 #2
HI! I plan to use a javascript checker, and my content is 50% flash
templates and other js script related templates.

So the user will most probably have his/hers java enabled or will want
too in order to preview the templates.

Do you have any idea how I can use server code to do it?

Paul

*** Sent via Developersdex http://www.developersdex.com ***
Jul 22 '05 #3
Gazing into my crystal ball I observed Paul <no****@devdex.com> writing
in news:ux**************@TK2MSFTNGP09.phx.gbl:
HI! I plan to use a javascript checker, and my content is 50% flash
templates and other js script related templates.
You can do preliminary checking client side. Do not depend on it, always
validate server side.

So the user will most probably have his/hers java enabled or will want
too in order to preview the templates.
Why would the user have to have java enabled? Flash is not java, and
javascript is certainly not java. Oh! You mean that the visitor is
going to have to have javaSCRIPT enabled in order to preview the
templates. That's not a wise idea. More and more people are disabling
javascript to get away from nasty things, pop-ups, etc.

A website should never be dependent on client side scripting. Using
javascript to enhance the user's experience is one thing, dependency
another.

Do you have any idea how I can use server code to do it?


ASP know absolutely nothing about what is going on client side.
--
Adrienne Boswell
http://www.cavalcade-of-coding.info
Please respond to the group so others can share
Jul 24 '05 #4
HI! yes flash does not need java enabled, what I meant was that the site
that I am affiliated with uses scripting and I already found one item that
gets blocked with Norton Internet Security Spam Blocker. all affiliates are
sort of force to use it or they must use WebAPI to download all the
templates for previewing. WebAPI is the preferred method of coarse. but not
everyone knows how to use it. I for one.

Since this is a commercial site selling products I figure that if I check
for a blocker I can alert the user to allow scripting for the site or advise
him that some functionality will be dis-abled and I can re-direct the user
to another page.

For now however I am using this method as it works,

<%
dim ifp
ifp = Request.QueryString("ifp")
if ifp <> "" then
%>
<iframe src=<%= ifp %> name="Iframe001" width="750px" height="920px"
scrolling="yes" id="Iframe001">If you are reading this then your browser
cannot view Iframe, Please upgrade you browser.</iframe>
<% else %>
<iframe src="defaultpage.htm" name="Iframe001" width="750px" height="920px"
scrolling="yes" id="Iframe001">If you are reading this then your browser
cannot view Iframe, Please upgrade you browser.</iframe>
<% end if %>

The only thing thought, I don't know how to do this in JavaScript. the only
docs I read and help I got was in VB.
Paul
"Adrienne" <ar********@sbcglobal.net> wrote in message
news:Xn**************************@207.115.63.158.. .
Gazing into my crystal ball I observed Paul <no****@devdex.com> writing
in news:ux**************@TK2MSFTNGP09.phx.gbl:
HI! I plan to use a javascript checker, and my content is 50% flash
templates and other js script related templates.


You can do preliminary checking client side. Do not depend on it, always
validate server side.

So the user will most probably have his/hers java enabled or will want
too in order to preview the templates.


Why would the user have to have java enabled? Flash is not java, and
javascript is certainly not java. Oh! You mean that the visitor is
going to have to have javaSCRIPT enabled in order to preview the
templates. That's not a wise idea. More and more people are disabling
javascript to get away from nasty things, pop-ups, etc.

A website should never be dependent on client side scripting. Using
javascript to enhance the user's experience is one thing, dependency
another.

Do you have any idea how I can use server code to do it?


ASP know absolutely nothing about what is going on client side.
--
Adrienne Boswell
http://www.cavalcade-of-coding.info
Please respond to the group so others can share

Jul 24 '05 #5
Gazing into my crystal ball I observed "Paul"
<pa***********@sympatico.ca> writing in
news:uQ**************@tk2msftngp13.phx.gbl:

HI! yes flash does not need java enabled,
Flash has absolutely _nothing_ to do with java. Java is a compiled
language, Flash is a browser plugin.

what I meant was that the site that I am affiliated with uses scripting and I already found one
item that gets blocked with Norton Internet Security Spam Blocker. all
affiliates are sort of force to use it or they must use WebAPI to
download all the templates for previewing. WebAPI is the preferred
method of coarse. but not everyone knows how to use it. I for one.
Do you have a URL? I've got to see this.

Since this is a commercial site selling products I figure that if I
check for a blocker I can alert the user to allow scripting for the
site or advise him that some functionality will be dis-abled and I can
re-direct the user to another page.

A commercial site that sells products must be especially aware of users who
do not have client side scripting available, iframes enabled, flash
available, images enabled, etc. Checking for a blocker is the least of
your concerns.
For now however I am using this method as it works,

<%
dim ifp
ifp = Request.QueryString("ifp")
if ifp <> "" then
%>
<iframe src=<%= ifp %> name="Iframe001" width="750px" height="920px"
scrolling="yes" id="Iframe001">If you are reading this then your
browser cannot view Iframe, Please upgrade you browser.</iframe>
<% else %>
<iframe src="defaultpage.htm" name="Iframe001" width="750px"
height="920px"
scrolling="yes" id="Iframe001">If you are reading this then your
browser cannot view Iframe, Please upgrade you browser.</iframe>
<% end if %>
Jehosephat! I hate sites that tell me I have to upgrade my browser to see
something - I always leave and find what I want somewhere else.

You know, your most important visitor is going to see that message as well,
but Google can't do that.

The only thing thought, I don't know how to do this in JavaScript. the
only docs I read and help I got was in VB.
Then you need to post to a javascript group, comp.lang.javascript might be
a good place to start.


Paul
"Adrienne" <ar********@sbcglobal.net> wrote in message
news:Xn**************************@207.115.63.158.. .
Gazing into my crystal ball I observed Paul <no****@devdex.com>
writing in news:ux**************@TK2MSFTNGP09.phx.gbl:
HI! I plan to use a javascript checker, and my content is 50% flash
templates and other js script related templates.


You can do preliminary checking client side. Do not depend on it,
always validate server side.

So the user will most probably have his/hers java enabled or will
want too in order to preview the templates.


Why would the user have to have java enabled? Flash is not java, and
javascript is certainly not java. Oh! You mean that the visitor is
going to have to have javaSCRIPT enabled in order to preview the
templates. That's not a wise idea. More and more people are
disabling javascript to get away from nasty things, pop-ups, etc.

A website should never be dependent on client side scripting. Using
javascript to enhance the user's experience is one thing, dependency
another.

Do you have any idea how I can use server code to do it?


ASP know absolutely nothing about what is going on client side.
--
Adrienne Boswell
http://www.cavalcade-of-coding.info
Please respond to the group so others can share



--
Adrienne Boswell
http://www.cavalcade-of-coding.info
Please respond to the group so others can share
Jul 24 '05 #6
Thanks for your comments, I will keep that in mind :)
Paul

"Adrienne" <ar********@sbcglobal.net> wrote in message
news:Xn****************************@207.115.63.158 ...
Gazing into my crystal ball I observed "Paul"
<pa***********@sympatico.ca> writing in
news:uQ**************@tk2msftngp13.phx.gbl:

HI! yes flash does not need java enabled,


Flash has absolutely _nothing_ to do with java. Java is a compiled
language, Flash is a browser plugin.

what I meant was that the
site that I am affiliated with uses scripting and I already found one
item that gets blocked with Norton Internet Security Spam Blocker. all
affiliates are sort of force to use it or they must use WebAPI to
download all the templates for previewing. WebAPI is the preferred
method of coarse. but not everyone knows how to use it. I for one.


Do you have a URL? I've got to see this.

Since this is a commercial site selling products I figure that if I
check for a blocker I can alert the user to allow scripting for the
site or advise him that some functionality will be dis-abled and I can
re-direct the user to another page.


A commercial site that sells products must be especially aware of users
who
do not have client side scripting available, iframes enabled, flash
available, images enabled, etc. Checking for a blocker is the least of
your concerns.
For now however I am using this method as it works,

<%
dim ifp
ifp = Request.QueryString("ifp")
if ifp <> "" then
%>
<iframe src=<%= ifp %> name="Iframe001" width="750px" height="920px"
scrolling="yes" id="Iframe001">If you are reading this then your
browser cannot view Iframe, Please upgrade you browser.</iframe>
<% else %>
<iframe src="defaultpage.htm" name="Iframe001" width="750px"
height="920px"
scrolling="yes" id="Iframe001">If you are reading this then your
browser cannot view Iframe, Please upgrade you browser.</iframe>
<% end if %>


Jehosephat! I hate sites that tell me I have to upgrade my browser to see
something - I always leave and find what I want somewhere else.

You know, your most important visitor is going to see that message as
well,
but Google can't do that.

The only thing thought, I don't know how to do this in JavaScript. the
only docs I read and help I got was in VB.


Then you need to post to a javascript group, comp.lang.javascript might be
a good place to start.


Paul
"Adrienne" <ar********@sbcglobal.net> wrote in message
news:Xn**************************@207.115.63.158.. .
Gazing into my crystal ball I observed Paul <no****@devdex.com>
writing in news:ux**************@TK2MSFTNGP09.phx.gbl:

HI! I plan to use a javascript checker, and my content is 50% flash
templates and other js script related templates.

You can do preliminary checking client side. Do not depend on it,
always validate server side.
So the user will most probably have his/hers java enabled or will
want too in order to preview the templates.

Why would the user have to have java enabled? Flash is not java, and
javascript is certainly not java. Oh! You mean that the visitor is
going to have to have javaSCRIPT enabled in order to preview the
templates. That's not a wise idea. More and more people are
disabling javascript to get away from nasty things, pop-ups, etc.

A website should never be dependent on client side scripting. Using
javascript to enhance the user's experience is one thing, dependency
another.
Do you have any idea how I can use server code to do it?
ASP know absolutely nothing about what is going on client side.
--
Adrienne Boswell
http://www.cavalcade-of-coding.info
Please respond to the group so others can share



--
Adrienne Boswell
http://www.cavalcade-of-coding.info
Please respond to the group so others can share

Jul 24 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: middletree | last post by:
Intranet tech support system using ASP/VBScript running on W2000 Server, IIS, and using SQL Server 2000. I need to add a search engine. The problem with using a regular SQL query is that if you...
1
by: Benny | last post by:
Hi, I would like to know, if I need to do some floting point operations (mainly multiplication and division) on each roll of a table, should I read the data out from the DB and do the...
5
by: colin.steadman | last post by:
I'm building a statistics page and would like to ping a server and show the result in ASP. This shouldn't be a problem, but I'd like to be able to get the same information for 40 other servers all...
17
by: Paul | last post by:
HI! I get an error with this code. <SCRIPT language="JavaScript"> If (ifp==""){ ifp="default.htm"} //--></SCRIPT> Basicly I want my iframe to have a default page if the user enters in...
2
by: UJ | last post by:
Is there a way with a asp:checkbox to run a JavaScript to display/hide text/input on the screen without doing a postback? I also need to be able to access the stuff at the server so I need to...
1
by: Ben Kim | last post by:
Hello all, We are connecting to a remote server using FTP and sending up 100's of files daily to this site. I just received a call from the operations manager of this site and they are...
0
by: Nightcrawler | last post by:
I hope this is the right group for this question. I recently started looking into AJAX and I am doing the following: I have a repeater (dummydata) that is bound to a datatable (Articles). Each...
6
by: dgleeson3 | last post by:
Hello All I have VB code (.Net 2005) reading from an SQL server 2005 database. Im getting InvalidCastException when doing reader.GetInt32(0) Im simply reading an int from a simple database. It...
25
by: Darsin | last post by:
Hi all I need to perform a summation on a column of a table based on a criteria given in another column in the same table. The catch is i need to perform different sums according to the number of...
0
by: okonita | last post by:
Hi all, I am having a DB2 connectivity problem that I hope someone can help me resolve. I need this to test Replication and such other things. What am I doing wrong here? Any help that I can get...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.