By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,680 Members | 1,475 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,680 IT Pros & Developers. It's quick & easy.

cross-domain

P: n/a
Hello.

Can anyone help with cross-domain problem?
I have HTML page from server1 that send xmlHTTPRequest to server2.

How can I do it?

Thanks.
Oct 18 '08 #1
Share this Question
Share on Google+
6 Replies


P: n/a
SAM
Le 10/18/08 11:32 PM, ampo a écrit :
Hello.

Can anyone help with cross-domain problem?
I have HTML page from server1 that send xmlHTTPRequest to server2.

How can I do it?
You send your XHR to the server of your domain.
The PHP (or other language) on this server will call and get the infos
on the other server.

--
sm
Oct 18 '08 #2

P: n/a
ampo wrote:
Can anyone help with cross-domain problem?
I have HTML page from server1 that send xmlHTTPRequest to server2.
How can I do it?
You might be interested in Ajax Cross Domain:

http://www.ajax-cross-domain.com/

--
Bart
Oct 19 '08 #3

P: n/a
Bart Van der Donck wrote:
ampo wrote:
>Can anyone help with cross-domain problem?
I have HTML page from server1 that send xmlHTTPRequest to server2.
How can I do it?

You might be interested in Ajax Cross Domain:

http://www.ajax-cross-domain.com/
CAVEAT: Each and every bit of information sent and retrieved using this
method goes over a third-party server!

While it is rather easy to set up server-side URL rewrite on one's own
server, even without any knowledge of server-side scripting.
PointedEars
--
realism: HTML 4.01 Strict
evangelism: XHTML 1.0 Strict
madness: XHTML 1.1 as application/xhtml+xml
-- Bjoern Hoehrmann
Oct 20 '08 #4

P: n/a
ampo wrote:
Can anyone help with cross-domain problem?
I have HTML page from server1 that send xmlHTTPRequest to server2.

How can I do it?
First of all, this could be a digital rights issue. Make sure that you have
*written* authorization to use content of others in your Web site before you
use it.

Second, you can use either server-side URL rewrite, such as
<http://httpd.apache.org/docs/2.0/misc/rewriteguide.htmlor a server-side
proxy script *on your server*.
PointedEars
--
var bugRiddenCrashPronePieceOfJunk = (
navigator.userAgent.indexOf('MSIE 5') != -1
&& navigator.userAgent.indexOf('Mac') != -1
) // Plone, register_function.js:16
Oct 20 '08 #5

P: n/a
Thomas 'PointedEars' Lahn wrote:
Bart Van der Donck wrote:
>ampo wrote:
>>Can anyone help with cross-domain problem?
I have HTML page from server1 that send xmlHTTPRequest to server2.
How can I do it?
>You might be interested in Ajax Cross Domain:
*http://www.ajax-cross-domain.com/

CAVEAT: Each and every bit of information sent and retrieved using this
method goes over a third-party server!
The default installation works with a web page that calls /cgi-bin/
ACD.js on the same website (though the .js may also reside on another
domain). ACD.js then does the request to the remote server. For
example:
http://www.ajax-cross-domain.com/#Synopsis
http://www.ajax-cross-domain.com/runit/1.htm
Two domains involved: the caller (ajax-cross-domain.com) and the
remote site (google.com).

Maybe the text "or as managed service on ajax-cross-domain.com" had
created this confusion:
http://www.ajax-cross-domain.com/#Flowchart

The default installation is on the same website though:
http://www.ajax-cross-domain.com/#Installation
While it is rather easy to set up server-side URL rewrite on one's own
server, even without any knowledge of server-side scripting.
That would be a suitable alternative, yes.

--
Bart
Oct 21 '08 #6

P: n/a
Bart Van der Donck wrote:
Thomas 'PointedEars' Lahn wrote:
>Bart Van der Donck wrote:
>>ampo wrote:
Can anyone help with cross-domain problem?
I have HTML page from server1 that send xmlHTTPRequest to server2.
How can I do it?
You might be interested in Ajax Cross Domain:
http://www.ajax-cross-domain.com/
CAVEAT: Each and every bit of information sent and retrieved using this
method goes over a third-party server!

The default installation works with a web page that calls /cgi-bin/
ACD.js on the same website (though the .js may also reside on another
domain). ACD.js then does the request to the remote server. For
example:
http://www.ajax-cross-domain.com/#Synopsis
http://www.ajax-cross-domain.com/runit/1.htm
Two domains involved: the caller (ajax-cross-domain.com) and the
remote site (google.com).
Nevertheless, those who have a domain of their own usually don't need your
script (as they can put .htaccess and friends), and those who don't have a
domain usually can't run your script on their server (who can't/won't afford
a domain usually can't get CGI and friends because there are just not enough
ads that would pay for it).

So the latter group should be made aware that all their requests and
responses can be spied^Wlogged on, either by you (no offense meant, but a
statement of confidentiality is missing from your documentation), or a
man-in-the-middle because the connection is only partially encrypted (from
your server to the target host) at best.

There is also the inherent insecurity of passing sensitive data in URIs to
consider, since they end up in the local history and caches, proxy caches,
and default Web server logs. Not to mention the limitation of data to be
transmitted because browsers (and particularly that of the browser with
still the greatest market share, like it or not); BTW, that limit is at 2083
characters per URI in IE, not 2048.

Given these facts, I have to question the overall usefulness of your
script/service, even if your intentions may be good.
PointedEars
--
realism: HTML 4.01 Strict
evangelism: XHTML 1.0 Strict
madness: XHTML 1.1 as application/xhtml+xml
-- Bjoern Hoehrmann
Oct 22 '08 #7

This discussion thread is closed

Replies have been disabled for this discussion.