Angular 2: 404 error occur when I refresh through the browser [duplicate]
https://stackoverflow.com/questions/35284988/angular-2-404-error-occur-when-i-refresh-through-the-browser
#前端#
修改app.module.ts
import { HashLocationStrategy, LocationStrategy } from '@angular/common';
providers: [
{ provide: LocationStrategy, useClass: HashLocationStrategy }
],
修改root-routing.module.ts
imports: [RouterModule.forRoot(routes, { useHash: true })],
Angular 2: 404 error occur when I refresh through the browser [duplicate]的更多相关文章
- angular.js:13920 Error: [$injector:unpr] Unknown provider: $scopeProvider <- $scope <- testServe
angular.js:13920 Error: [$injector:unpr] Unknown provider: $scopeProvider <- $scope <- testSer ...
- How to create your own custom 404 error page and handle redirect in SharePoint 分类: Sharepoint 2015-07-08 00:22 4人阅读 评论(0) 收藏
1. In your MOSS server, make a copy of %systemdrive%\Program Files\Common Files\Microsoft Shared\Web ...
- Handling HTTP 404 Error in ASP.NET Web API
Introduction: Building modern HTTP/RESTful/RPC services has become very easy with the new AS ...
- Posting data to a HttpHandler greater then ~29MB gives a 404 error
1down votefavorite 1 I am testing a HttpHandler that accepts XML. It works fine when a small amount ...
- Server response error code:404, error:{"ret":-1, "msg":"invalid appkey"}
Server response error code:404, error:{"ret":-1, "msg":"invalid appkey" ...
- [DUBBO] Unexpected error occur at send statistic, cause: Forbid consumer 192.168.3.151 access servic
[DUBBO] Unexpected error occur at send statistic, cause: Forbid consumer 192.168.3.151 access servic ...
- Win10上启动UICrawler自动遍历时报 "org.openqa.selenium.WebDriverException: An unknown server-side error occur red while processing the command. Original error: Could not sign with default certifi cate."
操作步骤: 1.直接启动 Appium (我用的是 version 1.10.0) 2.打开命令窗口,切换到 UICrawler 所在路径 3.执行命令 java -jar UICrawler-2.2 ...
- Openning SharePoint - 80 website gives HTTP 404 Error, The webpage cannot be found ! on SharePoint 2013
ask: I tried to open the SharePoint - 80 throw Browse in IIS, but I get HTTP 404 Error (The webpage ...
- 404 error on preview ... "buffer_id(29) is not valid (closed or unsupported file format)"
利用sublime text2的插件OmniMarkupPreview进行md文件预览时,出现如下错误 "Error: 404 Not Found Sorry, the requested ...
随机推荐
- Linux3一些文件操作命令more,less,pr,head,tail,wc
查看文件内容命令: more和less 用cat命令可以查看文件.有时候文件太大,可以用管道符号|配合more或者less一同使用. cat <文本文件名称>|more cat < ...
- 张超超OC基础回顾02_成员变量(属性),局部变量,全局变量的区别
成员变量: 写在类声明的大括号中的变量, 我们称之为 成员变量(属性, 实例变量) 成员变量只能通过对象来访问 注意: 成员变量不能离开类, 离开类之后就不是成员变量 成员变量不能在定义的同时进行初始 ...
- golang学习
1. 学习资源列表 https://github.com/golang/go/wiki 2. 最快的入门方法 直接通过代码学习 https://tour.go-zh.org 3. go指南 https ...
- Python pandas.DataFrame调整列顺序及修改index名
1. 从字典创建DataFrame >>> import pandas >>> dict_a = {'],'mark_date':['2017-03-07','20 ...
- Classification and Prediction
# coding: utf-8 # In[128]: get_ipython().magic(u'matplotlib inline') import pandas as pd from pandas ...
- Django-Web框架之创建项目和应用
Django我们是基于python3来演示的.首先我们来安装一下django框架.使用pip3 install django安装的是最新的版本: 我们在pycharm中创建django工程.如图所示: ...
- javascript总结4:javascript常见变量
1 javascript变量 定义:变量在计算机中,是用于存储信息的"容器". 2 使用方法: 2-1 定义变量: var n1; 2-2 变量赋值: var n2=23.45; ...
- Spring MVC:Model、View、ModelAndView
个人理解:View为服务器上的某个文件容器,可以为JSP,FTL等动态页面文件,甚至是媒体文件等等,单单是一个文件.Model的作用是存储动态页面属性,动态页面文件即View可以在Model中获取动态 ...
- angular 守卫路由
import { NgModule } from '@angular/core'; import { Routes, RouterModule } from '@angular/router'; im ...
- vs2015+opencv3.3.1 实现 c++ 双边滤波器(Bilateral Filter)
#include <opencv2\highgui\highgui.hpp> #include <iostream> #include<vector> using ...