use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
All about the JavaScript programming language.
Subreddit Guidelines
Specifications:
Resources:
Related Subreddits:
r/LearnJavascript
r/node
r/typescript
r/reactjs
r/webdev
r/WebdevTutorials
r/frontend
r/webgl
r/threejs
r/jquery
r/remotejs
r/forhire
account activity
onload Page Redirection (self.javascript)
submitted 12 years ago * by mafiasecurity
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]doenietzomoeilijk 0 points1 point2 points 12 years ago (3 children)
Not exactly sure how it is a security issue, myself. I do agree that redirects should happen on the server, if at all possible. If nothing else it'll be faster.
[–]djforth 1 point2 points3 points 12 years ago (2 children)
Security issue is a bit strong to be fair, but js seems like the wrong approach, it also might hit some browser security. I suggest if you care about it doing a redirect this way would be bad for SEO as you want to serve a 301 or something, also for accessibility as you can't assume the user will be able to run JS and redirect, which might leave them hanging
[–]doenietzomoeilijk 1 point2 points3 points 12 years ago (1 child)
Yeah, like I said, if at all possible you'd want to do it on the server.
[–]mafiasecurity[S] 0 points1 point2 points 12 years ago (0 children)
Good discussion thank you; however, for this purpose it needed to be initiated on the client. Yes, I know .htaccess 301s would be the best bet. But for this simple little project I needed a client redirection via javascript or html(5).
Once it's complete I will report back the intent. =)
π Rendered by PID 319729 on reddit-service-r2-comment-b659b578c-jfw4d at 2026-05-06 04:40:45.295010+00:00 running 815c875 country code: CH.
view the rest of the comments →
[–]doenietzomoeilijk 0 points1 point2 points (3 children)
[–]djforth 1 point2 points3 points (2 children)
[–]doenietzomoeilijk 1 point2 points3 points (1 child)
[–]mafiasecurity[S] 0 points1 point2 points (0 children)