Submit form in another frame

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Ori

    #1

    Submit form in another frame

    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 user is clicking on a button in my site
    (the top frame).

    Can i do it?
  • Lasse Reichstein Nielsen

    #2
    Re: Submit form in another frame

    orianavim@hotma il.com (Ori) writes:
    [color=blue]
    > 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 user is clicking on a button in my site
    > (the top frame).
    >
    > Can i do it?[/color]

    No.
    Tha standard security model in browsers will not allow cross domain
    scripting.

    If the page is just for personal use and your browser is IE, you can
    look into HTML-applications (Google for HTA).

    /L
    --
    Lasse Reichstein Nielsen - lrn@hotpop.com
    DHTML Death Colors: <URL:http://www.infimum.dk/HTML/rasterTriangleD OM.html>
    'Faith without judgement merely degrades the spirit divine.'

    Comment

    • Richard Cornford

      #3
      Re: Submit form in another frame

      "Ori" <orianavim@hotm ail.com> wrote in message
      news:b431a203.0 312221712.11ce7 965@posting.goo gle.com...
      <snip>[color=blue]
      >I have two frames. one which is my website (top frame),
      >and the other is someone else website. ...[/color]
      <snip>[color=blue]
      >Can i do it?[/color]

      No. Browser security requires that scripts originating on one domain are
      not allowed access to the DOMs of pages from a different domain. There
      is just too much potential for abuse if they were.

      Richard.


      Comment

      • Lucanus

        #4
        Re: Submit form in another frame

        You might be able to do something like that by tearing the target form
        apart.

        If you are somewhat conversant with forms, you could create a URL
        string which would simulate the form being submitted.

        ie If your site is hosted at www.host1.com and the target site has a
        page which submits to www.host2.com/processor with the following
        inputs FirstName, Surname, PhoneNumber.
        You can hardcode a link which will act like a submission of that page
        like
        the following:


        That link can then be targetted at whatever frame you want.

        NOTE: I have only tested this within my work's intranet, so there is
        no difference in Domain Names, as such, I cannot comment on whether
        this solution is the best for your application.

        Luke

        Comment

        Working...