|
|
|
|
|
для: hate
(04.09.2006 в 00:43)
| | Взял как раз то что вам нужно, с одного сайта.
В гугле нашел:
<!-- THREE STEPS TO INSTALL PASS TEXTBOX (IN FRAMES):
1. Copy the entire first code section into your FRAMESET document
2. Save the second code into a new page, pass-textbox-framesl.html
2. Paste the second code into a new page, pass-textbox-framesr.html -->
<!-- STEP ONE: Paste this entire code into your FRAMESET page -->
<html>
<head>
<script language="JavaScript">
<!-- Original: Ronnie T. Moore -->
<!-- Web Site: The JavaScript Source -->
<!-- This script and many more are available free online at -->
<!-- The JavaScript Source!! http://javascript.internet.com -->
<!-- Begin
function passText(str) {
top.frames['right'].document.yourform.msg.value = str;
}
// End -->
</script>
</head>
<frameset cols="300,*" frameborder=1>
<frame name="left" src="pass-textbox-framesl.html">
<frame name="right" src="pass-textbox-framesr.html">
</frameset>
</form>
</body>
</html>
<!-- STEP TWO: Copy this code into a new page -->
<!-- Save the page as: pass-textbox-framesl.html -->
<html>
<body>
<center>
<form name=myform>
Enter Your Name:<br>
<input type=text name=user size=10 value="">
<input type=button value="Ok!" onClick="parent.passText(this.form.user.value);">
</form>
</center>
</body>
</html>
<!-- STEP THREE: Copy this code into a new page -->
<!-- Save the page as: pass-textbox-framesr.html -->
<html>
<body>
<form name=yourform>
<input type=text name=msg size=10 value="">
</form>
</body>
</html>
<p><center>
<font face="arial, helvetica" SIZE="-2">Free JavaScripts provided<br>
by <a href="http://javascriptsource.com">The JavaScript Source</a></font>
</center><p>
<!-- Script Size: 1.38 KB -->
|
Demo: http://javascript.internet.com/forms/pass-textbox-frames-demo.html | |
|
|
|
|
|
|
| Собственно вопрос.. Есть два фрэйма, проименованные как "page" и "link"
При нажатии на ссылку из "link" нужно вставить значение в textfield фрэйма "page"
<SCRIPT language=Javascript type=text/javascript>
<!--
function puttag(tag) {
??????????.document.inputform.links.focus();
??????????.document.inputform.links.value += tag;
}
//-->
</SCRIPT>
<? ... всякий код
<a onclick=\"puttag('<$id> $title');\" href='javascript:void(0)'>Добавить</a>
... и тд
|
Памагите заменить ?????????? на нужное, или вообще помогите =) | |
|
|
|
|