# Using back button in flash "like a browser back button"

**URL:** <https://forum.kirupa.com/t/using-back-button-in-flash-like-a-browser-back-button/205491>\
**Category:** Uncategorized\
**Created:** [October 30, 2006, 7:07am UTC](https://forum.kirupa.com/t/using-back-button-in-flash-like-a-browser-back-button/205491 "2006-10-30T07:07:15Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Flash\_Man1](https://avatars.discourse-cdn.com/v4/letter/f/8797f3/32.png) [@Flash\_Man1](https://forum.kirupa.com/u/Flash_Man1)\
**Post date:** [October 30, 2006, 7:07am UTC](https://forum.kirupa.com/t/using-back-button-in-flash-like-a-browser-back-button/205491/1 "2006-10-30T07:07:15Z")

</div>

hey all/reef,

basically this code will work like a browser back button its very simple but “could end up very long” basically it will act “similiar to the browser back button”

```auto
on (release) {
    if(page1 = _currentframe){
        _root.gotoAndStop("quiz");
    } else if (page0 = _currentframe){
        _root.gotoAndStop("register");
    } else if (page2 = _currentframe){
        _root.gotoAndStop("q2");
    } else if (page3 = _currentframe){
        _root.gotoAndStop("q3");
    } else if (page4 = _currentframe){
        _root.gotoAndStop("speciality");
    }
}

```

it works when the (page1 = \_currentframe){ is rotated with the first if statement…because for somereason it seems to not recognise the “else if’s” anybody or reef have any ideas why??
