为什么 jQTouch 不能在我的本地主机上工作?

发布于 2024-09-17 07:01:09 字数 177 浏览 3 评论 0 原文

我正在我的本地主机上尝试 jQTouch 演示。点击“提交”后我没有得到任何回复。我在 Google 上搜索了该问题,只找到了这个链接文本,但它不起作用。

I was trying out the jQTouch demos on my localhost. I couldn't get any response after clicking on "Submit". I Googled the problem and only found this link text but it doesn't work.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

小情绪 2024-09-24 07:01:09

只需记住在 .htaccess 文件中添加 ajax 文件(例如 ajax_post.php)即可。干杯!

RewriteCond $1 !^(index\.php|javascript|**ajax_post\.php**|robots\.txt|captcha)

Just remember to add the ajax file(such as ajax_post.php) in the .htaccess file. Cheers!

RewriteCond $1 !^(index\.php|javascript|**ajax_post\.php**|robots\.txt|captcha)
空袭的梦i 2024-09-24 07:01:09

同源策略 阻止本地主机 AJAX 请求,因为请求和响应的域是不同的。要解决此问题,使用 IP 地址禁用该策略,或添加 Access-Control-Allow-Origin : * 响应头。

The same-origin policy prevents localhost AJAX requests since the domains of the request and the response are different. To workaround this, use the IP Address, disable the policy, or add the Access-Control-Allow-Origin: * header to the response.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文