Back button on other pages?


#1

Hi, before 1.0.0 beta,
when navigating to different template (html), it automatically added a back button on top left
However, i’m using 1.0.0 beta 3 i believe,
back button is not shown by default. and I’m not sure how i can display it.

I can manually add back button like below:

<ion-view>    
  <ion-nav-buttons side="left">
  <button menu-toggle="left" class="button button-icon icon ion-back" ng-click="goBack()"></button>
  </ion-nav-buttons>
...

however, I don’t want to add this manually to all other child pages. How can i make it like the previous version of ionic where it displays back button automatically? what’s the recommended way?


#2

hey ozexpert,
add this to the index.html “ion-ios7-arrow-back”

//edit i mean

<ion-nav-back-button

like:

<ion-nav-bar class="bar-positive nav-title-slide-ios7">
            <ion-nav-back-button class="button-icon button-clear ion-ios7-arrow-back"></ion-nav-back-button>
</ion-nav-bar>

#3

Hey, my point is not on the icon. I just wanted to know what’s the best practice without manually adding back button on each view.


#4

you must add what i show on the first post…
if you add the code to the index it will auto add your back button, you dont have to add it to all the views


#5

Oh. okay i misunderstood. I will try that…