jquery - Possible to give Ajax Permission to site not in Same Origin? -


i'm trying take p - example - element 1 of websites on server 1
, insert inside <div id="insert"></div> element website on server 2

i'm trying using load function
$( '#insert' ).load('server1.com/index #take p')

issue is: enter image description here

since have access both servers, there anyway allow these request happen?

what looking cross origin http request. can read here.

you may able accomplish want adding following .htaccess file:

<ifmodule mod_headers.c>     header set access-control-allow-origin: http://example.com </ifmodule> 

but read through link more details.


Comments

Popular posts from this blog

How to understand 2 main() functions after using uftrace to profile the C++ program? -

c# - Update a combobox from a presenter (MVP) -

How to put a lock and transaction on table using spring 4 or above using jdbcTemplate and annotations like @Transactional? -