跨域从浏览器存储读取数据 [英] cross domain reading data from browser storage

查看:524
本文介绍了跨域从浏览器存储读取数据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试使用jStorage和jQuery将具有唯一ID的数据存储到浏览器的存储中,从 a.com 开始。然后我尝试使用从 b.com 的唯一ID读取数据。但 jStorage.get('UniqueID')无法显示所需的输出。

I am trying to store data with a unique ID into the browser's storage, from say a.com using jStorage and jQuery. I am then trying to read the data using the unique ID from, say b.com. But jStorage.get('UniqueID') is not working, and it's not showing the desired output.

任何人帮助我阅读浏览器存储跨域?

Can anyone help me with reading browser storage cross-domain?

推荐答案

本文有一些与跨域存储相关的信息。它提供了使用iframe访问另一个域的 localStorage 对象的基本技术。

This article has some information related to cross-domain storage. It offers "the basic technique of using an iframe to access another domain's localStorage object."

这篇关于跨域从浏览器存储读取数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆