 |
|

02-21-2007, 10:26 AM
|
|
Senior Member
5 posts this year. needs some grease! New user, who has not interacted much yet.
|
|
|
Join Date: Feb 2007
Posts: 148
Thanks: 0
Thanked 0 Times in 0 Posts
Nominated 0 Times in 0 Posts
TOTW/F/M Award(s): 0
|
|
.htaccess file
Hi there,
Does anyone have experience with the .htaccess file?
Someone said that it would help Google if you enter a "last modified date" in your .htaccess file or scripts in your pages.
I really do not have a clue what a .htaccess file is or which information including the syntax would be necessary.
Thank you,
lala
|

02-21-2007, 11:53 AM
|
 |
Facilitator
5166 posts this year. Platinum VIP!Trusted Member - This user is a Master!
Last months UKWW Tokens: 283
|
|
|
Join Date: Jun 2003
Location: London, England.
Posts: 11,929
Thanks: 3
Thanked 29 Times in 20 Posts
Nominated 0 Times in 0 Posts
TOTW/F/M Award(s): 0
|
|
Lala,
I do not think its a good idea or its true to modify .htaccess just to add "last modified date" if you have not modified anything in the first place. .htaccess is a hidden file (hidden from users and web browser) but you can see if you set your ftp software to view hidden file.
I will suggest you leave it well alone unless you know what you are doing 
|

02-21-2007, 12:59 PM
|
|
Senior Member
5 posts this year. needs some grease! New user, who has not interacted much yet.
|
|
|
Join Date: Feb 2007
Posts: 148
Thanks: 0
Thanked 0 Times in 0 Posts
Nominated 0 Times in 0 Posts
TOTW/F/M Award(s): 0
|
|
More questions
Temi,
Thank you.
What is the file for? Who would write changes to it? And in case you have updated content on the site do you then have to update the file?
I would not mind to have at least a look on one to get an idea what this is all about. Is there a safe way just to check the entries in the file?
lala 
|

02-21-2007, 01:02 PM
|
 |
Facilitator
5166 posts this year. Platinum VIP!Trusted Member - This user is a Master!
Last months UKWW Tokens: 283
|
|
|
Join Date: Jun 2003
Location: London, England.
Posts: 11,929
Thanks: 3
Thanked 29 Times in 20 Posts
Nominated 0 Times in 0 Posts
TOTW/F/M Award(s): 0
|
|
Lala,
Yes, its a good idea to have a look. The file is used for a number of thing for example, until about 4 or 5 weeks ago, this forum was at UK Forums - Webmaster SEO & Small Business Discussions - Powered by vBulletin . Then I decided that its better on the current url. I used .httaccess file to point all traffic that are still going to the old url to come to this new url. That is just one of the several uses it can be put to. I hope others will give example of how they have used .httaccess file 
|

02-21-2007, 03:51 PM
|
|
Senior Member
5 posts this year. needs some grease! New user, who has not interacted much yet.
|
|
|
Join Date: Feb 2007
Posts: 148
Thanks: 0
Thanked 0 Times in 0 Posts
Nominated 0 Times in 0 Posts
TOTW/F/M Award(s): 0
|
|
Separate file
Is there any example file that I could have a look at (including good articles, books etc)? I wondered what the file itself would loook like. Or is it included into t he HTML header?
lala
|

02-21-2007, 05:27 PM
|
 |
Facilitator
5166 posts this year. Platinum VIP!Trusted Member - This user is a Master!
Last months UKWW Tokens: 283
|
|
|
Join Date: Jun 2003
Location: London, England.
Posts: 11,929
Thanks: 3
Thanked 29 Times in 20 Posts
Nominated 0 Times in 0 Posts
TOTW/F/M Award(s): 0
|
|
Lala,
The file is hidden (which means you cannot see it unless you instruct your browser or ftp software to reveal hiddent files as well)
Its and ugly complicated looking file........ I have just pasted one below. Its the defaul .httaccess file that come with a directory software called eSyndicate.
I don't think you need a book for it, just do a search on the net and you will find a lot of tutorials on .httaccess file. BTW, its a Unix/Linux file, I don't think it exist on Windows platform.
-----------here is a .httaccess file---------------------
# enable mod_rewrite
RewriteEngine on
# mod_rewrite rules for categories pages
RewriteRule ^(.*)/$ index.php?category=$1 [QSA,L]
RewriteRule ^(.*)/index([0-9]+).html$ index.php?category=$1&page=$2 [QSA,L]
# mod_rewrite rule for suggest link page
RewriteRule ^suggest-link([0-9]+).html$ suggest-link.php?id=$1 [QSA,L]
# mod_rewrite rules for new links page
RewriteRule ^new-links.html$ new-links.php [QSA,L]
RewriteRule ^new-links([0-9]+).html$ new-links.php?page=$1 [QSA,L]
# mod_rewrite rules for top links page
RewriteRule ^top-links.html$ top-links.php [QSA,L]
RewriteRule ^top-links([0-9]+).html$ top-links.php?page=$1 [QSA,L]
# mod_rewrite rules for popular links page
RewriteRule ^popular-links.html$ popular-links.php [QSA,L]
RewriteRule ^popular-links([0-9]+).html$ popular-links.php?page=$1 [QSA,L]
# mod_rewrite rules for editors links page
RewriteRule ^editor-links/index.html$ editor-links.php [QSA,L]
RewriteRule ^editor-links/index([0-9]+).html$ editor-links.php?page=$1 [QSA,L]
# mod_rewrite rules for view link page
RewriteRule ^(.*)/(.*)-l([0-9]+).html$ view-link.php?cat=$1&title=$2&id=$3 [QSA,L]
# mod_rewrite rules for news page
RewriteRule ^news.html$ news.php [QSA,L]
RewriteRule ^(.*)-n([0-9]+).html$ news.php?title=$1&id=$2 [QSA,L]
# mod_rewrite rules for additional pages
RewriteRule ^p(.*).html$ page.php?name=$1 [QSA,L]
# mod_rewrite rules for error pages
RewriteRule ^([0-9]+).htm$ error.php?error=$1 [QSA,L]
ErrorDocument 500 /dir/500.htm
ErrorDocument 404 /dir/404.htm
ErrorDocument 403 /dir/403.htm
ErrorDocument 401 /dir/401.htm
|

02-21-2007, 09:17 PM
|
 |
Super Moderator
960 posts this year. Platinum VIP!Trusted Member - This user is a Master!
Last months UKWW Tokens: 7
|
|
|
Join Date: Oct 2004
Posts: 2,272
Thanks: 2
Thanked 11 Times in 11 Posts
Nominated 0 Times in 0 Posts
TOTW/F/M Award(s): 0
|
|
The 'last modified ' notice is sent by your web server. whoever told you to add it to your htaccess is wrong. Most 99% of servers supply the last modified timestamp, but dynamic sites always give a last modified datestamp as the time the spider hits it.
Be VERY carefull what you do with your htaccess,as you can block the robots completely from visiting the site if you get it wrong.
|

02-22-2007, 06:14 AM
|
 |
Facilitator
5166 posts this year. Platinum VIP!Trusted Member - This user is a Master!
Last months UKWW Tokens: 283
|
|
|
Join Date: Jun 2003
Location: London, England.
Posts: 11,929
Thanks: 3
Thanked 29 Times in 20 Posts
Nominated 0 Times in 0 Posts
TOTW/F/M Award(s): 0
|
|
Quote:
Originally Posted by OldWelshGuy
Be VERY carefull what you do with your htaccess,as you can block the robots completely from visiting the site if you get it wrong.
|
Lala, I will go one step further and say DO NOT TOUCH your .httaccess at all unless you absolutely need and even them, ensure you have a backup of the original .httaccess file so that you can restore it if changes you made goes wrong.
Good luck
|

02-22-2007, 02:18 PM
|
|
Senior Member
5 posts this year. needs some grease! New user, who has not interacted much yet.
|
|
|
Join Date: Feb 2007
Posts: 148
Thanks: 0
Thanked 0 Times in 0 Posts
Nominated 0 Times in 0 Posts
TOTW/F/M Award(s): 0
|
|
No worries
Thank you guys.
Do not worry. I am just curious. I would not dare to change the file unless I know more about it (if it was true that it helps with Google I would have tried to find someone who knows what he/she is doing).
lala
|

02-22-2007, 03:18 PM
|
 |
Super Moderator
960 posts this year. Platinum VIP!Trusted Member - This user is a Master!
Last months UKWW Tokens: 7
|
|
|
Join Date: Oct 2004
Posts: 2,272
Thanks: 2
Thanked 11 Times in 11 Posts
Nominated 0 Times in 0 Posts
TOTW/F/M Award(s): 0
|
|
Pm me your url and I will take a quick look at things for you. You can then rest assured as to what needs doing, (if anything)
|
|
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
|
|
|
|
|