Without the .html url tag

i.e. myspace.com/name instead of myspace.com/name.html

Page 1 of 1

13 Replies - 1503 Views - Last Post: 07 March 2008 - 10:45 PM

#1 mlg5454  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 25
  • Joined: 15-October 07

Without the .html url tag

Posted 06 March 2008 - 11:56 AM

get it? how do you get an html document to not be www.page.com/page.html, and instead, www.mpage.com/page ??
Is This A Good Question/Topic? 0
  • +

Replies To: Without the .html url tag

#2 BenignDesign  Icon User is offline

  • holy shitin shishkebobs
  • member icon




Reputation: 6092
  • View blog
  • Posts: 10,527
  • Joined: 28-September 07

Re: Without the .html url tag

Posted 06 March 2008 - 12:04 PM

subdomain?

As in the difference between http://www.website.com/blah.html and http://www.website.com/blah .... would be a subdomain that automatically loads an index.html or default.html from the "blah" folder. It should also work as http://blah.website.com (if this were a real site, which it is not).

This post has been edited by BenignDesign: 06 March 2008 - 12:06 PM

Was This Post Helpful? 0
  • +
  • -

#3 Nykc  Icon User is offline

  • Gentleman of Leisure
  • member icon

Reputation: 729
  • View blog
  • Posts: 8,642
  • Joined: 14-September 07

Re: Without the .html url tag

Posted 06 March 2008 - 12:08 PM

I think I misunderstood the question. My bad!

But if you are trying to doing something like in Myspace those are calling variables through a fuseaction using ColdFusion.

This post has been edited by Nykc: 06 March 2008 - 12:12 PM

Was This Post Helpful? 0
  • +
  • -

#4 BenignDesign  Icon User is offline

  • holy shitin shishkebobs
  • member icon




Reputation: 6092
  • View blog
  • Posts: 10,527
  • Joined: 28-September 07

Re: Without the .html url tag

Posted 06 March 2008 - 12:10 PM

View PostNykc, on 6 Mar, 2008 - 12:08 PM, said:

no that would be subdomain.domain.com

sub directory!


Indeed, you are correct. My noobness has been revealed! ahhhh!
Was This Post Helpful? 0
  • +
  • -

#5 Nykc  Icon User is offline

  • Gentleman of Leisure
  • member icon

Reputation: 729
  • View blog
  • Posts: 8,642
  • Joined: 14-September 07

Re: Without the .html url tag

Posted 06 March 2008 - 12:14 PM

Please explain a little better what you are trying to do, or why for that matter so someone can better answer this question. It is a little vague
Was This Post Helpful? 0
  • +
  • -

#6 mlg5454  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 25
  • Joined: 15-October 07

Re: Without the .html url tag

Posted 06 March 2008 - 01:18 PM

i have a website called minusthemasses.com.

artist pages right now are as follows:

http://www.minusthem...fledfromme.html

i would like them to be:

http://www.minusthem...birdsfledfromme

how do i do this?
Was This Post Helpful? 0
  • +
  • -

#7 Nykc  Icon User is offline

  • Gentleman of Leisure
  • member icon

Reputation: 729
  • View blog
  • Posts: 8,642
  • Joined: 14-September 07

Re: Without the .html url tag

Posted 06 March 2008 - 01:29 PM

Ok someone might be able to elaborate on this a little better. but the best way to do this is to have a subdirectory created in the artists section such as
http://www.minusthem...birdsfledfromme

when someone visits the URL it will bring up that mini webspace. This is the simplest way to do this. You will need some logic that creates the directory when the user signs up.

There could be other methods but I think this one is the simplest, plus its the only way I know how to do stuff like that. Maybe someone else has some different input. Either way the described method should be fairly sufficient for what you appear to be trying to attempt.

Hope this helps!
Was This Post Helpful? 0
  • +
  • -

#8 thehat  Icon User is offline

  • awake ? web();
  • member icon

Reputation: 106
  • View blog
  • Posts: 951
  • Joined: 28-February 08

Re: Without the .html url tag

Posted 06 March 2008 - 01:44 PM

Mykc's solution sounds spot on. Just be sure that in that folder, your html/php/whatever file is named as a folder default (usually index) and that you only use the folder name, not the filename, in your links.
Was This Post Helpful? 0
  • +
  • -

#9 mlg5454  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 25
  • Joined: 15-October 07

Re: Without the .html url tag

Posted 06 March 2008 - 02:24 PM

I don't think I follow what exactly I'm supposed to do with the subdomain thing...
Was This Post Helpful? 0
  • +
  • -

#10 Nykc  Icon User is offline

  • Gentleman of Leisure
  • member icon

Reputation: 729
  • View blog
  • Posts: 8,642
  • Joined: 14-September 07

Re: Without the .html url tag

Posted 06 March 2008 - 02:29 PM

Basically a sub directory is another folder. When the user signs up you assign them a folder titled (username) this becomes the answer to your problem. It becomes part of the URL. When typing a normal URL you don't have to type index.html afterwards. The server will default to the index.html file. This is exactly what you are trying to do. to test this theory create a new folder called test. upload it to server and go to the interwebz and type www.yoursite.com/artist/test. make sure you have an index.html page (just make a hello world page or something)
When you go to the new url that Hello World page will pop-up.

This is the same concept Myspace and other sites use.
Was This Post Helpful? 0
  • +
  • -

#11 no2pencil  Icon User is offline

  • Toubabo Koomi
  • member icon

Reputation: 5310
  • View blog
  • Posts: 27,210
  • Joined: 10-May 07

Re: Without the .html url tag

Posted 06 March 2008 - 02:29 PM

Are you running this on your own host? You need to make sure that your "whatever.html" page is concidered an index page & will auto load (or be looked for by the webserver).

(httpd.conf)
<Directory /var/www/html/customers>
   DirectoryIndex main.php
</Directory>



This will make Apache look for a file named main.php instead of index.html, and serve that as the "index" page for our store directory. That's the approach we take in the rest of our examples; you'll note that all the pages are called something.php rather than something.html.

Granted, this is if you are running apache on your webserver.
Was This Post Helpful? 0
  • +
  • -

#12 girasquid  Icon User is offline

  • Barbarbar
  • member icon

Reputation: 108
  • View blog
  • Posts: 1,825
  • Joined: 03-October 06

Re: Without the .html url tag

Posted 06 March 2008 - 02:54 PM

As an alternative, you might want to take a look at something called mod_rewrite under Apache. If you write a simple rule like this:
RewriteRule /(.+) /$1.html [nc,l]



It should redirect any requests to /foo to /foo.html.

Try googling for some tutorials to get you started, you can do some pretty cool things.
Was This Post Helpful? 0
  • +
  • -

#13 mlg5454  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 25
  • Joined: 15-October 07

Re: Without the .html url tag

Posted 07 March 2008 - 10:13 PM

cool. i'm kinda swamped with other stuff but when i get the chance i'll try the subdomain thing and if that doesn't work correctly i'll come back and bug y'all some more.
Was This Post Helpful? 0
  • +
  • -

#14 Nykc  Icon User is offline

  • Gentleman of Leisure
  • member icon

Reputation: 729
  • View blog
  • Posts: 8,642
  • Joined: 14-September 07

Re: Without the .html url tag

Posted 07 March 2008 - 10:45 PM

Good luck. try to keep us posted either way. Solutions make this forum a more valuable resource.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1