The requested URL /home/profession was not found on this server.

通过xxx.com, 首页可以正常访问,xxx.com/xx/xx 就出现 The requested URL xxx was not found on this server.

1,找到apache配置文件httpd.conf配置文件中的

AllowOverride none
Require all denied

改成

Options Indexes FollowSymLinks
AllowOverride All

2,找到apache配置文件httpd.conf配置并开启重写模块

LoadModule rewrite_module modules/mod_rewrite.so 

Ubuntu16.04模块在  /etc/apache2/mods-available 下,需要链接到  mods-enable 下

ln -s /etc/apache2/mods-available/rewrite.load /etc/apache2/mods-enabled/rewrite.load

3.加在重写,站点缺少 .htaccess 文件(文件在public下,没有就新建)

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>


新部署到服务器 报 The requested URL /home/profession was not found on this server. 错误的更多相关文章

  1. 【每日学习】Apache重写未开启,导致The requested URL /xxxx.html was not found on this server

    今天把项目环境从集成换成独立的,全部搭建好后,网站主页www.xxx.com能打开,但一涉及到跳转,带参数,比如 www.xxx.com/xxx/xxx.html 就会报错 The requested ...

  2. The requested URL /xxxx.html was not found on this server

    The requested URL /xxxx.html was not found on this server 的原因是,Apache没有开启重写 apache 打开 httpd.conf 文件找 ...

  3. windows 部署 git 服务器报 Please make sure you have the correct access rights and the repository exists.错误

    这两天在阿里云上弄windows 服务器,顺便部署了一个git服务.根据网上教程一步步操作下来,最后在 remote远程仓库的时候提示 fatal: 'yourpath/test.git' does ...

  4. webservice部署到服务器报错

    System.Net.WebException: 基础连接已经关闭: 发送时发生错误. ---> System.IO.IOException: 从传输流收到意外的 EOF 或 0 个字节. 在 ...

  5. linux下配置lamp时候出现The requested URL /info.php was not found on this server问题

    在经历修改各种配置文件和各种文件权限后,发现了怎么解决 On newer versions of Ubuntu, the document root is set to /var/www/html i ...

  6. (原)使用TortoiseGit提交代码push的时候报错:HTTP 413 curl 22 The requested URL returned error: 413 Request Entity Too Large

    今天我想rk的sdk包里面的一些东西提交到我的git服务器上,结果,总是报错,折腾了一下午,结果才解决. 首先看看我提交代码的时候,报错的信息: git.exe push --progress &qu ...

  7. Object not found! The requested URL was not found on this server.... 报错解决方案

    服务器(centos6.5) lnmp 报错如下 Object not found! The requested URL was not found on this server. The link ...

  8. 配置ssh框架启动tomcat服务器报异常Unable to create requested service [org.hibernate.engine.jdbc.env.spi.JdbcEnvironment]

    在Spring中配置jdbc时,引用的是dbcp.jar包,在db.properties配置文件中,使用了之前的properties配置文件的用户名username(MySql用户名) 然后在启动服务 ...

  9. php ci 报错 Object not found! The requested URL was not found on this server. If you entered the URL manually please check

    Object not found! The requested URL was not found on this server. The link on the referring page see ...

随机推荐

  1. JS监听video视频播放时间

    采用原生时间监听element.addEventListener(event, function, useCapture) //监听播放时间 var video = document.getEleme ...

  2. java、mysql、oracle、pgsql数据类型对应关系

    看不清 请 Ctrl+鼠标滚轮     放大页面

  3. canvas的其他应用

    画布的基础知识 专门研究画布的大佬 手动实现echar的大佬 echar官方 画布之水印 ctx.font = "bold 20px Arial"; ctx.lineWidth = ...

  4. Day9 - D - Piggy-Bank POJ - 1384

    Before ACM can do anything, a budget must be prepared and the necessary financial support obtained. ...

  5. nosql概叙

    关系型数据库管理系统:按照预先设置的组织架构,将数据存储在物理介质上 数据之间可以做关联操作

  6. Matplotlib 图形绘制

    章节 Matplotlib 安装 Matplotlib 入门 Matplotlib 基本概念 Matplotlib 图形绘制 Matplotlib 多个图形 Matplotlib 其他类型图形 Mat ...

  7. HDFS 命令行基本操作

    1.hdfs命令行 (1)查看帮助 hdfs dfs -help (2)查看当前目录信息 hdfs dfs -ls / (3)上传文件 hdfs dfs -put /本地路径 /hdfs路径 (4)剪 ...

  8. 织梦 dede runphp=yes SQL语句操作

    个人实例dede:channelartlist 下循环出 channel 栏目 中的 文章 {dede:sql sql='select * from dede_arctype where reid = ...

  9. 牛客小白月赛3---G 旅游(树形dp)

    题目链接:https://www.nowcoder.com/acm/contest/87/G 分析: 1.对于点cur,dp[cur][0]表示在该点住宿:dp[cur][1]表示其某个子结点住宿,自 ...

  10. 065、Java面向对象之定义一个Book类,在主类中使用Book类

    01.代码如下: package TIANPAN; class Book { // 定义一个新的类 String title; // 书的名字 double price; // 书的价格 public ...