www.webdeveloper.com
Results 1 to 2 of 2

Thread: please somebody help me out!

  1. #1
    Join Date
    Jan 2010
    Posts
    73

    please somebody help me out!

    ++++++++++++++++++++++++++first window+++++++++++++++++++++++++++
    <html>
    <head>
    <script language="javascript">
    var myWindow;
    function christDoes(){
    mydWindow=open("my.html", "yes");
    //myWindow.document.write("i am here");
    }

    function buttonClear(){
    if(subject.value.length>0){
    subject.value="";
    }
    }
    </script>
    </head>
    <body><form><CENTER>
    <B>ENTER YOUR SUBJECT</B><INPUT TYPE="TEXT" NAME="subject">
    <input type="button" name="add" value="ADD">
    <input type="button" name="clear" value="CLEAR" onClick="buttonClear()"><br>
    <input type="button" name="ok" value="OK" onClick="christDoes()">
    </form>
    </body>
    </html>
    ++++++++++++++++++++++++++++first window++++++++++++++++++++++++


    +++++++++++++++++++++++++second window++++++++++++++++++++++++
    <html>
    <head>
    <script language="javascript">
    function displayColor() {
    var fAdd=self.opener.document.forms[0].add
    if(fAdd.click){
    var fMath=self.opener.document.forms[0].subject.value;
    var my=new Array(3);
    if(fMath.length>0){
    my[0]=fMath.toString().fixed().bold().italics();
    document.write(my[0] +"<input type='text' name='my[0].toLowerCase()'value=''>"+"<br>")
    }
    if(fMath.length != my[0]){
    my[1]=fMath.toString().fixed().bold();
    document.write(my[1] +"<input type='text' name='my[0].toLowerCase()' value=''>" +"<br>")
    }
    else{my[1]=""}
    if(fMath.length != my[0] && fMath.length != my[1]){
    my[2]=fMath.toString().fixed().bold();
    document.write(my[2] +"<input type='text' name='my[0].toLowerCase()' value=''>" +"<br>")
    }
    }
    else{my[2]=""}

    }
    </script>
    </head>
    <body onload="displayColor()">
    </body>
    </html>
    +++++++++++++++++++++++++++++second window++++++++++++++++++++++
    Thanks for your help. This is my plight:
    When i input into the tetbox:"subject" in the first window and click the "addButton" it should add the string and a textbox to the second window.
    If i click the "buttonClear", it clears the string from the textbox. Again, if i input another string into the textbox:"subject" of the first window it should add the string and textbox on a new line "<br>" on thesame second window.

    For Example if i entered "name" in textbox "subject"
    And, again after clicking "buttonClear" and input another text:"school" into textbox "subject"

    the output on the second window should be:
    name textbox
    school textbox
    Thank for helping me .God bless.

  2. #2
    Join Date
    Oct 2006
    Posts
    939
    Sometimes with a new idea, you'll scratch the project and start over when you think of a better way than the angle you're on...

    HTML Code:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
    	"http://www.w3.org/TR/html4/strict.dtd">
    <HTML>
    <HEAD><TITLE>We10-35am8</TITLE>
    <META http-equiv=Content-Type content="text/html; charset=UTF-8">
    <STYLE type=text/CSS>
    
    </STYLE>
    <SCRIPT type="text/javascript">
    	var myWindow; var var0; var var1;
    function christDoes(x){ var0=x
       mydWindow=window.open('','mydWindow','top=15px, left=20px, width=400, height=375, location=1, menubar=1, scrollbars=1, toolbar=1, resizable=1, status=1');
    var WKIP='<!DOCTYPE HTML PUBLIC "-\/\/W3C\/\/DTD HTML 4.01\/\/EN"\n"http:\/\/www.w3.org\/TR\/html4\/strict.dtd">\n<HTML>\n<HEAD><TITLE>my<\/TITLE>\n<META http-equiv=Content-Type content="text\/html; charset=UTF-8">\n<STYLE type=text\/CSS>\n<\/STYLE>\n<SCRIPT type="text\/javascript">\nfunction myFunc(){ var ov0=\'hay\';\n if(opener && opener.var0){ov0=\'<input> \'+opener.var0+\'\';}\ndocument.forms[0].innerHTML=\'\'+ov0+\'\'\n}\n<\/SCRIPT>\n<META content="MSHTML 6.00.2900.2963" name=GENERATOR><\/HEAD>\n<body onload="myFunc()">\n<form>hello\n<\/form>\n<\/body>\n<\/html>\n';
    
       mydWindow.document.write(WKIP)
       mydWindow.document.close()
    }
    
    
    </SCRIPT>
    <META content="MSHTML 6.00.2900.2963" name=GENERATOR></HEAD>
    <BODY >
    	<form onsubmit="christDoes(this.elements[0].value);return false" style="text-align:center">
    	 <H2>ENTER YOUR SUBJECT</H2>
    	  <INPUT NAME="subject"><br>
    	  <input type="reset" name="clear" value="CLEAR"><input type="submit" name="ok" value="OK" >
    	</form>
    
    
    </BODY></HTML>

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles