tricky form post issue

Associate
Joined
16 Feb 2008
Posts
307
Location
Staffordshire
Scenerio:

I have a search box in a nav bar which does the following:

It sends the search string by POST to another domain and then displays the results in a Iframe on the same page. All works perfectly.

Problem:

there are pages within the site that have no Iframe, just the usual terms,delivery info etc.
Obviously when the search string is submitted from these pages there is no iframe to display the result.

Forget the target attributes of _blank _self etc as this loses all the design and the result is just a list of results.

What I want to happen:

when the search string is posted from a html page containing NO Iframe, I want the returning results to be displayed in an Iframe on another html page that does.

Ive done some googling but no real solid ideas out there.
I presume Iam looking at php, so point me in the right direction please.

thanks
 
Soldato
Joined
3 Jun 2005
Posts
3,066
Location
The South
Could you not use a JQuery modal dialog (most support iFrames or AJAX), like ColorBox, and use that to display the search results data? Any links from that results page could then be 'fired' back to the parent window.
I've used something similar a few times in the past and it works well.
 
Associate
OP
Joined
16 Feb 2008
Posts
307
Location
Staffordshire
Unfortunatley unable to use that approach as it causes security issues due to cross site scripting.

Basically I am sending a search query from the site via POST in a form.
In turn this query is directed to an URL on the remote site, the remote then spits out the results which I display in an Iframe contained within a DIV.

Works with no issues IF the Iframe is on the same page which contains the FORM.

All I want to do is have that query returned to another pages Iframe.

I figure this ?

have a script that takes said query then passes it to a page on the local domain containing a Post script which in turn sends the query to the remote site and then displays on the page containing an iframe.

I think I just need the search query passed to the post script and then be able to tell the returning data on what page to be targetted? Yes?

There must be a script out there surely to do this but I cant find one anywhere.

Any more thoughts?
 
Back
Top Bottom