Jump to content
spidometrs

[CONTRIBUTION] Ultimate SEO URLs v2.1 - by Chemo

Recommended Posts

Thanks a lot Arild Evensen !

 

Best Regards,

 

Nathali

 

 

It is very strange!

 

I checked all the files on the English side and they are ok..

 

Could the reason for that is a javascript that a programmer modified in my checkout_payment.php and on some other files?

 

Or maybe my database has errors..

 

In my seo.class.php file I have in these lines the code..

1057 $result = $this->DB->FetchArray( $this->DB->Query( $sql ) );

1058 $aName = $this->strip( $result['aName'] );

 

my database is 4.2.2 I think..

 

Or maybe I need to erase the database SEO tables and create them again

 

Any clue please?

 

Regards,

Nathali


Best Regards,

Nathali

Share this post


Link to post
Share on other sites
It is very strange!

 

I checked all the files on the English side and they are ok..

 

Could the reason for that is a javascript that a programmer modified in my checkout_payment.php and on some other files?

 

Or maybe my database has errors..

 

In my seo.class.php file I have in these lines the code..

1057 $result = $this->DB->FetchArray( $this->DB->Query( $sql ) );

1058 $aName = $this->strip( $result['aName'] );

 

my database is 4.2.2 I think..

 

Or maybe I need to erase the database SEO tables and create them again

 

Any clue please?

 

Regards,

Nathali

 

 

headers already sent error is normaly due to whitespaces before a opening php tag or after a closing tag. So you may not be able to see the error. You have to check every start and end and make sure there is no one there.

 

I am not sure it is in seo.class file. Check index.php at line 39 it should be the first html output and the last php code over that line is call to language file. "

require(DIR_WS_LANGUAGES . $language . '/' . FILENAME_DEFAULT);"

Sins the error is only with one language i will bet the error is in the language file. check them for withspace, newline ...

Share this post


Link to post
Share on other sites

Is anyone else having issues with their manufacturer and category drop down boxes after an install of FWR Medias release of this contribution? Every drop down box on my site redirects to index.php and I haven't found a solution for this.

 

Any thoughts or suggestions? Thanks.

Share this post


Link to post
Share on other sites
It is very strange!

 

I checked all the files on the English side and they are ok..

 

Could the reason for that is a javascript that a programmer modified in my checkout_payment.php and on some other files?

 

Or maybe my database has errors..

 

In my seo.class.php file I have in these lines the code..

1057 $result = $this->DB->FetchArray( $this->DB->Query( $sql ) );

1058 $aName = $this->strip( $result['aName'] );

 

my database is 4.2.2 I think..

 

Or maybe I need to erase the database SEO tables and create them again

 

Any clue please?

 

Regards,

Nathali

Did you check the edits as I suggested elsewhere?


The Coopco Underwear Shop

 

If you live to be 100 years of age, that means you have lived for 36,525 days. Don't waste another, there aren't many left.

Share this post


Link to post
Share on other sites
Is anyone else having issues with their manufacturer and category drop down boxes after an install of FWR Medias release of this contribution? Every drop down box on my site redirects to index.php and I haven't found a solution for this.

 

Any thoughts or suggestions? Thanks.

 

Not sure what is wrong with your site that is not enough info to go on. Perhaps a link?

Share this post


Link to post
Share on other sites
Well that is deffo the problem which must mean my code is faulty .. are you online for quick responses for a bit?

 

 

"The site can be found here. It's a basic install of OSC and I haven't done much work on it yet...

 

I really appreciate it. Thanks again."

 

 

 

It's the same issue we went over a few days ago. I can't seem to figure out what's going on with the redirects. Any suggestions?

 

Thanks again.

Share this post


Link to post
Share on other sites
"The site can be found here. It's a basic install of OSC and I haven't done much work on it yet...

 

I really appreciate it. Thanks again."

 

 

 

It's the same issue we went over a few days ago. I can't seem to figure out what's going on with the redirects. Any suggestions?

 

Thanks again.

 

SEO URLs are off so I can't test anything. What I actually need is for you to be online with me to run some tests.

Share this post


Link to post
Share on other sites
SEO URLs are off so I can't test anything. What I actually need is for you to be online with me to run some tests.

 

 

When would be a good time? I will reconfigure the contribution and await your response. Thanks again.

Share this post


Link to post
Share on other sites
When would be a good time? I will reconfigure the contribution and await your response. Thanks again.

 

Well now if you are about.

 

I have a few mins while waiting for a customer to get back to me.

Edited by FWR Media

Share this post


Link to post
Share on other sites
Well now if you are about.

 

I have a few mins while waiting for a customer to get back to me.

 

 

Let me know what I should do... Thanks

Share this post


Link to post
Share on other sites
Let me know what I should do... Thanks

 

 

Per FWR Media's request:

 

Please move this to the support topic

 

With a description of the problem, and ideally a link

 

where your shop is located e.g. root = www.mysite.com/

 

How RewriteBase is set e.g. / or /catalog/ etc

 

This post has been edited by FWR Media: Yesterday, 04:09 PM

 

 

 

 

I just installed Ultimate_SEO_URLSv21d_UPDATED (v2.6 did not take for me so I followed advice from others to try 2.1)

and the home page (it is a test site) comes up.

 

However, when I click on categories or manufacturers while an SEO friendly URL appears for the category, the actual pafe does not render and I get:

 

Not Found

The requested URL /public_html/index.php was not found on this server.

 

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

Apache/1.3.41 Server at brightparrots.com Port 80

 

 

The test site is birghtparrots.com, the catalog is in public_html directory

 

 

I did rename "directory" to "public_html", but I am guessing I did not do this part quite right.

 

Yes, site is on linux, mod_rewrite is enabled and per

 

QUOTE (hwkd @ Nov 6 2008, 02:07 PM) *

Well, just installed Ultimate_SEO_URLSv21d_UPDATED and home page comes up, click on categories and a SEO friendly appears for the category, but I get:

 

 

---------------------------------------

Not Found

The requested URL /public_html/index.php was not found on this server.

 

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

Apache/1.3.41 Server at brightparrots.com Port 80

----------------------------------------------------------------

 

 

rendered in the page.

 

I did rename "directory" to "public_html", but I am guessing I did not do this part quite right and it is the source of the problem.

 

 

 

Yes, it is on linux serve and mod_rewrite is enabled and per FWR Media:

 

 

Put rubbish in your .htaccess .. like ..

 

jkfgkleajfgjoireujgoivjsvdklwjdvkjkasjdvkjl'

 

If it doesn't kick errors then you need AllowOveride set to ALL (or to specifics).

 

 

I did this and it did kick out an error.

 

 

Thanks

Share this post


Link to post
Share on other sites
Per FWR Media's request:

 

Please move this to the support topic

 

With a description of the problem, and ideally a link

 

where your shop is located e.g. root = www.mysite.com/

 

How RewriteBase is set e.g. / or /catalog/ etc

 

This post has been edited by FWR Media: Yesterday, 04:09 PM

 

 

 

 

I just installed Ultimate_SEO_URLSv21d_UPDATED (v2.6 did not take for me so I followed advice from others to try 2.1)

and the home page (it is a test site) comes up.

 

However, when I click on categories or manufacturers while an SEO friendly URL appears for the category, the actual pafe does not render and I get:

 

Not Found

The requested URL /public_html/index.php was not found on this server.

 

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

Apache/1.3.41 Server at brightparrots.com Port 80

 

 

The test site is birghtparrots.com, the catalog is in public_html directory

 

 

I did rename "directory" to "public_html", but I am guessing I did not do this part quite right.

 

Yes, site is on linux, mod_rewrite is enabled and per

 

QUOTE (hwkd @ Nov 6 2008, 02:07 PM) *

Well, just installed Ultimate_SEO_URLSv21d_UPDATED and home page comes up, click on categories and a SEO friendly appears for the category, but I get:

 

 

---------------------------------------

Not Found

The requested URL /public_html/index.php was not found on this server.

 

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

Apache/1.3.41 Server at brightparrots.com Port 80

----------------------------------------------------------------

 

 

rendered in the page.

 

I did rename "directory" to "public_html", but I am guessing I did not do this part quite right and it is the source of the problem.

 

 

 

Yes, it is on linux serve and mod_rewrite is enabled and per FWR Media:

 

 

Put rubbish in your .htaccess .. like ..

 

jkfgkleajfgjoireujgoivjsvdklwjdvkjkasjdvkjl'

 

If it doesn't kick errors then you need AllowOveride set to ALL (or to specifics).

 

 

I did this and it did kick out an error.

 

 

Thanks

 

If the shop is in public_html and not in a folder then .htacess should read ..

 

RewriteBase /

Share this post


Link to post
Share on other sites
Per FWR Media's request:

 

Please move this to the support topic

 

With a description of the problem, and ideally a link

 

where your shop is located e.g. root = www.mysite.com/

 

How RewriteBase is set e.g. / or /catalog/ etc

 

This post has been edited by FWR Media: Yesterday, 04:09 PM

 

 

Is this directed towards me? :huh:

 

 

@FWR Media

 

I have turned on SEO URL's and all is set for your advice. Thanks.

Share this post


Link to post
Share on other sites
Is this directed towards me? :huh:

 

 

@FWR Media

 

I have turned on SEO URL's and all is set for your advice. Thanks.

 

open includes/classes/seo.class.php

 

Find ..

 

		function check_redirect(){
			$this->need_redirect = false;

 

Add below it ..

// BOF REMOVE ME
die('getenv(\'PATH_INFO\') = ' . getenv('PATH_INFO'));
// EOF REMOVE ME

 

Then click the manufacturers link .. the script should die leaving a message about getenv. Please report back what it says (then remove the REMOVE ME code)

Share this post


Link to post
Share on other sites
Please report back what it says (then remove the REMOVE ME code)

 

 

This is what is returned: getenv('PATH_INFO') = /temp/index.php

Share this post


Link to post
Share on other sites
This is what is returned: getenv('PATH_INFO') = /temp/index.php

 

Perfect!! now is the seo.class.php back to standard prior to any mods?

Share this post


Link to post
Share on other sites
If the shop is in public_html and not in a folder then .htacess should read ..

 

RewriteBase /

 

Sorry if unclear, it is in a folder named "public_html" one down from the root, so I have:

 

RewriteBase /public_html/

 

 

 

Just "RewriteBase"

 

in .htaccess generated internal server error.

 

Thanks. What else. I see a lot of stuff similar on this thread but cannot find one that pins down a resolution.

Share this post


Link to post
Share on other sites
Sorry if unclear, it is in a folder named "public_html" one down from the root, so I have:

 

RewriteBase /public_html/

 

 

 

Just "RewriteBase"

 

in .htaccess generated internal server error.

 

Thanks. What else. I see a lot of stuff similar on this thread but cannot find one that pins down a resolution.

 

public_html is web root

 

and not just RewriteBase but ..

 

RewriteBase /

Share this post


Link to post
Share on other sites

I found one error with the manufacture drop down list.

 

If i select a manufacture it shows correctly.

 

If i then select "select a manufacture" again it goes to a 404 with the url ending like this "/-m-.html"

 

I think this can be solved with rewriterule to index.php but i am not sure on how to put this together without breaking some of the other rules.

Share this post


Link to post
Share on other sites
Yes it is. Thanks.

 

Ok now temporarily replace the code between ..

 

$this->need_redirect = false;

 

and ..

 

$this->uri = ltrim( basename($_SERVER['REQUEST_URI']), '/' );

 

With ..

 

				// BOF: FWR - Some servers show the folders in getenv('PATH_INFO') like /catalog/shop/
			$getEnvPathInfo = getenv('PATH_INFO');
			if( false !== strpos($getEnvPathInfo, DIR_WS_HTTP_CATALOG) ){
			  $rawpath = str_replace(DIR_WS_HTTP_CATALOG, '', $getEnvPathInfo);
			} else {
			  $rawpath = $getEnvPathInfo;
			}  
			$this->path_info = is_numeric(strpos(ltrim($rawpath, '/') , '/')) ? ltrim($rawpath, '/') : NULL;
			// EOF: FWR - Some servers show the folders in getenv('PATH_INFO') like /catalog/shop/

Share this post


Link to post
Share on other sites
Ok now temporarily replace the code between ..

 

$this->need_redirect = false;

 

and ..

 

$this->uri = ltrim( basename($_SERVER['REQUEST_URI']), '/' );

 

With ..

 

				// BOF: FWR - Some servers show the folders in getenv('PATH_INFO') like /catalog/shop/
			$getEnvPathInfo = getenv('PATH_INFO');
			if( false !== strpos($getEnvPathInfo, DIR_WS_HTTP_CATALOG) ){
			  $rawpath = str_replace(DIR_WS_HTTP_CATALOG, '', $getEnvPathInfo);
			} else {
			  $rawpath = $getEnvPathInfo;
			}  
			$this->path_info = is_numeric(strpos(ltrim($rawpath, '/') , '/')) ? ltrim($rawpath, '/') : NULL;
			// EOF: FWR - Some servers show the folders in getenv('PATH_INFO') like /catalog/shop/

 

Genius! This seems to have fixed it. I'll have a look around and see if I can confirm with absolute certainty. Feel free to do the same. Thanks.

Share this post


Link to post
Share on other sites
Genius! This seems to have fixed it. I'll have a look around and see if I can confirm with absolute certainty. Feel free to do the same. Thanks.

 

You have helped me out too, thanks.

 

This is the only known "bug" in 2.1d ORIGINAL updated. And it's related to odd occasions where certain servers seem to report a different value for PATH_INFO.

Share this post


Link to post
Share on other sites
I found one error with the manufacture drop down list.

 

If i select a manufacture it shows correctly.

 

If i then select "select a manufacture" again it goes to a 404 with the url ending like this "/-m-.html"

 

I think this can be solved with rewriterule to index.php but i am not sure on how to put this together without breaking some of the other rules.

 

That is not an issue in 2.1d ORIGINAL updated and I don't support other versions sorry.

Share this post


Link to post
Share on other sites
You have helped me out too, thanks.

 

This is the only known "bug" in 2.1d ORIGINAL updated. And it's related to odd occasions where certain servers seem to report a different value for PATH_INFO.

 

 

I'm glad we were able to pinpoint and fix this bug. This will likely help many other users as well.

 

On a seperate note: If I ever decide to move my store from /temp/ to root will these changes need to be updated?

 

I really appreciate you taking the time to sort this out with me. Your support and dedication is well noted. Thanks again.

Edited by DimeNote

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×