Running app in a browser


I was wondering I set up localhost with xampp and when I try to load my ionic /cordova project it doesn’t load it, then I tried python server and it shows an error code 404, message File not found
"GET /somecompany/www/index.html HTTP/1.1" 404 - when I run cordova serve it won’t work as well, I have cordova plugns in my app, I’d appreciate any help


have you tried the following?
ionic serve


Yes I have tried it as well, my app is written in angular.It has cordova plugins as well so I thought maybe this is why it won’t work in localhost


If you’re running the latest version of the Ionic CLI you can switch on logging when the server is running:

$ ionic serve -b
Running dev server: http://localhost:8100
Running live reload server: http://localhost:35729
Watching : [ 'www/**/*', '!www/lib/**/*' ]
Ionic server commands, enter:
  restart or r to restart the client app from the root
  goto or g and a url to have the app navigate to the given url
  consolelogs or c to enable/disable console log output
  serverlogs or s to enable/disable server log output
  quit or q to shutdown the server and exit

Maybe the logs will show the problem. Oh and also make sure you are running it form the top-level folder, i.e. above www.


Oh yeah also forgot to mention, you dont need XAMP to run Ionic’s local server, in fact it might cause problems because it might be using the same port that Ionic is trying to bind to (which will cause Ionic to fail).


I tried to run it with xampp and without with no success, but thank you for a reply


from what folder are you running ionic serve?

GET /worldPayClub/www/index.html HTTP/1.1 looks like you dont run it from inside your ionics project folder (which should leave out the worldPayClub from the path), so cd worldPayClub and then ionic serve and it should work i guess