Web Design Forum: A landing page without having the index.html ext. showing - Web Design Forum

Jump to content

WDF
WDF Premium Memberships Reseller Hosting
Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

A landing page without having the index.html ext. showing

#1 User is offline   Jejune 

  • Forum Newcomer
  • Pip
  • Group: Members
  • Posts: 32
  • Joined: 29-January 12
  • Reputation: 2
  • Gender:Male
  • Experience:Beginner
  • Area of Expertise:I'm Learning

Posted 29 January 2012 - 09:42 PM

Hi,

Just a quick question, when I upload, the server will automatically redirect any visitor to the index.html file.
But I've seen on bigger sites that the first page is just the domain name without the index.html extension showing up.

How do I do that?

Thanks.
0

#2 User is online   sash_oo7 

  • Forum Newcomer
  • PipPipPipPip
  • Group: Members
  • Posts: 838
  • Joined: 15-August 10
  • Reputation: 45
  • Gender:Male
  • Location:Mars
  • Experience:Nothing
  • Area of Expertise:Nothing

Posted 29 January 2012 - 10:01 PM

what is the name of the file u given to the page u uploaded?
rename it to index.html
0

#3 User is offline   Jejune 

  • Forum Newcomer
  • Pip
  • Group: Members
  • Posts: 32
  • Joined: 29-January 12
  • Reputation: 2
  • Gender:Male
  • Experience:Beginner
  • Area of Expertise:I'm Learning

Posted 29 January 2012 - 10:35 PM

I have re-named it it index.html

So the landing page is: www.example.co.uk/index.html

What I want is the landing page to be: www.example.co.uk
0

#4 User is online   BlueDreamer 

  • Web Guru
  • Group: Moderators
  • Posts: 5,804
  • Joined: 23-October 07
  • Reputation: 202
  • Gender:Male
  • Location:Northampton (where?)
  • Experience:Advanced
  • Area of Expertise:Web Developer

Posted 29 January 2012 - 10:47 PM

Just link to www.example.co.uk - not www.example.co.u/index.html
0

#5 User is offline   Jejune 

  • Forum Newcomer
  • Pip
  • Group: Members
  • Posts: 32
  • Joined: 29-January 12
  • Reputation: 2
  • Gender:Male
  • Experience:Beginner
  • Area of Expertise:I'm Learning

Posted 29 January 2012 - 10:56 PM

Did that too. It just automatically sends you to www.example.co.uk/index.html

My home site is:

jejune-jejune.co.uk

enter that add in, it will just go straight to jejune-jejune.co.uk/index.html
0

#6 User is online   sash_oo7 

  • Forum Newcomer
  • PipPipPipPip
  • Group: Members
  • Posts: 838
  • Joined: 15-August 10
  • Reputation: 45
  • Gender:Male
  • Location:Mars
  • Experience:Nothing
  • Area of Expertise:Nothing

Posted 30 January 2012 - 12:26 AM

where are u uploading ur files under which folder?
0

#7 User is offline   Jejune 

  • Forum Newcomer
  • Pip
  • Group: Members
  • Posts: 32
  • Joined: 29-January 12
  • Reputation: 2
  • Gender:Male
  • Experience:Beginner
  • Area of Expertise:I'm Learning

Posted 30 January 2012 - 08:45 PM

I'm on vidahost. And I upload it to the web root public_html.
0

#8 User is offline   AdvantageDigitalMedia 

  • Forum Newcomer
  • Group: Gold Membership
  • Posts: 21
  • Joined: 31-January 12
  • Reputation: 1

Posted 31 January 2012 - 09:06 AM

Hi there,

The reason for this is simply you have a 301 redirect instigated on your domain. I did a quick check and it returns this:

Checked link: http://www.jejune-jejune.co.uk

Type of redirect: 301 Moved Permanently
Redirected to: http://www.jejune-je....uk/index.html/

301 Redirects are headers sent to the browser for instructional purposes. Basically if anyone accesses the root domain, http://www.jejune-jejune.co.uk, they are being redirected to the index.html/ page automatically.

Depending on your hosting environment this is probably applied in your .htaccess file. If you cannot see this try looking for a setting in your FTP client for "Show hidden files" or similar, as some clients hide it for security or to prevent accidental editing.

If you're still stuck, contact your host. This is not usually something that can be setup by accident as it's been specified somewhere, but as I say, it depends on your hosting environment.

Hope this helps.
1

#9 User is offline   Jejune 

  • Forum Newcomer
  • Pip
  • Group: Members
  • Posts: 32
  • Joined: 29-January 12
  • Reputation: 2
  • Gender:Male
  • Experience:Beginner
  • Area of Expertise:I'm Learning

Posted 31 January 2012 - 04:16 PM

Thank you!

I will try it out and post how it goes.
0

#10 User is offline   AdvantageDigitalMedia 

  • Forum Newcomer
  • Group: Gold Membership
  • Posts: 21
  • Joined: 31-January 12
  • Reputation: 1

Posted 31 January 2012 - 04:21 PM

Hi,

No worries at all. As I say it depends how this 301 has been put in place, whether it's in a .htaccess or via an option in your control panel so have a look around.

If you get stuck just reply here and I'll help if I can.

Cheers.
0

#11 User is online   sash_oo7 

  • Forum Newcomer
  • PipPipPipPip
  • Group: Members
  • Posts: 838
  • Joined: 15-August 10
  • Reputation: 45
  • Gender:Male
  • Location:Mars
  • Experience:Nothing
  • Area of Expertise:Nothing

Posted 01 February 2012 - 05:23 AM

how to make 301 redirect using .htaccess put it inside public_html folder

RewriteCond %{REQUEST_URI} /index\.html?$ [NC]
RewriteRule ^(.*)index\.html?$ "/$1" [NC,R=301,NE,L]


u can try this code too in ur .htaccess file

how to find .htsccess file on ur server

This post has been edited by sash_oo7: 01 February 2012 - 05:53 AM

0

#12 User is offline   AdvantageDigitalMedia 

  • Forum Newcomer
  • Group: Gold Membership
  • Posts: 21
  • Joined: 31-January 12
  • Reputation: 1

Posted 01 February 2012 - 06:52 AM

View Postsash_oo7, on 01 February 2012 - 05:23 AM, said:

how to make 301 redirect using .htaccess put it inside public_html folder

RewriteCond %{REQUEST_URI} /index\.html?$ [NC]
RewriteRule ^(.*)index\.html?$ "/$1" [NC,R=301,NE,L]


u can try this code too in ur .htaccess file

how to find .htsccess file on ur server


He already has a 301 redirect in place which is causing his issue. If, as assumed, his issue is that he just wants the root URL to display upon page load, i.e. http://www.yourdomain.com instead of http://www.yourdomain.com/index.html he won't need any redirects in his .htaccess as this is normal behaviour.

You're also assuming his hosting/server has mod_rewrite enabled, which some don't, in which case your above code won't work. It's also good practise to initialise the RewriteEngine before writing rules, again assuming mod_rewrite is enabled.

Hope this helps, let us know how you get on!
0

#13 User is offline   Jejune 

  • Forum Newcomer
  • Pip
  • Group: Members
  • Posts: 32
  • Joined: 29-January 12
  • Reputation: 2
  • Gender:Male
  • Experience:Beginner
  • Area of Expertise:I'm Learning

Posted 08 February 2012 - 06:14 PM

Sorry for the delay. Been abit busy. Figured it out though. It was actually my own fault.

What I did wrong was zip the folder containing the web files then upload it to the public folder. The mistake I made was to rename the folder containing the web files to index.html, instead of just moving them outside of the zip folder.

Thanks for the help, it's much appreciated.
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users