Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

How To Put Link On Each Product Page To Size Chart Page

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 12-26-2007, 02:32 PM
 
lera4285 lera4285 is offline
 

Advanced Member
  
Join Date: Nov 2007
Posts: 43
 

Default How To Put Link On Each Product Page To Size Chart Page

Hi,

I am constructing a clothing site and would like to have a link to our "Size Chart" .html page on each clothing Product Page.

I would like for the link to be in the same location on each clothing Product Page.

We will have merchandise other than clothing on other product pages and do not want the "Size Chart" link to appear on those pages.

I have no clue as how to accomplish this and would really appreciate any suggestions.

Thank You
__________________
Learning is a beautiful yellow brick road that never ends.
4.1.9 Unix Windows XP
Florida
www.sexcitinglingerie.com
Reply With Quote
  #2  
Old 12-26-2007, 07:51 PM
 
carpeperdiem carpeperdiem is offline
 

X-Guru
  
Join Date: Jul 2006
Location: New York City, USA
Posts: 5,399
 

Default Re: How To Put Link On Each Product Page To Size Chart Page

This is relatively simple, but a bit tricky until you get your head around what's going on. I would rate this solution as a difficulty level "4" on a scale of 1-10

The idea is to use Extra Fields to tell xcart that there is a size chart -- but only if the product has a size chart. The size chart will be the same for all products, yes?

1. Enable extra fields
2. In extra fields module options, make sure "Display default values in all extra fields for which non-default values have not been defined:" is UNCHECKED
3. Go to Extra Fields. Define an extra field. Call it, "size_chart"
4. Open file: skin1/modules/Extra_Fields/product.tpl

FIND:
Code:
{section name=field loop=$extra_fields} {if $extra_fields[field].active eq "Y" && $extra_fields[field].field_value} <tr> <td width="30%">{$extra_fields[field].field}</td> <td>{$extra_fields[field].field_value}</td> </tr> {/if} {/section}

REPLACE WITH:
Code:
{section name=field loop=$extra_fields} {* mod to only show the size chart if the product has one *} {if $extra_fields[field].field eq "size_chart"} {if $extra_fields[field].field_value ne ""} <tr> {* if you want to be tricky -- use a javascript popup here *} <td><a href="/path-to/size_chart.html" >Size Chart? Click Here!</a></td> </tr> {/if} {else} {* END mod to only show the size chart if the product has one *} {if $extra_fields[field].active eq "Y" && $extra_fields[field].field_value} <tr> <td width="30%">{$extra_fields[field].field}</td> <td>{$extra_fields[field].field_value}</td> </tr> {/if} {/if} {* added for the size chart mod *} {/section}

Now, do a bulk edit of your products -- if it wants to display a size chart, put a Y in the size chart field. Otherwise, leave empty.

Adjust the path to the html link in the code you just replaced...

That's all there is to it.

Not for a true beginner, but if you have any smarty experience, this is a good and relatively easy way to accomplish your goal...

For extra credit, instead of using a html link, use Thickbox or any cool image or iFrame popup, and integrate your size chart using a cool js popup of some kind.

BUT -- the code to tell xcart if the product has a size chart or not is still the same...

I hope this helps.

Jeremy
__________________
xcart 4.5.4 gold+ w/x-payments 1.0.6; xcart gold 4.4.4
Reply With Quote
  #3  
Old 12-27-2007, 06:24 AM
 
lera4285 lera4285 is offline
 

Advanced Member
  
Join Date: Nov 2007
Posts: 43
 

Default Re: How To Put Link On Each Product Page To Size Chart Page

Thanks Carpeperdiem,

I have studied your reply and am sure that I can implement your instructions.

I am unclear about how to preform the "bulk edit."

Thank You
__________________
Learning is a beautiful yellow brick road that never ends.
4.1.9 Unix Windows XP
Florida
www.sexcitinglingerie.com
Reply With Quote
  #4  
Old 12-27-2007, 11:23 AM
 
lera4285 lera4285 is offline
 

Advanced Member
  
Join Date: Nov 2007
Posts: 43
 

Default Re: How To Put Link On Each Product Page To Size Chart Page

Carpeperdiem,

I have it working now (thanks to your instructions). I had to make a small change to the following code from ("/path-to/size_chart.html") to the actual URL of the size_chart (a href="http://www.websiteurl.com/pages.php?pageid=2)

<td><a href="/path-to/size_chart.html" >Size Chart? Click Here!</a></td>

I'm still unclear with bulk edit.

Thank you very much.
__________________
Learning is a beautiful yellow brick road that never ends.
4.1.9 Unix Windows XP
Florida
www.sexcitinglingerie.com
Reply With Quote
  #5  
Old 12-27-2007, 11:41 AM
 
carpeperdiem carpeperdiem is offline
 

X-Guru
  
Join Date: Jul 2006
Location: New York City, USA
Posts: 5,399
 

Default Re: How To Put Link On Each Product Page To Size Chart Page

bulk editing of products is well documented.
---------------------------------------------------

Modifying products You can modify previously created products, which means you can edit any of their details.
To modify a product:
1.Find the product that you wish to modify.
2.Open the product for modification. Do one of the following:
[FONT='Arial Unicode MS','Lucida Sans Unicode','Arial']▪[/font]In the 'Search results' dialog box, select the check box next to the product name, then click the Modify selected button.
or
[FONT='Arial Unicode MS','Lucida Sans Unicode','Arial']▪[/font]In the 'Search results' dialog box, click the product name link.
This should open a page with the details of the selected product.
3.Change all the necessary product details.
4.Click the Save button to save the changes. The details of the product will be updated.
5.If necessary, add, edit or delete international descriptions and other additional features for the product.
Group product editing (mass product editing)
If you need to make similar changes to more than one products, you might want to edit these products as a group.
To modify several products simultaneously (using X-Cart's group product editing feature):
1.Find the products that you wish to modify.
2.In the 'Search results' dialog box, select the products that need to be modified (select the check boxes next to the product names).
Note: You can use the Check all link to select all the products on the page.
3.Click the Modify selected button.
This should open a page with a list of products selected for modification:
http://www.x-cart.com/xcart_manual/online/group_ed1.gif
and a 'Product details' dialog box displaying the details of a product whose name is written in bold font in the list of products selected for modification:
http://www.x-cart.com/xcart_manual/online/group_ed2.gif
Now you can view the details of any of the products from the 'Product list': all you need to do is click on the name of the product whose details you wish to view, and the details will be displayed in the 'Product details' dialog box below.
4.From the 'Product list', select a product whose details you wish to use as a model for all the products in the list. The details of this product will be opened for viewing and modification in the 'Product details' dialog box.
5.In the 'Product details' dialog box, change all the product details that need to be changed for the currently selected product. You can make any changes, no matter whether they need to be applied only to this very product or to all of the products selected for modification.
6.You might have noticed that the 'Product details' dialog box looks a bit different when used in group product editing mode: all the fields of this dialog box have check boxes located to the left of their names. These check boxes allow you to assign the product details of the product you are viewing to the rest of the products selected for modification. Select the check boxes next to the fields which need to be applied to all of the products in the 'Product list'.
7.Click the Save button at the bottom of the 'Product details' dialog box to save the changes. The product details you have changed should be updated (The ones with selected check boxes should be applied to all of the products in the 'Product list', the ones whose check boxes were left unselected - just to the product whose details are displayed in the 'Product details' dialog box).
8.(Optional) Now, if you need to make further changes to any more products from the 'Product list', select one of these products so its details are displayed in the 'Product details' dialog box and continue editing as described above.
9.(Optional) Add, edit or delete international descriptions and other additional features for one of the products and apply the changes to all the products being edited.
__________________
xcart 4.5.4 gold+ w/x-payments 1.0.6; xcart gold 4.4.4
Reply With Quote
  #6  
Old 12-27-2007, 12:17 PM
 
lera4285 lera4285 is offline
 

Advanced Member
  
Join Date: Nov 2007
Posts: 43
 

Default Re: How To Put Link On Each Product Page To Size Chart Page

Yes I did this. I guess the name "Bulk Editing" confused me a little.

Thank you very much for your patience and information.
__________________
Learning is a beautiful yellow brick road that never ends.
4.1.9 Unix Windows XP
Florida
www.sexcitinglingerie.com
Reply With Quote
  #7  
Old 02-05-2008, 10:51 PM
  divinechic's Avatar 
divinechic divinechic is offline
 

Advanced Member
  
Join Date: Dec 2007
Posts: 78
 

Default Re: How To Put Link On Each Product Page To Size Chart Page

Could you explain how to make a popup using javascript? I am not good at this. I got your mod to work, thank you so much but I would like to have the page pop up and be smaller that a regular page.

Quote:
Originally Posted by carpeperdiem
This is relatively simple, but a bit tricky until you get your head around what's going on. I would rate this solution as a difficulty level "4" on a scale of 1-10

The idea is to use Extra Fields to tell xcart that there is a size chart -- but only if the product has a size chart. The size chart will be the same for all products, yes?

1. Enable extra fields
2. In extra fields module options, make sure "Display default values in all extra fields for which non-default values have not been defined:" is UNCHECKED
3. Go to Extra Fields. Define an extra field. Call it, "size_chart"
4. Open file: skin1/modules/Extra_Fields/product.tpl

FIND:
Code:
{section name=field loop=$extra_fields} {if $extra_fields[field].active eq "Y" && $extra_fields[field].field_value} <tr> <td width="30%">{$extra_fields[field].field}</td> <td>{$extra_fields[field].field_value}</td> </tr> {/if} {/section}

REPLACE WITH:
Code:
{section name=field loop=$extra_fields} {* mod to only show the size chart if the product has one *} {if $extra_fields[field].field eq "size_chart"} {if $extra_fields[field].field_value ne ""} <tr> {* if you want to be tricky -- use a javascript popup here *} <td><a href="/path-to/size_chart.html" >Size Chart? Click Here!</a></td> </tr> {/if} {else} {* END mod to only show the size chart if the product has one *} {if $extra_fields[field].active eq "Y" && $extra_fields[field].field_value} <tr> <td width="30%">{$extra_fields[field].field}</td> <td>{$extra_fields[field].field_value}</td> </tr> {/if} {/if} {* added for the size chart mod *} {/section}

Now, do a bulk edit of your products -- if it wants to display a size chart, put a Y in the size chart field. Otherwise, leave empty.

Adjust the path to the html link in the code you just replaced...

That's all there is to it.

Not for a true beginner, but if you have any smarty experience, this is a good and relatively easy way to accomplish your goal...

For extra credit, instead of using a html link, use Thickbox or any cool image or iFrame popup, and integrate your size chart using a cool js popup of some kind.

BUT -- the code to tell xcart if the product has a size chart or not is still the same...

I hope this helps.

Jeremy
__________________
X-Cart Gold version 4.1.9
Reply With Quote
  #8  
Old 05-25-2008, 10:06 PM
  Jeff San's Avatar 
Jeff San Jeff San is offline
 

Newbie
  
Join Date: Mar 2008
Posts: 4
 

Default Re: How To Put Link On Each Product Page To Size Chart Page

I really want to have my size chart popup in thickbox how can i do this i already have my images doing it on the product details page but cant figure it out for linking to my size chart thankz in advance for your help.
__________________
X-Cart version - 4.1.9
PHP - 4.4.8
MySQL server - 4.0.27
MySQL client - 5.0.32
Web server - Apache/1.3.34 Ben-SSL/1.55
Perl - 5.008008
Operation system - Linux
Reply With Quote
  #9  
Old 05-26-2008, 09:28 PM
 
merbay merbay is offline
 

Advanced Member
  
Join Date: Mar 2008
Posts: 42
 

Default Re: How To Put Link On Each Product Page To Size Chart Page

Thanks Carpeperdiem,

I am a newbie and had no trouble with this following your instructions! It works perfectly!

One change I would like to make. The text is now between "quantity in stock" and "price" and gets lost. How can I move this up before Details, orto the very end after size, etc. ?

Thanks in advance.
__________________
merbay
4.1.9
Reply With Quote
  #10  
Old 05-28-2008, 10:58 AM
 
merbay merbay is offline
 

Advanced Member
  
Join Date: Mar 2008
Posts: 42
 

Default Re: How To Put Link On Each Product Page To Size Chart Page

Anyone? I thought that this would be easy, but I keep messing up the table-- Help!

I would really like to just put this link into the description, but am willing to be flexible; just want to make the link easy to see! Thanks
__________________
merbay
4.1.9
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 01:04 PM.

   

 
X-Cart forums © 2001-2020