X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Dev Questions (https://forum.x-cart.com/forumdisplay.php?f=20)
-   -   Static page simulation. Search engine improvements (https://forum.x-cart.com/showthread.php?t=10128)

jimskodi 01-06-2005 08:45 AM

What about the way lite commerce handles this
 
In lite commerce you have a product showcase Organizer - free add on where you can tell what 3 styles to show to the public.

list, table or icon.

table - would be the way to go.

If you change it to table it gives you the title - price and buy it now.

so if you switch to this table and create a catalog with it and then switch back to the icon option you then have static pages which are just words and they can order. How do we get this on x-cart gold? is it possible?

http://www.litecommerce.com/addon.html?addon=showcase

and what if we gave the customer the option to switch between all 3 choices.. it would make browsing your website a littel more fun, convienent, like they are in control of the shopping experience.

B00MER 01-18-2005 12:07 PM

Nice modification :D

I tweaked it some. Added a different link on the image to help with SEO, along with adding the usual html/body junk. H3 used on product titles, style sheet of xcart used in case someone does click through. I also changed the sql query to return the latest added products to keep events current with search engine findings. I also corrected a bug if a product title had a /w to shorten with, the cart would break. :idea:

skin1/SEO_listing.html:
Code:

{ config_load file="$skin_config" }
<html>
<head>
<title>{$lng.txt_site_title} {$lng.txt_subtitle_home}</title>
{ include file="meta.tpl" }
<link rel="stylesheet" href="{$SkinDir}/{#CSSFile#}">
</head>
<body LEFTMARGIN=0 TOPMARGIN=0 RIGHTMARGIN=0 BOTTOMMARGIN=0 MARGINWIDTH=0 MARGINHEIGHT=0>

{* Smarty Template SEO_listing.tpl  by Fernando Borcel. MascotasMexico.com 2004/10/31 *}
{foreach from=$products item=v key=k}



<h3>{$products[$k].product}</h3>
{if $products[$k].descr}{$products[$k].descr}{else}{$products[$k].fulldescr}{/if}
 
[img]{if $full_url}{$http_location}{else}{$xcart_web_dir}{/if}/image.php?productid={$products[$k].productid}[/img]
 
<hr size=1>
</p>
{/foreach}

</body>
</html>


customer/listing.php:
Code:

<?php

/* Search Engine Enhancement by Fernando Borcel. MascotasMexico.com */

require "./auth.php";

$qry = "SELECT * FROM " . $sql_tbl["products"] . " where forsale='Y' order by add_date DESC";
$result = db_query($qry);

$products = array();

while ($result_row = db_fetch_array($result)) {
  $products[] = $result_row;
}


$smarty->assign("products",$products);
$smarty->display("SEO_listing.tpl", $smarty);

?>


.htaccess file:
Code:

RewriteEngine on
Options +FollowSymlinks
RewriteBase /
RewriteRule ^(.*)-pid-([0-9]+)\.html$ /customer/product.php?productid=$2
RewriteRule ^(.*)listing.html$ /customer/listing.php


Keep in mind this store was running off the main public_html/ directory, and not a sub directory like xcart/

so my links is example.com/customer/listing.html

Kudos! 8)

GM 01-18-2005 12:52 PM

You still da' BOSS BOOMER! By the way, hows Baby BOOMER coming along? :D

PDI 01-28-2005 12:29 PM

Boomer,

I tried your mod, but it doesn't seem to be working.

When I go to www.mysite.com/customer/listing.html, I get the following error:
Quote:

Warning: main(./auth.php): failed to open stream: No such file or directory in /home/mysite/public_html/customer/listing.php on line 5

Warning: main(./auth.php): failed to open stream: No such file or directory in /home/mysite/public_html/customer/listing.php on line 5

Fatal error: main(): Failed opening required './auth.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/mysite/public_html/customer/listing.php on line 5
My x-cart is also installed in the root public_html directory, so it should work the same for me as it does for you.
Also, the original mod in this thread said to create "SEO_listing.tpl" but your mod says "SEO_listing.html." Was this an oversight/typo on your part, or should it really by .html?
Any ideas?
Thanks!

GM 01-28-2005 08:20 PM

Hi PDI, it's supposed to be .tpl and it goes in skin1/customer/ not in www/customer also, are you on a shared server? Because sometimes with a shared server (and only with certain scripts) you have to set up "full paths" ie. home/yourdomain/www/ . I know, because I've had to do this with some scripts.

nfc5382 01-29-2005 09:49 AM

excellent, thanks!

abbieroad 02-02-2005 05:55 PM

Quote:

Originally Posted by fernando
Good point. I'll update the mod so that it'll include all categories. I just finished a new mod so that customers will be able to see all the first-level sub-categories within the main category they're browsing. I'll post it here over the next few days ;) You can check it out @ my site.

Cheers,


Hey Fernando...did you ever post this mod for the sub-categories? If not, it would be great if you could do so...

Thanks!

mrbiggles 02-06-2005 07:06 PM

Hello
Thanks for the above mod, I finally worked out how to do it last night. Once I had it completed I tried the following link as suggested by someone else.

http://validator.w3.org/check?uri=http://www.creydall.com/coby/mycatalog.html

and recieved 977 errors which means it is not 4.01 compliant.
Is this a major problem? and will I still get search engines sniffing around and picking up the page.
Is there somewhere that will make it complient like a shareware filter that will adjust the format.
Regards Adam

GM 02-06-2005 07:33 PM

google, msn and yahoo will all index it.

mrbiggles 02-06-2005 07:36 PM

One less thing to worry about
thanks for the reply.
Regards Adam


All times are GMT -8. The time now is 08:24 AM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.