For example, i have 2 frame, one in left side and one in right side.
for the right side frame, i can;t alter the code in the right frame and i just know
it have a textbox id=customer
then i want to write a left frame by myself and when i click the button,
the right frame textbox word will change as what I set.
Is it possible?
17 3153 acoder 16,027
Recognized Expert Moderator MVP
Welcome to TSDN!
Yes, it is possible. See this link. If you get stuck, post your code.
It not works...help...
This one is the index.htm file
[HTML]<HTML>
<HEAD>
<TITLE>main</TITLE>
</HEAD>
<FRAMESET cols="20%, 80%">
<FRAME name=left src="main.htm">
<FRAME name=right src="aaaaa.htm">
</FRAMESET>
</html>
[/HTML]
This one is main.htm
[HTML]<button
onclick="parent.right.document.getElementById('cel lright').innerHTML=
'New words'">
Change</button>
[/HTML]
This one is the file aaaaa.htm
[HTML]<input type="text" size="14" id="cellright" value="Hello"></input>[/HTML]
For aaaaa.htm, I don;t want to modify it...but when i click the button in main.htm..it suppose the textbox in aaaaa.htm should change from "Hello" to "New words"...HELP.
thanks.
acoder 16,027
Recognized Expert Moderator MVP
Change the code to:[HTML]<button onclick="parent.right.document.getElementById('cel lright').value='New words'">Change</button>[/HTML]
I try to make the gmail.com as the right frame, and there have a textbox username and password...for the password textbox..it id is "Passwd".
So in left frame, i use
[HTML]<button onclick="parent.right.document.getElementById('Pas swd'). value='1234567'">add pwd</button>[/HTML]
But it not works? Why?
acoder 16,027
Recognized Expert Moderator MVP
The frame is from a different domain. Try a page from the same domain.
We can;t do anything if it is from a different domain?
acoder 16,027
Recognized Expert Moderator MVP
We can;t do anything if it is from a different domain?
Well, you may find one or two workarounds, but no, because of security restrictions, cross-domain scripting is not possible.
Is there any ways we can make something to help us input information to
textbox which in different domain?
gits 5,390
Recognized Expert Moderator Expert
hi ...
moved from js-article-section to the forum-section ... please don't post questions in the articles-section ...
kind regards
Is there any ways we can make something to help us input information to
textbox which in different domain?
Be specific little bit more!
Kind regards,
Dmjpro.
acoder 16,027
Recognized Expert Moderator MVP
Is there any ways we can make something to help us input information to
textbox which in different domain?
This is not possible due to security restrictions. See this link.
I try to make the gmail.com as the right frame, and there have a textbox username and password...for the password textbox..it id is "Passwd".
So in left frame, i use
[HTML]<button onclick="parent.right.document.getElementById('Pas swd'). value='1234567'">add pwd</button>[/HTML]
However it not works....i have been told the problem is because the script will work only if it in the same domain.
I want to ask is there any others ways i can do for it?
thanks very much.
I try to make the gmail.com as the right frame, and there have a textbox username and password...for the password textbox..it id is "Passwd".
So in left frame, i use
[HTML]<button onclick="parent.right.document.getElementById('Pas swd'). value='1234567'">add pwd</button>[/HTML]
However it not works....i have been told the problem is because the script will work only if it in the same domain.
I want to ask is there any others ways i can do for it?
thanks very much.
You are sure that the password field is Passwd?
I think you are sure.
And I assume that right frame name is right.
Now try this, I think it will work...........! -
parent.document.frames['right'].document.getElementById('Passwd').value='1234567';
-
Good Luck!
Kind regards,
Dmjpro.
it not works..............
gits 5,390
Recognized Expert Moderator Expert
hi ...
as it was said :) ... for security reasons you cannot do cross-site-scripting ...
kind regards
hi ...
as it was said :) ... for security reasons you cannot do cross-site-scripting ...
kind regards
What an Idea Gits!
I went through in normal way but failed.
How does this Browser decide that cross you do Cross-Site Scripting?
Please answer me.
Kind regards,
Dmjpro.
gits 5,390
Recognized Expert Moderator Expert
hi ...
read the information behind the link
that acoder posted already ...
kind regards
Sign in to post your reply or Sign up for a free account.
Similar topics |
by: Ori |
last post by:
Hi!
This is my problem...
I have two frames. one which is my website (top frame), and the other
is someone else website. I want to simulate a submit in the other
website (lower frame)when a...
|
by: google |
last post by:
I have a HTML file that contains an iframe. The HTML file is served
by one server. The iframe contains a link to a completely different
server. My question is, can any action in the iframe (such...
|
by: A. Jamie Cuticchia |
last post by:
I have a webpage with 2 frames. Each frame accesses a different URL.
When I try to run a javascript from Frame 1 to access content in Frame
2, I get a forbidden error.
Is there a solution to...
|
by: Chip |
last post by:
Here's the problem: I need to look up records from Library of Congress and
associate the data to a book in my database.
Here's how I think it should work. Open the Library of Congress search page...
|
by: Bruno |
last post by:
I have a feature that is hosted on a different domain from the primary one
in a frame, and need to retain values in a cookie.
example: A web page at one.com contains a frame which has a page...
| |
by: J |
last post by:
Hello. I apologize if this isn't the appropriate group for this question
but I was wondering if it's possible to allow regular windows domain users
to change their passwords through an .asp page? ...
|
by: smerf |
last post by:
Using javascript, is there a way to trap an external page inside a frame?
I've seen scripts to break out of frames, but nothing to keep a page trapped
in a frame.
|
by: redgoals |
last post by:
Hi All,
I will be creating a white label website for car hire dealers. My main website will be called something like: carhire.com, the content on carhire.com will be pulled in from a database.
...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
|
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...
| |
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...
|
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...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The...
|
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 ...
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
|
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...
| |