Can't navigate away from root page


#1

I am trying to navigate from my root page, LoginPage, to a page called RegisterPage. In login.html, there is a button that calls register() in the login.js file. I have set the entry components in the app module and the register module for the register page, but nothing happens when the register button is clicked. I am hoping I’m missing something simple but have had no luck. Any help would be appreciated.

login.html: https://github.com/chrisklus/foodfinder/blob/master/src/pages/login/login.html
login.ts: https://github.com/chrisklus/foodfinder/blob/master/src/pages/login/login.ts
app.module.ts: https://github.com/chrisklus/foodfinder/blob/master/src/app/app.module.ts
register.module.ts: https://github.com/chrisklus/foodfinder/blob/master/src/pages/register/register.module.ts

My ionic version is 3.19.0. My node version is 6.11.2. Working in Cloud9 with Ubuntu 14.04.


#2

in you login.ts file you should try thy following code,:

import { RegisterPage } from ‘…/pages/register/register’;

register() {
this.navCtrl.push(RegisterPage);
}

first import the register page from destination and then push the page without ’ ’ then it will solve the problem.


#3

thanks much! works perfectly