Jump to content

Latest products


Guest

Recommended Posts

I have found that when you seperate the words with a space it helps a lot.

ex. dvdworld/dvdworld and dvdworld / dvdworld

There was a post about this a while ago, try the search and change the date to over 60 days.

I will also try and find it for you. ;)

Link to comment
Share on other sites

I used a display limit on the text on latest products on cubecart 2. It was something like show 15-20 characters.

Edit

Here is the old code

CODE

// start loop of results

while($row = mysql_fetch_array($new_prod_result)){

$title=$row["title"];

$product=$row["product"];

$description= $row["description"];

After, Add

CODE

$description=stripslashes($description);

$description=substr($description,0,75);

Can i do this on V3?

Link to comment
Share on other sites

Guest estelle

Or you can just set the height so it is large enough for all images and all titles to fit.

E.g. in skins/Killer/styleTemplates/content/index.tpl:

<!-- BEGIN: repeat_prods -->

<div style="float: left; text-align: center; width: {VAL_WIDTH}px; height: 150px;">

The actual value for the height will depend on your site. Just try different values until you find what works.

Link to comment
Share on other sites

Guest estelle

Sorry that i didn't really answer your question the first time round. That code will not work in v3, but here's the change to make.

Edit includes/content/index.tpl. Find this line:

$index->assign("VAL_PRODUCT_NAME",$latestProducts[$i]['name']);


*Replace* it with these lines (change the 75 to however many characters you want):


$name = substr($latestProducts[$i]['name'],0,75);

$index->assign("VAL_PRODUCT_NAME",$name);

Done! :sourcerer:

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
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...