Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

NIMMIT SEF Support thread


Guest

Recommended Posts

I dont know if this has been brought up, but with this mod, a particular product can end up having several different unique pages that point to it, essential looking like multiple copies of a page to search engine spider - a big SEF no-no.

 

Has this been fixed? Regardless, good job.

 

I personally made my own SEF mod last February through April that is very similar to this Nimmit one as the only other ones available at the time required the catalog be located in the root. Mine though is very extensive and requires changes throughout many many files. Being a novice with PHP I didn't try to make it simple lol..

 

Anyway here is a sample of a site with my work: http://www.maxlang.com/cufflinksandstuds.com/

 

There have actually been numerous fixes since the version in the above site that have have not yet been implemented (the above site is not live). Also that site is based on the CRE Loaded version of OSC...

 

As for making this mod public, that is debatable as it is a pretty cumbersome mod and I don't really want to support it lol..

 

-John M

Link to comment
Share on other sites

  • 2 weeks later...
  • Replies 85
  • Created
  • Last Reply

Top Posters In This Topic

I think the fact that you have a / in the name of your product could be throwing things off. I'm not sure how that affects the problem at hand...but I think it will cause you problems down the road.

Chris Dunning

osCommerce, Contributions Moderator Team

 

Please do not send me PM! I do not read or answer these often. Use the email button instead!

 

I do NOT support contributions other than my own. Emails asking for support on other people's contributions will be ignored. Ask in the forum or contact the contribution author directly.

Link to comment
Share on other sites

ok, first part sorted.

if i change

function callback($pagecontent) {
?$pagecontent = preg_replace_callback("/(<[Aa][ \r\n\t]{1}[^>]*href[^=]*=[ '\"\n\r\t]*)([^ \"'>\r\n\t#]+)([^>]*>)/",'wrap_href',$pagecontent);
?return $pagecontent;

to

function callback($pagecontent) {
?$pagecontent = preg_replace_callback("/mydirectory(<[Aa][ \r\n\t]{1}[^>]*href[^=]*=[ '\"\n\r\t]*)([^ \"'>\r\n\t#]+)([^>]*>)/",'wrap_href',$pagecontent);
?return $pagecontent;

 

it works with no errors, but i cant add

 

# -----> NIMMIT:SEF:B

RewriteEngine on

RewriteBase /

 

#-----> single file no vars

RewriteRule ^([^/]*)\.html$ $1.php?%{QUERY_STRING} [NC]

 

#-----> one var

RewriteRule ^/?(product)/([^/]*)\.html$ product_info.php?products_id=$2&%{QUERY_STRING} [NC]

RewriteRule ^/?(category)/([^/]*)\.html$ index.php?cPath=$2&%{QUERY_STRING} [NC]

RewriteRule ^/?(brand)/([^/]*)\.html$ index.php?manufacturers_id=$2&%{QUERY_STRING} [NC]

 

#-----> two vars

RewriteRule ^/?(category)/(.*)/(product)/([^/]*)\.html$ product_info.php?cPath=$2&products_id=$4&%{QUERY_STRING} [NC]

RewriteRule ^/?(brand)/(.*)/(product)/([^/]*)\.html$ product_info.php?manufacturers_id=$2&products_id=$4&%{QUERY_STRING} [NC]

#-----> Reviews

RewriteRule ^/?(product_reviews_write|product_reviews|product_reviews_info)/product/([^/]*)\.html$ $1.php?products_id=$2&%{QUERY_STRING} [NC]

RewriteRule ^/?(product_reviews_write|product_reviews|product_reviews_info)/category/(.*)/product/([^/]*)\.html$ $1.php?cPath=$2&products_id=$3&%{QUERY_STRING} [NC]

RewriteRule ^/?(product_reviews_write|product_reviews|product_reviews_info)/brand/(.*)/product/([^/]*)\.html$ $1.php?manufacturers_id=$2&products_id=$3&%{QUERY_STRING} [NC]

#-----> products new

RewriteRule ^/?(products_new)/product/([^/]*)\.html$ $1.php?products_id=$2&%{QUERY_STRING} [NC]

# -----> NIMMIT:SEF:E

 

 to my .htaccess file then i get forbidden :-(

 

john

anybody got a fix for it ???

 

Regards John

Link to comment
Share on other sites

  • 2 weeks later...

#-----> products new

RewriteRule ^/?(products_new)/product/([^/]*)\.html$ $1.php?products_id=$2&%{QUERY_STRING} [NC]

 

^ This is the only problem I have using this contrib.

 

My urls show up as:

 

http://mywebsite.comproducts_new/product/....?action=buy_now

 

Notice the lack of a slash between the domain name and products_new. Plus, the 'product' is simply that. So if I add a slash, it returns to the cart, but without a product added.

 

Im not sure how to code for rewrites so any help would be apprciated. Can anybody post an htaccess file that works completely?

 

Thanks!

Link to comment
Share on other sites

  • 2 weeks later...

Yo-

 

I created a new copy of application_top.php and commented out the calls to the NIMMIT SEF. It works, although without URL rewrites. Maybe this will help others using this with other contribs like RMA, which I found out also doesnt seem to work good with this contrib. You lose some, you win some, you know...

Link to comment
Share on other sites

Hi ,

NIMMIT

 

Currently I am using your contribute with OsCommerceMs2 and it's working perfectly. But I am facing a small problem. Whenever I click any product in home page (index.html) it redirects me to "[productname].html" page, everything is fine but this page is unable to include style sheet. So look and feel is different from others, where as other pages like "login.html", "myaccount.html" are working perfectly. Can you or anybody tell me what I have to do to slove this problem?

Link to comment
Share on other sites

Hi

 

When I click "view more" link in "review box" at left site in home page it redirects users to "//reviews.html" page . If you notice, there is an extra front slash "/" is added before "reviews.html". So webserver is unable to locate that page and showing "404 error". I think it's a small bug. Have I to edit in .htaccess file?

Link to comment
Share on other sites

  • 2 weeks later...
I am able to solve those problems. I have to make a small change in "url_rewrite.php" file.

 

Your contribution is great.

Did you solve the Reviews Page problem with the double slash appearing.

 

Can you also post your website.

Link to comment
Share on other sites

  • 2 weeks later...

Hello all,

i think this problem is related to this contribution, if not I appoligize!

 

On my Advanced_search and all_products pages the buy now buttons do not work...

http://www.time4neon.comall_products/produ...?action=buy_now

see how it adds all_products? it also does similar on advanced search

http://www.time4neon.comadvanced_search_re...?action=buy_now

 

any ideas?

thanks

Link to comment
Share on other sites

Do not use this Contribution

 

It corrupts the Advance Search and also it corrupts the Reviews.

 

Both of the above does not work if you use this contirbution.

 

Instead use the Original Contribution named SEF transformer.

Sorry but in my shop it doesen't works.

 

Thers a linklike http://www.oberhexe.com/product_info.php/c...products_id/188

 

and no http://www.oberhexe.com/productname.html

 

And this is very important for google

 

Can you help me to generate a linklist of my products like productname.html ?

Link to comment
Share on other sites

RE: Farrukh

The whole point of an open source community project is that everyone helps contribute to the final result, by mealy saying...

Do not use this Contribution

 

It corrupts the Advance Search and also it corrupts the Reviews.

 

Both of the above does not work if you use this contribution.

 

Instead use the Original Contribution named SEF transformer.

 

Seems to me like your being lazy ! If you have an interest (which you obviously do judging by the number your posts in this thread). Do something about it !!

 

Like so many other contributions, this will do what the original writer intended it to. Because I don't have any use for reviews (and was unaware that it has an advanced search problem (I will look into this)) there is very little point in me writing something that i will not use.

 

You're still using the contribution and I see that you have helped with other contribs?, why not sort this one out rather than belittling it?

 

Love

 

Nimmit

Link to comment
Share on other sites

  • 2 weeks later...

hello guys i just installed this contribution on my site , all the links are changed but they are 404 . example link is here

http://www.mghatworld.com/category/Wristbands.html

 

so to make sure i installed fresh osc ms2 store and then installed this contribution on it , i dont see no effect at all , every thing is the same , Can any one please help me figure this out

 

link to new store http://www.mghatworld.com/catalog

 

 

 

thankyou

Edited by sinryder
Link to comment
Share on other sites

hello guys i just installed this contribution on my site , all the links are changed but they are 404 . example link is here

http://www.mghatworld.com/category/Wristbands.html

 

so to make sure i  installed fresh osc ms2 store and  then installed this contribution on it , i dont see no effect at all , every thing is the same  , Can any one please help me figure this out

 

link to new store http://www.mghatworld.com/catalog

thankyou

 

This contribution will only work if your catalog is installed in the root, not catalog/ etc

Link to comment
Share on other sites

hey sam , thankyou for replying , i reinstalled the osc in root directly

 

here is the link to it http://mghatworld.com/

 

and its still not working. No difference at all

this is what i did

 

in root folder , copied these 2 files

 

/public_html/url_rewrite.php

/public_html/.htaccess

 

then in

includes folder

 

copied this

/public_html/includes/nimmit_sef.php

 

a little code from my application_top.php

 

// start the timer for the page parse time log

  define('PAGE_PARSE_START_TIME', microtime());

 

#-----> NIMMIT:SEF:B

require('url_rewrite.php');

#-----> NIMMIT:SEF:E

 

// set the level of error reporting

  error_reporting(E_ALL & ~E_NOTICE);

 

And This

 

// if gzip_compression is enabled, start to buffer the output

  if ( (GZIP_COMPRESSION == 'true') && ($ext_zlib_loaded = extension_loaded('zlib')) && (PHP_VERSION >= '4') ) {

    if (($ini_zlib_output_compression = (int)ini_get('zlib.output_compression')) < 1) {

      if (PHP_VERSION >= '4.0.4') {

        ob_start('ob_gzhandler');

      } else {

        include(DIR_WS_FUNCTIONS . 'gzip_compression.php');

        ob_start();

        ob_implicit_flush();

      }

    } else {

      ini_set('zlib.output_compression_level', GZIP_LEVEL);

    }

  }

 

#-----> NIMMIT:SEF:B

require(DIR_WS_INCLUDES . 'nimmit_sef.php');

#-----> NIMMIT:SEF:E

 

// set the HTTP GET parameters manually if search_engine_friendly_urls is enabled

  if (SEARCH_ENGINE_FRIENDLY_URLS == 'true') {

    if (strlen(getenv('PATH_INFO')) > 1) {

      $GET_array = array();

      $PHP_SELF = str_replace(getenv('PATH_INFO'), '', $PHP_SELF);

      $vars = explode('/', substr(getenv('PATH_INFO'), 1));

      for ($i=0, $n=sizeof($vars); $i<$n; $i++) {

        if (strpos($vars[$i], '[]')) {

          $GET_array[substr($vars[$i], 0, -2)][] = $vars[$i+1];

        } else {

          $HTTP_GET_VARS[$vars[$i]] = $vars[$i+1];

        }

        $i++;

      }

 

      if (sizeof($GET_array) > 0) {

        while (list($key, $value) = each($GET_array)) {

          $HTTP_GET_VARS[$key] = $value;

        }

      }

    }

  }

 

 

i guess i did everything ok and still no effect :(

Link to comment
Share on other sites

hello every one Contribution is working Great Thankyou NIMMIT ,

is it possible to change _ in links to -

a friend told me that The search algo's treat the underscore as a character, not a space. So all the keywordrich filenames are absolutely no good, even if they did help, as they are all being read as one nonsense word.

 

any help is greatly appreciated

 

thankyou

Edited by sinryder
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...