douqufan9148 2015-12-30 21:50
浏览 23
已采纳

web-host没有读取PHP代码

Sorry if this is a simple question, but I have been having some problems with my website. I have used both HostGator and Godaddy to host my site. But on both site I have been getting a consistent problem, image: http://postimg.org/image/optvm8qy7/ (sorry for links i did not want to clog up the page).

My problem, or what I think that my problem, is that my default file that we website reads is index.php. I know that that is usable and it dose work on my localhost server. But the index.php file contains both php and html code inside it: http://postimg.org/image/79eyw0fvt/ (once again sorry for the link and not an image on the page).

So what I am Thinking is that for some reason the Web host cant read the php code or is reading it as regular text. Because as you can see the title of the webpage is meant to say "Jackpot Battles", but it says <?php echo $tital; ?>. The thing is that it will read the rest of the files and the website correctly just not any php.

If anyone has any ideas on what could be causing this, or would like any extra information please leave a comment.

Thank you for your time.

  • 写回答

1条回答 默认 最新

  • dslk6326846 2015-12-30 21:56
    关注

    It looks like the default page for your host is index.html. While index.php might be on the list, because you have an index.html file it is pointing to that. If you delete or rename index.html it will likely work. I can view what looks to be the correct data by going to http://jackpotbattles.pw/index.php

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 组策略中的计算机配置策略无法下发
  • ¥15 如何绘制动力学系统的相图
  • ¥15 对接wps接口实现获取元数据
  • ¥20 给自己本科IT专业毕业的妹m找个实习工作
  • ¥15 用友U8:向一个无法连接的网络尝试了一个套接字操作,如何解决?
  • ¥30 我的代码按理说完成了模型的搭建、训练、验证测试等工作(标签-网络|关键词-变化检测)
  • ¥50 mac mini外接显示器 画质字体模糊
  • ¥15 TLS1.2协议通信解密
  • ¥40 图书信息管理系统程序编写
  • ¥20 Qcustomplot缩小曲线形状问题