Re: Ceon URI Mapping (SEO)
Hi,
Quote:
Originally Posted by
g1smd
That being so, the file should use the most efficient code to get the job done. In this case, trailing .* characters on multiple patterns waste CPU cycles that you might later need elsewhere in serving the pages.
I agree.. so thank you for the extra information. Saying "should" wasn't quite right, it should really have been "would be better" as "should" implies that the original is wrong rather than simply inefficient but I'm glad you've posted the information that you have.
I'll update the documentation for the soon to be released version 3.4.0 to not use the wildcard matching. I wouldn't have thought having an additional match for "anything else" would make much of a difference but since not using it may make even a slight difference then it's definitely best not to use it - closer to the ideal situation of maximum efficiency!
Thanks again for your helpful tips! :)
All the best...
Conor
ceon
Re: Ceon URI Mapping (SEO)
Hi,
Quote:
Originally Posted by
damiantaylor
I just checked out the link you gave me and the source of your site. I also used the above site to see what results it gave for your examples page.
It's coming back with many files not found.. all relatively loaded files are coming back as not found.. this includes not just your images but CSS and JavaScript files as well.
The reason for this is the software on that analysis site doesn't know what a "base href" tag is so it is building all the links wrongly.
So ignore its file not found errors - it's the software that has the problems, not your site, it is fine!
You should probably use a working analysis service if you are still interested in analysis results.
That should set your mind at rest!
All the best..
Conor
ceon
Re: Ceon URI Mapping (SEO)
After several hours of trial, error, and searching I thought to post here.
A client is hosting on a virtual private server with InMotionHosting. No matter what I have attempted I cannot get the rewrite rules to work. I am new to the whole virtual private server business. Anyway, mod_rewrite is enabled.
So I attempted to get back to basics and just use the instruction's rules.
Quote:
RewriteEngine On
# Don't rewrite any URIs ending with a file extension (ending with .[xxxx])
RewriteCond %{REQUEST_URI} !\.[a-zA-Z]{2,4}$
# Don't rewrite admin directory
RewriteCond %{REQUEST_URI} !^/admin.* [NC]
# Don't rewrite editors directory
RewriteCond %{REQUEST_URI} !^/editors.* [NC]
# Don't rewrite cPanel directories
RewriteCond %{REQUEST_URI} !/cpanel.* [NC]
RewriteCond %{REQUEST_URI} !/frontend.* [NC]
# Handle all other URIs using Zen Cart (index.php)
RewriteRule (.*) index.php?%{QUERY_STRING} [L]
No dice. I get the following message:
Quote:
The requested URL /product-manuals was not found on this server.
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
I have tried added RewriteBase / and other directives but no luck at all. Anyone have any suggestions? This site is being moved from GoDaddy where the client had no problems with the plugin. They just had a lot of performance issues : ).
Re: Ceon URI Mapping (SEO)
You're capturing the path part of the incoming URL request into the $1 back-reference, but then your rule does not use that information.
The Query String data will also be blank, so the script has nothing at all to work with.
Re: Ceon URI Mapping (SEO)
Hi,
I have a problem that seems to be with this URI mapping mod. It's a fantastic mod by the way, worked first time and really easy to add extra pages to the mapping :) Thanks Conor!
The problem I have is that I am passing an array as a hidden field on a form.
The form HTML is as follows:
<form name="filter" action="http://www.myurl.com" method="get">
<input type="hidden" name="main_page" value="index" />
<input type="hidden" name="cPath" value="8" />
<input type="hidden" name="Flt_Grade[]" value="100" />
<select name="filter_id" onchange="this.form.submit()">
<option value="1">Most Popular</option>
<option value="2" selected="selected">Price: Low to High</option>
<option value="3">Price: High to Low</option>
<option value="4">Title</option>
<option value="6">Date Added: Newest</option>
<option value="7">Date Added: Oldest</option>
</select>
</form>
When option 4 in the dropdown is selected, the URL should be
http://www.myurl.com&main_page=index...0&filter_id=4/
Where %5B = [ and %5D = ]
But what I actually get is
http://www.myurl.com&main_page=index...=&filter_id=4/
The Flt_Grade array has lost its square brackets and its value.
If I switch URI mapping off, it works ok.
Do you know if this likely be a problem with my .htaccess file or with the mod itself?
Re: Ceon URI Mapping (SEO)
Hi Damian,
Glad you like the module!
Quote:
Originally Posted by
damiantaylor
The two URIs you have posted are both unmapped. As the URI uses "main_page=" it is clear that no URI mapping has taken place.
So I can't see how it could be the URI Mapping software. It must be some sort of parsing problem in your .htaccess file which is stripping the brackets?
I hope that helps.
All the best...
Conor
ceon
Re: Ceon URI Mapping (SEO)
Thanks for the quick reply Conor!
Sorry, that URL was from my test site when I switched mapping off.
The URL I get is
myurl.com/FilesStones?Flt_Grade=&sort=20a&alpha_filter_id=4[/url]
I'm not very good on .htaccess but I had a feeling that may be the problem!
Can you spot the error in my .htaccess file? Sorry to ask you this but I haven't got a clue what it all means :blush:
Code:
RewriteEngine On
# Don't rewrite any URIs ending with a file extension (ending with .[xxxx])
RewriteCond %{REQUEST_URI} !\.[a-zA-Z]{2,4}$
# Don't rewrite admin directory
RewriteCond %{REQUEST_URI} !^/admin.* [NC]
# Don't rewrite editors directory
RewriteCond %{REQUEST_URI} !^/editors.* [NC]
# Don't rewrite cPanel directories
RewriteCond %{REQUEST_URI} !/cpanel.* [NC]
RewriteCond %{REQUEST_URI} !/frontend.* [NC]
# Handle all other URIs using Zen Cart (index.php)
RewriteRule (.*) index.php?%{QUERY_STRING} [L]
RewriteEngine On
# Prepend www if http://myurl.com
RewriteCond %{HTTP_HOST} ^myurl.com
RewriteRule (.*) http://www.myurl.com [R=301] [L]
Re: Ceon URI Mapping (SEO)
Hi,
Quote:
Originally Posted by
damiantaylor
Sorry, that URL was from my test site when I switched mapping off.
The URL I get is
myurl.com/FilesStones?Flt_Grade=&sort=20a&alpha_filter_id=4[/url]
Hmm, so a redirection is taking place. You've found a bug in the module.. it doesn't re-encode array parameters in a query string properly when performing a redirect from a dynamic URI to a static URI mapping.
Please get in contact with me via this link with FTP and admin details for your site and I'll upload a test version of a fix.. you can then let me know if the fix works and I'll include it in 3.4.0.
All the best..
Conor
ceon
Re: Ceon URI Mapping (SEO)
Hi Damian,
By the way, this wouldn't have happened if you had the form go to the correct URI.. Instead of...
Code:
<form name="filter" action="http://www.myurl.com" method="get">
<input type="hidden" name="main_page" value="index" />
<input type="hidden" name="cPath" value="8" />
You should be using:
Code:
<form name="filter" action="http://www.myurl.com/FilesStones" method="get">
The following should be deleted:
Code:
<input type="hidden" name="main_page" value="index" />
<input type="hidden" name="cPath" value="8" />
Regardless, get in contact with me as requested in the previous e-mail.
All the best...
Conor
ceon
Re: Ceon URI Mapping (SEO)
Will do Conor!
I'll have to wait til I get home for that one though....should be around 4.30