Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

.html extensions to directories.

Featured Replies

Hi everyone, I completed and hosted my first site a couple of weeks back.

 

The URL is

Now I'm not completely certain what I am actually talking about here and I have been trying to search for a while. So bear with me.

 

If you click on my homepage you can see I have managed to make it a non .html file. So on all my pages this links to that directory when you click 'home'. Which I believe optimises it's search potential as it won't appear on google even if I search very direct terms. I know it takes a while, but it's seemingly taking too long.

 

Now on other sites I notice they manage to this will all of their pages e.g, www.pwjc.co.uk/news

 

Where as mine is clearly, www.pwjc.co.uk/news.html - with the .html extension.

 

When I try the first directory my pages fail.

 

It appears to me, so far, that the pages are indeed meant to be '/news' and not the way I currently have it. Other than my home/index page.

 

Is that correct? I don't think I'm making much sense as I don't really know what this aspect of the SEO process is called. I think you will understand with my examples though.

 

If you have managed to understand, firstly, well done. Secondly, how do I make all my pages like that without corrupting them?

 

 

Thanks for your time.

Hi Gary

 

To remove the .html you will have to rewrite the url using a file called .htaccess As far as I know this will only work If your site is hosted on a Linux server and not a windows server (someone correct me if i am wrong).

 

To create this file just use notepad and save the file as .htaccess

 

In this file put the following code

 

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{HTTP_HOST} ^pwjc.co.uk [NC]
RewriteRule ^(.*)$ http://www.pwjc.co.uk/$1 [L,R=301]
</IfModule>

RewriteEngine on
RewriteOptions inherit
RewriteBase //
RewriteRule ^news$ news.html [L]
RewriteRule ^dates$ dates.html [L]

 

The above code should alter the two pages news and dates, just add the rest you want to change.

 

you can then save the file to your root directory online

 

I havent checked this code but it should work.

 

How long ago did the site go live as it varies anything between days and 3weeks.

 

Pat

  • Author

Hi Pat, thanks for that.

 

It's been probably over 2 weeks. Should it still show up on google then how it is already?

 

Having the homepage as a non .html extension, should be enough though right? Or am I supposed to do what you suggested.

Hi Pat, thanks for that.

 

It's been probably over 2 weeks. Should it still show up on google then how it is already?

 

Having the homepage as a non .html extension, should be enough though right? Or am I supposed to do what you suggested.

 

To be honest having news.html shouldnt be an issue seo wise, I only use the above code if I am generating pages through php eg i could have a generated page like showitem.php?item_id=260 which I would change to football.html.

 

As for google I would wait another week, also I would set up an account with google webmaster tools and register a sitemap, that may help.

 

Pat

  • Author

Hey Pat. In that case I may leave it as it is. I thought it was probably ok like it is now.

 

I already have a webmasters account and have also tried a sitemap. My sitemap doesn't seem to work, everytime I enter a new page into it the status has a red cross below it. Is that normal? Does the site need to be indexed in google for these sitemaps to work?

 

I wasn't sure if it wasn't working because of my issue we discussed previous.

Not sure how you generated your sitemap, but I have generated one for you

<?xml version="1.0" encoding="UTF-8"?>
<urlset
	xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9
	http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd">
<!-- created with Free Online Sitemap Generator www.xml-sitemaps.com -->

<url>
<loc>http://www.pwjc.co.uk/</loc>
<lastmod>2010-04-25T02:52:58+00:00</lastmod>
</url>
<url>
<loc>http://www.pwjc.co.uk/news.html</loc>
<lastmod>2010-04-25T02:27:21+00:00</lastmod>
</url>
<url>
<loc>http://www.pwjc.co.uk/dates.html</loc>
<lastmod>2010-04-25T02:27:21+00:00</lastmod>
</url>
<url>
<loc>http://www.pwjc.co.uk/pictures.html</loc>
<lastmod>2010-04-25T02:27:21+00:00</lastmod>
</url>
<url>
<loc>http://www.pwjc.co.uk/merchandise.html</loc>
<lastmod>2010-04-25T02:27:21+00:00</lastmod>
</url>
<url>
<loc>http://www.pwjc.co.uk/contact.html</loc>
<lastmod>2010-04-25T02:27:21+00:00</lastmod>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/links.html</loc>
<lastmod>2010-04-25T02:27:21+00:00</lastmod>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/index.php</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/faq.php</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/ucp.php?mode=register&sid=3b9f8607be29860228dfd618753887e2</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/ucp.php?mode=login&sid=3b9f8607be29860228dfd618753887e2</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/memberlist.php?mode=group&g=5&sid=3b9f8607be29860228dfd618753887e2</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/memberlist.php?mode=group&g=4&sid=3b9f8607be29860228dfd618753887e2</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/memberlist.php?mode=viewprofile&u=69&sid=3b9f8607be29860228dfd618753887e2</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/memberlist.php?mode=leaders&sid=3b9f8607be29860228dfd618753887e2</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/ucp.php?mode=delete_cookies&sid=3b9f8607be29860228dfd618753887e2</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/ucp.php?mode=register</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/ucp.php?mode=login</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/memberlist.php?mode=group&g=5</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/memberlist.php?mode=group&g=4</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/memberlist.php?mode=viewprofile&u=69</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/memberlist.php?mode=leaders</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/ucp.php?mode=delete_cookies</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/ucp.php?mode=sendpassword</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/ucp.php?mode=terms</loc>
</url>
<url>
<loc>http://www.pwjc.co.uk/forum/ucp.php?mode=privacy</loc>
</url>
</urlset>

 

save as sitemap.xml

  • Author

I did do that too yeh, that's already done. I'm just wondering if its meant to be viewable like that to all. As you can tell, I put it in my root it comes up like that. I must be missing something here.

I did do that too yeh, that's already done. I'm just wondering if its meant to be viewable like that to all. As you can tell, I put it in my root it comes up like that. I must be missing something here.

 

basically the sitemap.xml is just for googles benefit to enable google to help index your pages

  • Jo 90 locked this topic
Guest
This topic is now closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.