How to change index.html to index.php in ionic?


I want to change the file which is loaded in the starting. i.e index.html to index.php. i changed it with config file

<content src="index.php"/>

But still I am getting the error when i run through command “ionic serve”

Error: ENOENT: no such file or directory, open ‘C:\Users\User-D2\ionic\MyApp\www\index.html’

Is there anything else i need to do?


You are aware that you can’t run php on device, correct? This is a common misunderstanding, that Cordova uses ALL web technologies. It does not, just plain HTML, CSS, and JavaScript. You can have your ionic app make REST calls to a web service using PHP on a traditional server.

Hope this clears up the confusion you might have and why you were getting an error.