473,545 Members | 1,745 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

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 1473
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="framese t.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.ht m?'
+location.searc h.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
8989
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 variables and adds them to my url. <script type="text/javascript"> //<!]> </script>
1
2402
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 GENERATED BY FUNCTION. Here'e the point: I'm writing a simple website for showing my photographs. It has a central page with many links (as many as...
29
4963
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 window properly but does not pass the parameter. (this is part of a coldfusion template) <a href="##"
1
11852
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 (Left, Content, and Footer) In the content page, I have a checkbox, which value is a number (i.e. 500). I would like that, when a user clicks on this...
14
1595
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 wish to visit from the first page, after pressing go it takes you to a frame page.
2
1505
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 window. I am wanting to capture the URL in the top frame where the PDFs are displayed and update the URL of the URL/pdf to be +1 or -1. Example of top frame...
2
5874
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 some reason the sendPhp is not working. I need to send
0
1089
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 want to appear in the textfield that I want it to appear in. Here is the code... Private Const WM_SETTEXT As Long = &HC Private Declare...
0
7390
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
7647
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
1
7410
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7742
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
1
5318
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
4940
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3436
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1865
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
0
692
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

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.