当前位置: 动力学知识库 > 问答 > 编程问答 >

routing - How to use php pages in templateurl in stateprovider of angularjs

问题描述:

I used the stateprovider with an html page.

$stateProvider

.state('about', {

url: '/about',

templateUrl: 'pages/about.html

});

But i changed the about file to about.php and also in the code below.

$stateProvider

.state('about', {

url: '/about',

templateUrl: 'pages/about.php

});

It still seems to link to about.html somehow, because if I delete the about.html and keep about.php it is not working

Im wondering how I can use the .php file extention in the stateprovider.

EDIT:

Okay so this does work on my personal hosting space but not on external hosting on one.com. Any idea how to fix this?

分享给朋友:
您可能感兴趣的文章:
随机阅读: