is there code that you can use for a back button that takes you back to the last page you looked at no matter where it is.

basically so it does the same job as the browser back button?

    Yes, but it's Javascript - don't ask me what. Someone here will help you in a minute.

    Norman

      that makes no sense to me.
      I am newb remember.

        Newb to php. You never said you were a newb to javascript. 😉

          does anyone care to share the javascript code with me?

          im sure it must only be a line or two?

            I thought I typed it... @.@ Lol oh well.

            <SCRIPT LANGUAGE="javascript">
            history.back
            </SCRIPT>

            Should work.

              Maybe im not doing something right,

              but i put the code in (thats all i did) and nothing happens.

              do i need to enable javascript on apache?
              or am i doing something else wrong?

              thanks.

                You didn't put it inside the php tag did you? You probably didn't, but I can't think of anything else that would stop it working... 🙁

                  no, your right. Its not within the php tags.

                  but the code 'history.back'

                  does this produce a text link called 'back' with the function of history (which obviously takes you back to the last page).

                  Just seems like very little amount of code.
                  if it does produce the text 'back' can you format this text (colour, size, etc)

                  when i open in DW, i get a Source option which is currently blank.
                  do i need to edit this?

                  i get no errors
                  no nothing.

                    Ah. That's why it isn't working. 😛
                    Your probably going straight to your page to test it - it doesn't make a link, it automatically goes back. So if you go straight to the page, it can't go back. 🙂

                    You can use javascript:
                    <input type="button" value="Back" onClick="history.back()">
                    I think (I'm not too good with js.)

                      Write a Reply...