473,320 Members | 2,104 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,320 software developers and data experts.

Passing text to a frame in a window

Hello
Im trying to make this application that does this.
The user enters text in a window clicks GO and then a new window opens
with the text in a frame.

I assume I put the text in the URL.
But how do I get the frame on the next window to take the text
and put it in its textbox.

Aug 6 '06 #1
2 1463
Br**************@gmail.com wrote:
Im trying to make this application that does this.
The user enters text in a window clicks GO and then a new window opens
with the text in a frame.

I assume I put the text in the URL.
But how do I get the frame on the next window to take the text
and put it in its textbox.
form.htm =

<html>
<body>
<form target="_blank" method="get" action="frameset.htm">
<input type="text" name="T">
<input type="submit" value="Go">
</form>
</body>
</html>

frameset.htm =

<html>
<head>
<script type="text/javascript">
document.write('<frameset rows="350,*">')
document.write('<frame src="http://www.google.com">')
document.write('<frame src="myframe.htm?'
+location.search.substring(1)+'">')
document.write('</frameset>')
</script>
</head>
<body></body>
</html>

myframe.htm =

<html>
<head>
<script type="text/javascript">
pVal = location.search.substring(1)
pVal = pVal.replace(/^T=/,'')
document.write( pVal )
</script>
</head>
<body></body>
</html>

Hope this helps,

--
Bart

Aug 7 '06 #2
Bart Van der Donck wrote:
[...]
myframe.htm =

<html>
<head>
<script type="text/javascript">
pVal = location.search.substring(1)
pVal = pVal.replace(/^T=/,'')
document.write( pVal )
</script>
</head>
<body></body>
</html>
Ah yes I forgot, just before the document.write command, there should
be something like:

pVal = unescape( pVal )

--
Bart

Aug 8 '06 #3

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

Similar topics

7
by: Scott | last post by:
I need help to modify the code below to pass url variables from a framset. The click to run this will be in the mainFrame. This script works well in a non-frame page. Grabs the current url...
1
by: cirillo_curiosone | last post by:
Hi, i'm new to javascript. I started studing it on the web few weeks ago, but still haven't been able to solve one big problem: HOT TO PASS VALUES FROM A SCRIPT VARIABLE TO A CHILD HTML...
29
by: wayne | last post by:
Hey there... I'm having some problems passing url parameters with an open.window command. I'm not terribly familiar with java script but here is the code below. When executed it opens the...
1
by: | last post by:
Hi, 1st, I did a search and could not find any info on this, the Google results were good, but I'm still have issues...So any help will be great. I have a frame page, which contains 3 frames...
14
by: BrendanMcPherson | last post by:
Hello, Im try to do some tricks to help make a "Search Many Sites from One Location". http://www.act.org.au/b_nexus.htm What I have decided to do is this: 1. You can choose which site you...
2
by: netling | last post by:
Ok, Here is my situation... we have a 64 page pdf that we have broken up into separate pages. We are needing a frame set to have a "Previous Page and Next Page" navigation at the bottom of the...
2
by: Geoff Cox | last post by:
Hello, The code below is aimed at passing the date in the yyyyMMdd format from the javascript calendar in an html file to the php in a another file which then searches a MySQL database. For...
0
by: Matthew Page | last post by:
I am trying to pass a message to a userform in VBA. I will include the code of what I have so far below. The problem I am having is that I don't know what I need to send in order to get the text I...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
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...

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.