404

  • 8 Replies
  • 3492 Views
*

Offline Jamie

  • 32
  • 0
    • View Profile
404
« on: February 05, 2010, 18:19:58 »
http://nifflas.ni2.se/index.php?page=1001Saira

404, but it's the second from the top on Google for Saira. Probably worth fixing for SEO.

*

Offline Nifflas

  • 1532
  • 61
    • View Profile
Re: 404
« Reply #1 on: February 05, 2010, 18:29:11 »
The new URL is http://nifflas.ni2.se/?page=Saira

Google should figure this out pretty soon by itself. I introduced this change to prevent links to change when I re-arrange pages on my website. In the long run, it's all about preventing URL's to change, but they had to change once so that'd be possible.

Edit: I modified it so that if a non existing page is requested, it selects the default one.
« Last Edit: February 05, 2010, 18:48:51 by Nifflas »

*

Offline Jamie

  • 32
  • 0
    • View Profile
Re: 404
« Reply #2 on: February 06, 2010, 19:53:52 »
That's better, but you should probably actually set a redirect, rather than just serving the other page, or google will get confused.

http://nifflas.ni2.se/Saira would be better than http://nifflas.ni2.se/?page=Saira if you can set a rewrite.

*

Offline Nifflas

  • 1532
  • 61
    • View Profile
Re: 404
« Reply #3 on: February 07, 2010, 17:21:57 »
It's just too messy to support the old url system too and the support is completely inconsistent with the current one, particularily since I changed the sort numbers since the last update. I'd have to add this new redirect system would actually be very easy to add, and sure, an option is just to strip out the four starting numbers if the string begins numeric, but then I'd actually mess it up for new pages instead if I want to start a menu item with e.g. the number of a year. Then everytime I copy the CMS to use with another website I'd have to remove this feature since it otherwise just adds to tbe bloat. Another drawback is that if the old URL's keep work functioning properly, other websites won't have a reason to change them, which makes me stuck with this redundant feature which clutters the system and takes up my time that I'd rather spend on something important.

I've at other places seen way too much time spent on legacy stuff that in practice doesn't matter at all, but I want to focus on the "now". You know me enough to be aware I have a "as minimal as I can do it" policy, so trying to get me to add legacy support is kind of doomed to fail ;)

I suppose it'd be useful to use mod_rewrite to change the url's though.
« Last Edit: February 07, 2010, 17:33:29 by Nifflas »

*

Offline Jamie

  • 32
  • 0
    • View Profile
Re: 404
« Reply #4 on: February 07, 2010, 17:53:38 »
Actually, I wasn't suggesting you support the old URL system - just suggesting you actually use a HTTP redirect, rather than just serving the page you want to redirect to. The search engine spider won't know you've redirected it otherwise.

*

Offline Nifflas

  • 1532
  • 61
    • View Profile
Re: 404
« Reply #5 on: February 07, 2010, 18:04:14 »
Hmmm, we'll see what happens. I'll perhaps do it, but in that case after a second url change. It'd be silly to do it now if I'm soon going to involve mod_rewrite into all this anyway as you suggested.

*

Offline Jamie

  • 32
  • 0
    • View Profile
Re: 404
« Reply #6 on: February 07, 2010, 18:24:33 »
Well, it's just

Code: [Select]
header("Location: http://nifflas.ni2.se");
exit;

to do a proper HTTP redirect. But yeah, probably best to wait until you've made the further changes.

*

Offline Nifflas

  • 1532
  • 61
    • View Profile
Re: 404
« Reply #7 on: February 07, 2010, 19:07:20 »
I know how to do HTTP redirections - I created an entire CMS and know php well, but it's the very same index.php that is still responsible of interpreting all pages, so redirection code needs to go into that (or a page included from that). Thus, I also need code to check how the get strings are formatted to see if it's one of the old or new types. It sure is easy to do, but a lot of the things are that I could add if I wanted that would probably be useful as well. It's just that all time spent on something is taken away from something else, and I prefer to use time to make nice additions to my games instead of some temporary legacy support for my website. That's how I get so many games done. What difference is it going to make anyway, almost no of my customers have found me from google, they have found me at other websites, and even if they google for Saira or Nifflas, they still come to the right place.

What really brings new visitors is new content, so that's what I need to do.

Edit: Or bleh, whatever. It's just this cheap solution. I guess I'll just bloat the website until Google gets the hang of it. I just got to remember to remove it when I install the CMS for my friends.

  if ($_GET['page']=="1001Saira") {
    header("Location: http://nifflas.ni2.se/?page=Saira");
    die;
  }
« Last Edit: February 07, 2010, 19:23:31 by Nifflas »

*

Offline Jamie

  • 32
  • 0
    • View Profile
Re: 404
« Reply #8 on: February 07, 2010, 22:30:43 »
Oh no, I just corrupted Nifflas! :/