Otaku, Figure, Anime, Games, Jpop, Tech, Nihongo, Cosplay, DSLR, Photography, Camera
  CATEGORIES: HOME | FIGURE | ANIME | GAME | JPOP | JAPAN | TECH | SITE | ARCHIVE                  RSS Feeds
Click now for J-List!



| Follow me on Twitter!

| Most Recent Post:
Volks Dollfie Dream Saber Alter 2nd Ordered!
Volks Dollfie Dream Saber Alter 2nd Ordered!
Dollfie Dream (DD) maker Volks has made it easy for interested buyers to obtain their...
Hatsune Miku Tony Version
Hatsune Miku Tony Version
Okay, up for photoshoot today is the 1/7 scaled Hatsune Miku Tony Version by Max...
Nendoroid Kirino
Nendoroid Kirino
A quick figure post before procrastination kicks in, here's Nendoroid Kirino Kousaka from "Ore no...
Kore Wa Zombie Desu Ka OP "Makasete Tonight"
Kore Wa Zombie Desu Ka OP
Korezom opening theme "MA KA SE TE Tonight", sung by Nomizu Iori, the seiyuu of...
Hatsune Miku Lat-Type
Hatsune Miku Lat-Type
***Chikoku chikoku chikoku!*** (***late, late, late***)! It has been weeks since her announcement on GSC...
Site Is Now XGA Screen Compatible
Site Is Now XGA Screen Compatible
Ok, I shrank the site from 1280 pixels to 1024 pixels in width, obviously not...

| Most Recent Comments:
Divine Fang @ Hatsune Miku Tony Version
@ Fabrice, Absolutely ^_^! The best Miku figure, that is until I get...
Fabrice @ Hatsune Miku Tony Version
Her hair is so shiny *w* great figure worth having, unfortunetely i had...
otakunewby @ Nendoroid Kirino
Hi are you interested to do a link exchange Url: http://otakunewby.blogspot.com/ Send...
Erik @ Bayonetta Costumes
Well I guess you found her design a failure because she doesn't look like...
Divine Fang @ BRS Blu-ray Limited Edition Box
@ jus a loser, I thought it has got an awesome packaging too....

| Blogroll:
Real Life Buddies:
 • Anechoic 
 • I, UltraBeast
 • Jimmy Kecik
 • Keef
 • NCY 
 • Preston Toh  
 • Ze Hao

Online Buddies:
 • Alafista
 • Anime MMORPGS
 • Anime Raku
 • Atalude
 • Danny Choo
 • DarkMirage
 • Fabrice Requin
 • Figured's Figurelog
 • Gordonator
 • How a Girl Figures
 • Janime.tv
 • Jusuchin
 • Kirainet
 • Koi Aichaku
 • Kurogane
 • Kusakabemisao
 • Kyouran Kyodai
 • Life In Quadrant 4
 • Manga Figures
 • Orange Horizons
 • Otadesho
 • Otaku Dan
 • Otaku.fm
 • Otaku's Hideout
 • Riuva
 • Sky Lounge
 • Saku's AFK
 • Shadonia
 • The Deathseeker
 • WAWAWA Wasuremono
 • Wcloudx (kumo)
 • Yumeno no Sekai
 • Zone Otaku
 • 望み - What is that you desire?


avatar Rewrite Search Engine Friendly URL
Posted: August 22nd, 2008 2:21 pm (Fri) by Divine Fang
Last Edited: August 22nd, 2008 2:45 pm (Fri) Views: 3952 [Permalink]
Tag: Site, Linux, Apache, Programming, SEF, URL
Rewriting Search Engine Friendly URL (SEF URL) had been a mystery but a simple search string of "Rewrite URL" returns a tool that got the mystery solved almost immediately! As programming is nothing more than just a hobby of mine, I didn't venture into the technical details of rewriting a SEF URL. The solution I found was located at Webconfs. Input a dynamic URL there and the "Tool" will produce a static URL and codes required to be written/added on a htaccess file. The code was then customised to suit my needs since it's pretty much self-explanatory.

Kotomi-chan
Above: Kotomi Ichinose of Clannad


For this site, a single .htm URL pattern is used to cloak the dynamic URL. If you are a frequent reader you should have probably noticed non-SEF URL used previously, such as

http://www.shin-otaku.com/index.php?permalink=20080815091246&title=moetan_pastel_ink_nendoroid_unboxing
http://www.shin-otaku.com/index.php?category=archive



With simple codes applied to htaccess file as below,

Options +FollowSymLinks
RewriteEngine on
RewriteRule (.*)-(.*).htm$ index.php?permalink=$1&title=$2

Options +FollowSymLinks
RewriteEngine on
RewriteRule (.*).htm$ index.php?category=$1

non-SEF URLs become

http://www.shin-otaku.com/20080815091246-moetan-pastel-ink-nendoroid-unboxing.htm
http://www.shin-otaku.com/archive.htm


Extras
SEF may not be a concern for Blogspot or Wordpress users since both are readily SEF but for those otakus who are interested, proceed reading about:

Mod_rewrite & URL rewriting guide
SEF advantages

Read or post comment (10 Otaku comments)
nanu
(USA)
Posted August 22nd, 2008 3:39 pm (Fri)  
nothing more than a hobby eh? i'd say you're doing pretty well learning this on your own and applying it ;)

nanu
(USA)
Posted August 22nd, 2008 7:59 pm (Fri)  
OT: I just realized who's in your header after revisiting recent and not-so-recent figure pictures and barely noticing heterochromia in them ;o;

Divine Fang
(Kuala Lumpur, KL)
Posted August 23rd, 2008 9:22 am (Sat)  
@ nanu,
Yup, feels good to have this blog programmed manually. Arigatou gozaimasu!
OT: The current header is "possibly the cutest vampire ever" Chua Churam as stated here :)

gordon
(Singapore 新加坡)
Posted August 23rd, 2008 11:22 am (Sat)  
yes using SEF URL is very important.

putting words in your title that people will commonly do a search on google will bring about traffic. i find that in some cases, people who blogs about figures get lots of hits but few comments cos people come in via google search.

and putting sexual terms works likewise too but hey we aren't going to go that way right? ^^;

The UltraBeast
(Proud Son of Cheras)
Posted August 24th, 2008 7:51 am (Sun)  
GOOD ~!! It seems that you solved this riddle. :D

So it looks like the pattern is that it will chuck away everything in the second string i.e.
index.php?permalink=$1&title=$2

and tack on a .htm to whatever is remaining.

Divine Fang
(Kuala Lumpur, KL)
Posted August 24th, 2008 9:37 am (Sun)  
@ Gordon,
True, it seems like most visitors are referred by google especially image.google.com and they suck up serious bandwidth.
I bet you have gotten quite a good amount of traffic here and here ohoho...

@ The Ultrabeast,
You're right. But I've discovered that the rules I that modified above are bad. They "overlap" a real static URL ending with .htm!!! Problems will arise when I have a real static URL later... :O

Saku
(Toronto, Canada)
Posted August 26th, 2008 8:39 pm (Tue)  
Very good info. I am using wordpress already so SEF URL is not an issue but this would come in handy in the future.

Divine Fang
(Kuala Lumpur, MY)
Posted August 27th, 2008 12:49 pm (Wed)  
@ Saku,
Welcome! I have to say that Wordpress is by far a much more blogger-friendly, search-engine-friendly, and most importantly visitor-friendly blog CMS (Content Management System) and I may switch to it one day LOL!!!

The UltraBeast
(Proud Son of Cheras)
Posted September 17th, 2008 3:26 am (Wed)  
@Divine:

Ehhhh? How come you're looking to possibly switch to WP in future? I thought you've already got a good thing going on here?

About the static URL overlap, it's not a big problem at all, really.. I think all CMS SEF also 'masks' out actual .htm files which happen to have the exact same name. Which doesn't happen very often at all.

Divine Fang
(Kuala Lumpur, MY)
Posted September 17th, 2008 12:37 pm (Wed)  
@ The UltraBeast,
Everything is going very smoothly now but there are a few things that I didn't take into consideration when I was designing the SQL DB structure. I would like to have a "Read more..." feature on my entries and "change theme" options. Modifying the SQL DB and PHP codes in index page right now seems too late otherwise difficult. I could have done better but I guess this is what you call it's hard to get things right the first time.


Your Thoughts
<b>bold</b>, <i>italic</i>, <a href="http://...">Click</a> tags supported.
  Nickname
 
  Location e.g. Tokyo, Japan
 
  Gravatar email (optional)
 
  Website (optional)
 

Pick an avatar if you do not have a Gravatar email
:

Enter Code: CAPTCHA Image Reload Code



 

Copyright © 2008 - 2012 Shin-Otaku.com All rights reserved unless otherwise noted. | Contact