Skip to content

Commit

Permalink
Update render.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
sgohl authored Dec 8, 2023
1 parent aec056b commit d18c423
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions lib/render.sh
Original file line number Diff line number Diff line change
Expand Up @@ -124,3 +124,26 @@ Logo() {

}


Redirect() {

## for browser-based redirects

TARGET=${1:-}

case ${TARGET} in

back|refer)
TARGET=${HTTP_REFERER}
;;

*)
TARGET="/${TARGET}"
;;

esac

echo '<html><meta http-equiv="refresh" content="0; URL='"${TARGET}"'" /></html>'

}

0 comments on commit d18c423

Please sign in to comment.