I wanted to implement a feature on my application, that when a user creates his own page on my site, i add his username to the url - identifying his own personal page.
The best example would be www.facebook.com/username/
We can select our own name and whenever we have the url with that name we directly land up on our page. May be there is a way to update it via xml? from the db?
I tried to google it but couldnt find a suggestion on how to approach and implement it on my site (JSP's)
Bear Bibeault wrote:It would be easy to map a servlet that accepts any random string, that you interpret as the username, as a path parameter.
Then it's just a matter of looking up the user-specific info in the DB and forwarding to a dynamic JSP that displays the user-specific data.
Thanks a lot, i'll try it and let you know the results. But, i think your solution makes sense to me.
Ulf Dittmer wrote:You might want to read up on what a CMS is and does.
Well, i am already working on it, i am planning to utlize spring (3.x) mvc framework, use hibernate. tomcat, include cms (yes i did read about it, and the read is on) from some other free source... (after a lot of study and my comfort-ability i have worked this out) you got any suggestion, to design a scale-able, maintainable website for personal use only ? - i could have gone for php but i have a java background and i know the power java has...
Also, on the topic, i asked a couple of friends and URL shortening was another option recommended.
Ulf Dittmer wrote:
URL shortening was another option recommended.
What do you mean by that? What's commonly understood by that phrase is a service like goo.gl or bitly.com; surely that's not what you intend to implement?
You are right, i also read the same. But, my friend was saying that what i am looking for can also be achieved by url shortening.
So, far i have not come across any example on url shortening that meets my requirements.