weixin_33713503 2014-11-14 21:21 采纳率: 0%
浏览 88

在CDN上托管Ajax PHP文件?

I've been working on a Ajax function on my website hosted on godaddy. My Ajax function requires me to open the port 8192. I tried contacting godaddy but they just told me that they are unable to open any port for security reasons.

I've tried finding a solution for a good couple of hours now. From what I've read its supposed to be possible to host the ajax php file on a cdn. I came across AWS CloudFront and their Bucket Storage, but apparently they only support static pages like css and so.

Is there any way for me to host my PHP Ajax file outisde of my main web hosting?

  • 写回答

1条回答 默认 最新

  • ℙℕℤℝ 2014-11-15 01:54
    关注

    First, to answer your question, CDN's host only your static content (CSS, JS, SWF, IMG files...)

    You can't have an open port for you in any shared hosting plan including Godaddy and others.

    You need a root access in order to allow connections via port 8192, the solution is to acquire a VPS or Dedicated hosting. VPS preferred for your case.

    You can install Apache/Nginx, PHP in your Linux VPS, configure the web server to accept connections via port 8192, and also allow it in the iptables, then host your PHP file, and you can access it : http://SERVER_IP_OR_NAME.TLD:8192/ajax_file.php

    OVH offers very cheap VPS starting price $2.99 /month, or Digitalocean $5 /month, if you prefer Amazon Web Service, they provide Cloud server the service is named Amazon EC2, and you can obtain a cloud server first year free of charge.

    评论

报告相同问题?

悬赏问题

  • ¥15 关于#python#的问题:求帮写python代码
  • ¥20 MATLAB画图图形出现上下震荡的线条
  • ¥15 LiBeAs的带隙等于0.997eV,计算阴离子的N和P
  • ¥15 关于#windows#的问题:怎么用WIN 11系统的电脑 克隆WIN NT3.51-4.0系统的硬盘
  • ¥15 来真人,不要ai!matlab有关常微分方程的问题求解决,
  • ¥15 perl MISA分析p3_in脚本出错
  • ¥15 k8s部署jupyterlab,jupyterlab保存不了文件
  • ¥15 ubuntu虚拟机打包apk错误
  • ¥199 rust编程架构设计的方案 有偿
  • ¥15 回答4f系统的像差计算