www.webdeveloper.com
Results 1 to 4 of 4

Thread: timer to previous page

  1. #1
    zatomas's Avatar
    zatomas is offline (¯`·._.·[ÕÕ]·._.·´¯)
    Join Date
    Jul 2005
    Posts
    19

    timer to previous page

    Timer to previous page
    hi all..
    I am developing a small web application for a school to print student’s ID card and maintain database I the same time everything is working fine…
    But the printing process take so many clicks I want to cut them down with java script auto close page and back to previous page functions .
    So far this code didn’t work for me how can I get it tiwork

    Code:
    <script type="text/JavaScript">
    setTimeout("location.href = 'window.history.previous()';",3000);
    </script>
    It keep telling me the url is wrong I think I coded it wrong any help..
    cheers

  2. #2
    Join Date
    Jul 2008
    Location
    urbana, il
    Posts
    2,787

  3. #3
    zatomas's Avatar
    zatomas is offline (¯`·._.·[ÕÕ]·._.·´¯)
    Join Date
    Jul 2005
    Posts
    19
    i `ve tryed this code
    Code:
    <script type="text/JavaScript">
    setTimeout("location.href = 'window.history.previous()';",3000);
    </script>
    i got the error
    The requested URL /securecardprintarea/history.back() was not found on this server.

  4. #4
    Join Date
    Apr 2013
    Posts
    56
    How to use setTimeout

    From here you use rnd me answer: history.back().

    setTimeout(function(){history.back()},3000);

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles