what is the codes used to do that job?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Mahooby
    New Member
    • Jun 2010
    • 4

    #1

    what is the codes used to do that job?

    i want to know the codes used to do function as follow:

    link the text i type in my textbox of my page with textbox of of preloaded live webpage.
    where what i type in my text box is autotyped instaneously in the text box of online webpage.

    regards,
    mahamoud
    Last edited by Dormilich; Jun 16 '10, 05:55 AM. Reason: removed email address
  • Dormilich
    Recognized Expert Expert
    • Aug 2008
    • 8694

    #2
    are those text boxes on the same page or are you talking about textboxes on different pages?

    Comment

    • Mahooby
      New Member
      • Jun 2010
      • 4

      #3
      they are in different pages

      please see that:


      ,regards
      Mahmoud Ahmed

      Comment

      • NKTA
        New Member
        • Jan 2010
        • 26

        #4
        And check this also, it concerns to your problem, and also mine, trying to use DOM to access another page.
        Search ...

        Comment

        • gits
          Recognized Expert Moderator Expert
          • May 2007
          • 5390

          #5
          and as you might have noticed in your linked thread already - if there are different domains involved it is not possible with javascipt alone - due to the same origin policy ...

          Comment

          • NKTA
            New Member
            • Jan 2010
            • 26

            #6
            Yeap, but in my case, its 2 page in the same doamin, and still using DOM is not possible. Gives error.
            The 2 pages are located in the same place in the disk, i intended to re-use the format from one page and add some objects to it.

            I solved by using
            Code:
            someVar = window.open(...);
            var tmp = someVar.document;
            tmp.write(' and in here i have put the HTML code of my page ');
            for(var ...){
               // search the objects and then 
               tmp.write('write the objects');
            }
            Dont like to much of this idea, since any change to HTML, how small it is, requires to go to the source of javascript and change it there too.

            But it ain't my rules, lets just coope with it ...

            Comment

            • NKTA
              New Member
              • Jan 2010
              • 26

              #7
              I have another question...


              If i define the whole intire page including declairing the scripts it as i have stated, is it possible to call a function in the second page opened ?

              The only reference to that page i have is the variable in which i have declared the new window => someVar, so can i do something like:
              someVar.functio nToCall();
              or
              someVar.documen t.functionToCal l();
              Or is it restricted, to even being in the sae origin ?

              BR

              Comment

              Working...