To contact staff directly or to report bugs, please use Special:Contact.
Is there anyway I can redirect my main page to another page?
This is what I want. I want my users to land on my intro page. Then when they click on the "Enter Site" button it takes them to my main page. I was wondering if there is someway to accomplish this using:
if (window.location.pathname.indexOf('http://keros.wikia.com/wiki/Keros_Wiki') == 0) {
window.location = "http://www.myredirectpage.com";
}
--Andromeda Vadum (talk) 19:42, October 2, 2012 (UTC)
- You would be better off with
if(wgMainpage == wgPageName) {window.location = 'http://somesite.com';}
, but I would advise against doing this. When people go to your wiki, they expect to see your wiki - not some other site. Monchoman45 Talk Contribs Skystone 19:50,10/2/2012
- Rather than redirecting the main page automatically, you could have a button that takes the user to the other site when they click it -- but if they don't click the button, then they won't be taken to the other site. A very simple example would be:
[https://www.google.com <span class="button">Google</span>]
- which makes . If you want more fine control, you can make the button/javascript in a MediaWiki page and then place the raw HTML + script for the button onto the main page of your wiki by using verbatim tags. Mathmagician ƒ(♫) 20:11 UTC, Tuesday, 2 October 2012
It's not working Monchoman45, anything else? I put the code in MediaWiki:Wikia.js Does that help? It is not working...--Andromeda Vadum (talk) 23:46, October 2, 2012 (UTC)
Uncyclopedia has an on-page disclaimer that needs recognition before showing the page content. You might check that out.--PedroM (talk) 10:13, October 3, 2012 (UTC)
I want something like this: http://www.americandiamondworks.com/ --Andromeda Vadum (talk) 17:37, October 3, 2012 (UTC)