Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

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


Recommended Posts

I edited the file with the html editor and have it in, but it lost the . in front. Windows does not seem to allow it.

 

I can't see .htaccess unless in the file manager. I added the string to htaccess but can not delete the old one to rename the new one

Edited by Mad Duck
Link to comment
Share on other sites

Frustrated here

 

Filezilla and Core ftp programs can not see the .htaccess file in the catalog directory.

 

I saved it from admin/file manager and changed it and can only upload it without the . Then I tried to change it to have the . and of course a file already exists, but I can't delete it.

 

I try and paste the additions to the file from admin/file manager and it does not take them.

 

How can I change this?

Link to comment
Share on other sites

Frustrated here

 

Filezilla and Core ftp programs can not see the .htaccess file in the catalog directory.

 

I saved it from admin/file manager and changed it and can only upload it without the . Then I tried to change it to have the . and of course a file already exists, but I can't delete it.

 

I try and paste the additions to the file from admin/file manager and it does not take them.

 

How can I change this?

 

Filezilla click the tab server > Force show hidden files

Link to comment
Share on other sites

Frustrated here

 

Filezilla and Core ftp programs can not see the .htaccess file in the catalog directory.

 

I saved it from admin/file manager and changed it and can only upload it without the . Then I tried to change it to have the . and of course a file already exists, but I can't delete it.

 

I try and paste the additions to the file from admin/file manager and it does not take them.

 

How can I change this?

First of all, don't use admin/file manager to edit files, it is a security hole - delete it and paths to it as well.

Use notepad or download notepad ++ and insert the code into your .htaccess as per instructions.

Use filezila to upload the .htaccess file and you're done.

Edited by mr_absinthe

Absinthe Original Liquor Store

Link to comment
Share on other sites

OK, I can see it now. But I try to edit it and get:

Command:	RETR .htaccess
Response:	550 .htaccess: The system cannot find the file specified. 
Error:	Critical error

 

I can see it now though.

 

mr_absinthe,

I can not save the file as .htaccess as windows removes the . and then i just have htaccess and it does not work. I can not even download it from filezilla. I could only download it from file manager, but then I loos the . and i'm still not working.

Edited by Mad Duck
Link to comment
Share on other sites

Jack, have you noticed my post #4312?

Yes, I did. Just don't have the enough free time right now to look at it but I will eventually.

Edited by Jack_mcs

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

I can not save the file as .htaccess as windows removes the . and then i just have htaccess and it does not work. I can not even download it from filezilla. I could only download it from file manager, but then I loos the . and i'm still not working.

You can't run this contribution on a Windows server without speacial software. You need to ask your host if they are setup to allow .htaccess to be used.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Regarding the missing cpath in admin ref. post

 

I have no gone through all changes in install for the newest version and change the code, but still missing the cpath entry.

 

I cant even find the reference in the seo class file. As far as i can se this is the only place the entries coming from.

 

After what i can se there is a mistake in the second entry as the placeholder may fit with the cpath option in admin, but text is different. I am not sure if one entry is missing or one of thees 2 should not be there. (Add category parent to product URLs? - Add category parent to begining of URLs?)

 

I fint the correct entry in older version of Ultimate SEO URLs v2.1x like Ultimate_SEO_URLSv21d_UPDATED-23-NOV-2008 but there is only one of the entries (Add category parent to product URLs? - Add category parent to begining of URLs?)

 

What is the correct code. Bothe entries and cpath or only one + cpath.

 

               $x++;
               $this->default_config['SEO_ADD_CPATH_TO_PRODUCT_URLS'] = array('DEFAULT' => 'false',
                                                                              'QUERY' => "INSERT INTO `".TABLE_CONFIGURATION."` VALUES (NULL, 'Add category parent to product URLs?', 'SEO_ADD_CPATH_TO_PRODUCT_URLS', 'false', 'This setting will append the category parent(s) name to the product URLs (i.e. - parent-some-product-p-1.html).', GROUP_INSERT_ID, ".$x.", NOW(), NOW(), NULL, 'tep_cfg_select_option(array(''true'', ''false''),')"
                                                                             );
               $x++;
               $this->default_config['SEO_ADD_CAT_PARENT'] = array('DEFAULT' => 'false',
                                                                   'QUERY' => "INSERT INTO `".TABLE_CONFIGURATION."` VALUES (NULL, 'Add category parent to begining of URLs?', 'SEO_ADD_CAT_PARENT', 'false', 'This setting will add the category parent(s) name to the beginning of the category URLs (i.e. - parent-category-c-1.html).', GROUP_INSERT_ID, ".$x.", NOW(), NOW(), NULL, 'tep_cfg_select_option(array(''true'', ''false''),')"
                                                                   );

Link to comment
Share on other sites

You can't run this contribution on a Windows server without speacial software. You need to ask your host if they are setup to allow .htaccess to be used.

 

OK, I guess I have to back this contrib out now. Can you recommend one that will work with header tags and work on a windows server?

Link to comment
Share on other sites

OK, I guess I have to back this contrib out now. Can you recommend one that will work with header tags and work on a windows server?

You would have to check each of the other ones to see if any will work. But I wouldn't waste my time, personally. There are other changes that you may want to make at some point that won't work on a Windows server either. You should ask your host to move you to a Linux one or change hosts.

 

I just thought to add that the pre-cursor of this addon was called CName & PName, or something like that. It will work on a Windows server and is better than nothing, I suppose.

Edited by Jack_mcs

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

OK, I guess I have to back this contrib out now. Can you recommend one that will work with header tags and work on a windows server?

 

Ultimate Seo Urls 5 works with Windows servers.

 

http://www.oscommerce.com/forums/topic/336702-ultimate-seo-urls-5-by-fwr-media/

 

To not create issues with header tags you will need to add the PHP_SELF patch which is almost the last post.

Edited by FWR Media
Link to comment
Share on other sites

Hi Jack

 

I just begin to upgrade Ultimate_SEO_URLSv22d_5 from my current version (2.1) It seems the installation is simply than ever. I have uploaded files from uploading file and call the links (#1)from localhost (as I am testing in local now). The message show that "the link appear to be broken". I then read install.html again Chemo's mentioned that "Usually, the higher the version number, the more recent the version. Hoever, that is not the case with this contribution .." :'( I'm confused what to do. It's obviously that my current version (2.1) does not contain the new features from this contribution.

 

I enclose the FUNCTION I have within SEO URLs for your reference. (#2) and also my current version where I can confirm from output_html (#3)

 

Hope this information will perhaps give you some ideas what could went wrong. Can you pls let me know what I should do instead? Thank you.organicme

 

#1. After uploading files per read.html, this was 2nd steps.

http://localhost/seo.class.php

http://localhost/reset_seo_cache.php

 

#2. SEO URLs

Enable SEO URLs?	true	 
Add cPath to product URLs?	false	 
Add category parent to begining of URLs?	true	 
Filter Short Words	3	 
Output W3C valid URLs (parameter string)?	true	 
Enable SEO cache to save queries?	true	 
Enable product cache?	true	 
Enable categories cache?	true	 
Enable manufacturers cache?	true	 
Enable articles cache?	true	 
Enable topics cache?	true	 
Enable information cache?	true	 
Enable automatic redirects?	true	 
Choose URL Rewrite Type	Rewrite	 
Enter special character conversions		 
Remove all non-alphanumeric characters?	false	 
Reset SEO URLs Cache	false	 
Enable SEO URLs?

Enable the SEO URLs? This is a global setting and will turn them off completely.

 

 

 

#3 Script from html_output.php; This is where I confirm myself which version I have. Pls correct me if I am wrong.

<?php
/*
 $Id: html_output.php,v 1.56 2003/07/09 01:15:48 hpdl Exp $

 osCommerce, Open Source E-Commerce Solutions
 http://www.oscommerce.com

 Copyright (c) 2003 osCommerce

 Released under the GNU General Public License
*/

   if (SEO_ENABLED == 'true') {
   ////
// [b][u]Ultimate SEO URLs v2.1[/u][/b]
global $HTTP_SERVER_VARS;
   if($page='')
   $HTTP_SERVER_VARS['PHP_SELF'];
// The HTML href link wrapper function
 function tep_href_link($page = '', $parameters = '', $connection = 'NONSSL', $add_session_id = true, $search_engine_safe = true) {
       global $seo_urls;                
               if ( !is_object($seo_urls) ){
                       if ( !class_exists('SEO_URL') ){
                               include_once(DIR_WS_CLASSES . 'seo.class.php');
                       }
                       global $languages_id;
                       $seo_urls = new SEO_URL($languages_id);

Link to comment
Share on other sites

I just begin to upgrade Ultimate_SEO_URLSv22d_5 from my current version (2.1) It seems the installation is simply than ever. I have uploaded files from uploading file and call the links (#1)from localhost (as I am testing in local now). The message show that "the link appear to be broken". I then read install.html again Chemo's mentioned that "Usually, the higher the version number, the more recent the version. Hoever, that is not the case with this contribution .." :'( I'm confused what to do. It's obviously that my current version (2.1) does not contain the new features from this contribution.

 

Ultimate_SEO_URLSv22d_5 is the latest by me. Anyone can upload a new version though. The code you have installed isn't from my version. You need to go through each step of the installation and change what you have installed now to be sure your shop has the correct code. Also be sure your .htaccess file is setup correctly.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Hello everyone - I just installed this contrib, and I find it very useful - hopefully it works out. It was easy to install, so kudos to that!

 

I do have one question, though; something that would be of great help to my situation. I would like to get the manufacturers name in a product URL. So that the URL looks something like:

 

manufacturer-productname-productid.html

 

I see at one point in the code (the seo.class.php file) that the manufacturer ID is actually called up. What would be the best way to get this into the url?

 

Also, is it possible to remove the products ID from a URL for a "smoother" look (at least moving it out from before .html)?

 

Thanks for any/all help!

Link to comment
Share on other sites

I do have one question, though; something that would be of great help to my situation. I would like to get the manufacturers name in a product URL. So that the URL looks something like:

 

manufacturer-productname-productid.html

 

Also, is it possible to remove the products ID from a URL for a "smoother" look (at least moving it out from before .html)?

There isn't an option to add the manufacturer name to the product url link. I'll make a note to add that in the next version.

 

It isn't possible to remove the ID. There are some suggestions in this thread that may work for you. I do plan on adding that option at some point but it could be a while.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

There isn't an option to add the manufacturer name to the product url link. I'll make a note to add that in the next version.

 

It isn't possible to remove the ID. There are some suggestions in this thread that may work for you. I do plan on adding that option at some point but it could be a while.

 

Thank you for your reply - and thanks for including that in the next version. I look forward to it. :)

Link to comment
Share on other sites

Generally, everything has gone smoothly with set-up with one exception: the "buy-now" button in product listings does not work.

 

I did some research, and found that Chemo made some suggestions bank in January 2005 to resolve this. However, none of his suggestions have worked.

 

I am not caching anything on my site - never have. It has always been turned off. Under a listing of products in a category, the link for a given product seems to be the same for every product - the link includes the category names, the info that formally went in cpath, and then some things like action=buy_now and products_id after the .html part of the url. So a url looks something like this:

 

Any suggestions on resolving this? Aside from turning off the "buy now" in the product listings?

 

Thanks!

Link to comment
Share on other sites

Generally, everything has gone smoothly with set-up with one exception: the "buy-now" button in product listings does not work.

I've not seen such a problem on recent installations. All I can think to suggest is that you use the uninstall option in admin to comlpetely clear everything and then refresh your site and let it re-install. Before making any option changes, see if the Buy Now now works. If it doesn't, it seems like it would have to be a code issue in your shop or maybe server related somehow.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

I've not seen such a problem on recent installations. All I can think to suggest is that you use the uninstall option in admin to comlpetely clear everything and then refresh your site and let it re-install. Before making any option changes, see if the Buy Now now works. If it doesn't, it seems like it would have to be a code issue in your shop or maybe server related somehow.

 

Here is what the code looks like on the button:

<a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action', 'pName')) . 'action=buy_now&products_id=' . $products['products_id']) . '">

 

So, if you use the button, you get to the shopping cart, but it is reported as "Your Cart is Empty!" - some of the time, though, when then clicking on the "cart contents", the product actually is there. Other times, the product wipes the cart or isn't there.

 

I have a feeling this isn't an issue with the code around the button, but perhaps somewhere in application_top.php - what do you think?

 

Thank you!

Link to comment
Share on other sites

Here is what the code looks like on the button:

<a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action', 'pName')) . 'action=buy_now&products_id=' . $products['products_id']) . '">

 

So, if you use the button, you get to the shopping cart, but it is reported as "Your Cart is Empty!" - some of the time, though, when then clicking on the "cart contents", the product actually is there. Other times, the product wipes the cart or isn't there.

 

I have a feeling this isn't an issue with the code around the button, but perhaps somewhere in application_top.php - what do you think?

 

Thank you!

 

 

And I have figured out is has something to do with an extra & being in the URL instead of an "&" - the osCsid changes on the cart link after something is added (and probably, therefore the whole osCsid is changing).

 

I found a post about this from 2005, but the suggested fix wouldn't work in this case: the suggestion is to ammend a part of the The HTML href link wrapper function like so:

 

$link = str_replace('&amp', '&', $link);

if (isset($_sid)) {

$link .= $separator . tep_output_string($_sid);

}

 

To take out that funky extra &

 

In the new SEO, though, where could I place something like this to fix it?

 

Once again, thanks for any suggestions.

Link to comment
Share on other sites

hi all

 

i'm fairly new to Ultimate SEO URLs, and i'm wondering if its possible to do a few things and if anyone can point me in the right direction:

 

what i have:

+ a testing rig with OsCommerce (v. 2.2rc2a), pretty close to the default installation

+ Ultimate SEO URLs v22d_5

 

wat i'm wanting to do:

for a products in | Hardware | Memory | subcategory

 

rewrite the URL as www.mydomain.com.au/Memory/MyProductName.html

 

idea is, have my domain and have the first and only folder as the subcategory (or category if item is in the root of the category ) followed by the product from the 'Products Name' field

 

thanks for any help or idea

Link to comment
Share on other sites

Here is what the code looks like on the button:

<a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action', 'pName')) . 'action=buy_now&products_id=' . $products['products_id']) . '">

The problem is that the code for the button isn't standard oscommerce code. That pName in the code was used by early versions of Ultimate SEO but not any longer. You will need to restore that code, and any other code in your shop, to the original to fix the problem.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

wat i'm wanting to do:

for a products in | Hardware | Memory | subcategory

 

rewrite the URL as www.mydomain.com.au/Memory/MyProductName.html

 

idea is, have my domain and have the first and only folder as the subcategory (or category if item is in the root of the category ) followed by the product from the 'Products Name' field

That was actually how the code was first setup but then those using said they wanted the full path showing all categories. I'll change that in the next version to include all categories or just the immediate category.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

The problem is that the code for the button isn't standard oscommerce code. That pName in the code was used by early versions of Ultimate SEO but not any longer. You will need to restore that code, and any other code in your shop, to the original to fix the problem.

 

Sure, I understand, but the button code wasn't working before I tried the older code from researching someone who had a similar problem.

 

So restoring the few lines isn't going to change anything (other than bring me back to updated code, but on square one).

 

Thanks - any other suggestions for where I can find that & thing?

Link to comment
Share on other sites

That was actually how the code was first setup but then those using said they wanted the full path showing all categories. I'll change that in the next version to include all categories or just the immediate category.

 

thanks for replying Jack_mcs,

 

just wondering if that included the ability to place the category and/or subcategory as a folder (and with the *.html appended after that)

 

i'm actually doing this for the guys i'm working for.... their wanting it done soon.

is there a previous version u could point me to so i could try to get it to happen, hehehe until the new version is released that is :)

 

thanks for any info

 

SacH

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
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
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...