Jump to content

Resolved - SEO questions


Guest AlanGalbraith

Recommended Posts

Guest AlanGalbraith

My hosting server is a Windows Server... will the SEO system and .htaccess file work?

i've tried it, and the cart system generates the SEO friendly URLS, but I get a 404 file not found error when trying to use them.

I rebuilt the store map, emptied cache but still no joy.

Link to comment
Share on other sites

Guest AlanGalbraith

Running 5.1.2.2 CC (just saw that 5.1.3 is avail, will update)

cant really move to a Linux hosting service as I've got lots of other URLS and they are all with this hosting service. The site is running on Microsoft-IIS/6.0 right now.

Yes, I did install the .htaccess file. Turned on Enable SEO URLs to "Yes" and eneterd data in the "Custom SEO URL Path" dialog under product descriptions. Rebuild the Site Map and clears the store cache...

no joy...

the SEO firendly URLS are generated, but clicking on the links leads to a 404 page not found error.

Link to comment
Share on other sites

I like what I see with the URLs, so the problem then probably lies with the code in the .htaccess file.

If there is one located at the root of your domain, let's see it, in addition to the one that is supposed to be in the 'store' folder.

I actually didn't get a 404 error, I got:


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">

<html>

  <head>



	<meta name="revisit-after" content="10">

	<meta http-equiv="Content-Type" content="text/html; charset=utf-8">



	<script type="text/javascript" language="JavaScript"

		src="http://cdn.dsultra.com/js/registrar.js"></script>



	<script type="text/javascript" language="JavaScript">

	  registrar_frameset({a_id: #####}); // edit this to pass your portfolio ID

	</script>



  </head>

</html>

Link to comment
Share on other sites

Guest AlanGalbraith

I like what I see with the URLs, so the problem then probably lies with the code in the .htaccess file.

If there is one located at the root of your domain, let's see it, in addition to the one that is supposed to be in the 'store' folder.

I actually didn't get a 404 error, I got:

there is no .htaccess file in the root folder of my site...

I just hit the "install .htaccess" button in the "Search Engine Settings" panel.

here is the content of the .htaccess file in the /store directory


## File Security

<FilesMatch ".(htaccess)$">

 Order Allow,Deny

 Deny from all

</FilesMatch>



#### Apache directory listing rules ####

DirectoryIndex index.php index.htm index.html

IndexIgnore *



#### Rewrite rules for SEO functionality ####



<IfModule mod_rewrite.c>

  RewriteEngine On



  ######## START v4 SEO URL BACKWARD COMPATIBILITY ########

  RewriteCond %{QUERY_STRING} (.*)$

  RewriteCond %{REQUEST_FILENAME} !-f

  RewriteRule cat_([0-9]+)(.[a-z]{3,4})?(.*)$    index.php?_a=category&cat_id=$1&%1 [NC]



  RewriteCond %{QUERY_STRING} (.*)$

  RewriteCond %{REQUEST_FILENAME} !-f

  RewriteRule prod_([0-9]+)(.[a-z]{3,4})?$        index.php?_a=product&product_id=$1&%1 [NC]



  RewriteCond %{QUERY_STRING} (.*)$

  RewriteCond %{REQUEST_FILENAME} !-f

  RewriteRule info_([0-9]+)(.[a-z]{3,4})?$        index.php?_a=document&doc_id=$1&%1 [NC]



  RewriteCond %{QUERY_STRING} (.*)$

  RewriteCond %{REQUEST_FILENAME} !-f

  RewriteRule tell_([0-9]+)(.[a-z]{3,4})?$        index.php?_a=product&product_id=$1&%1 [NC]



  RewriteCond %{QUERY_STRING} (.*)$

  RewriteCond %{REQUEST_FILENAME} !-f

  RewriteRule _saleItems(.[a-z]+)?(?.*)?$        index.php?_a=saleitems&%1 [NC,L]

  ######## END v4 SEO URL BACKWARD COMPATIBILITY ########



  RewriteCond %{REQUEST_FILENAME} !-f

  RewriteCond %{REQUEST_FILENAME} !-d

  RewriteCond %{REQUEST_URI} !=/favicon.ico

  RewriteRule ^(.*).html?$ index.php?seo_path=$1 [L,QSA]

</IfModule>



Link to comment
Share on other sites

OK, I remember some conversations about how the .htaccess file needs tweaking if the store is in a subfolder. Maybe searching these forums (including those of CC4) may show something.

RewriteRule ^/shop/(.*).html?$ /shop/index.php?seo_path=$1 [L,QSA]

I don't know if the forward slash needs escaping, /, or if it's just:

RewriteRule ^/shop/(.*).html?$ /shop/index.php?seo_path=$1 [L,QSA]

Link to comment
Share on other sites

Guest AlanGalbraith

OK, I remember some conversations about how the .htaccess file needs tweaking if the store is in a subfolder. Maybe searching these forums (including those of CC4) may show something.

RewriteRule ^/shop/(.*).html?$ /shop/index.php?seo_path=$1 [L,QSA]

I don't know if the forward slash needs escaping, /, or if it's just:

RewriteRule ^/shop/(.*).html?$ /shop/index.php?seo_path=$1 [L,QSA]

woudl I just replace "shop" with "store" in my case?

Link to comment
Share on other sites

Guest AlanGalbraith

here is what I found when I searched... tried it but it doesnt seem to work either...

http://forums.cubeca...__fromsearch__1

and the above fix made that work,

but then I found sometimes request were reverting back to what "store.domain.com" points to

domain.com/store (which didn't work with the stock rewrite either for some reason )

to get both forms of the url to work this is what I ended up doing

note: I had to hard code the "store" perhaps someone with more .htaccess knowledge could improve

RewriteCond %{REQUEST_FILENAME} !-f

RewriteCond %{REQUEST_FILENAME} !-d

RewriteCond %{REQUEST_URI} !=/favicon.ico

RewriteCond %{HTTP_HOST} ^
store

RewriteRule ^(.*).html?$ %1/index.php?seo_path=$1 [L,QSA]

RewriteCond %{REQUEST_FILENAME} !-f

RewriteCond %{REQUEST_FILENAME} !-d

RewriteCond %{REQUEST_URI} !=/favicon.ico

RewriteRule ^(.*).html?$ %1/
store
/index.php?seo_path=$1 [L,QSA]

I couldn't figure out how to get either to work with out hardcoding the "store".

I hope this helps some of those who are having problems.

Link to comment
Share on other sites

I do not have the same .htaccess in the root that I have in my subfolder. Here's the part of my store folder .htaccess as a comparison. SEO is turned on. I don't have any backward compatibility section in mine.


<IfModule mod_rewrite.c>

RewriteEngine on

RewriteCond %{HTTP_HOST} !^dirtybutter.com$

RewriteRule ^(.*)$ http://dirtybutter.com/$1 [R=301]

RewriteCond %{REQUEST_FILENAME} !-f

RewriteCond %{REQUEST_FILENAME} !-d

RewriteCond %{REQUEST_URI} !=/favicon.ico

RewriteRule ^(.*).html?$ index.php?seo_path=$1 [L,QSA]

</IfModule>





vs YOURS





RewriteCond %{REQUEST_FILENAME} !-f

  RewriteCond %{REQUEST_FILENAME} !-d

  RewriteCond %{REQUEST_URI} !=/favicon.ico

  RewriteRule ^(.*).html?$ index.php?seo_path=$1 [L,QSA]

Link to comment
Share on other sites

You said, "The site is running on Microsoft-IIS/6.0 right now."

Bad news.

Server: Microsoft-IIS/6.0

X-Powered-By: ASP.NET, PHP/5.2.12

Since this is not Apache, there is no ability to rewrite the the URLs using .htaccess.

For IIS6, see:

www.isapirewrite.com

www.urlrewriter.net

iirf.codeplex.com

For Abyss Web Server (what I use), see the built-in server configuration screen.

You will need to get your hosting provider involved.

Link to comment
Share on other sites

Guest AlanGalbraith

well poop :D

mihgt just have to forge ahead without SEO friendly URL's... dont know that I want to tranfer it all over to the new server... I guess it wouldnt be THAT much of a hassle... I dont have a ton of products already in the store and I'm still tweaking it up before going live...

are SEO friendly urls really THAT big of a deal?

Link to comment
Share on other sites

The feelings and assertions about SEO techniques range from atheism, to agnosticism, to radical religious beliefs.

One could say, "If you use them and they don't work, what have you lost? If they do work and you don't use them, what have you lost?"

Link to comment
Share on other sites

Guest AlanGalbraith

ahhhh... I see :D

well, my hosting serivce has Linux plans, so to set one up will run $3/mo.. so its not a BIG deal on cost... I could likely still use the same database server and database, just move all the files over to the new server. Worst case I only have 21 test items in the store right now so if I had to start from scratch (again :D) it wouldnt be the end of the world. I saved off my custom skin the last time I had to wipe it all out and that worked fine setting it up agian... sigh.... :D

Link to comment
Share on other sites

SEO urls may not be that big a deal in terms of page rank,etc., but when I send a link to a product to a potential customer they see the actual product title in the link without any gobbledygook added to it. Just looks cleaner.

Good luck with the server change. Linux is the way to go.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...