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

Linking pages from product pages

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 03-27-2009, 06:25 PM
 
Tim CDN Tim CDN is offline
 

Advanced Member
  
Join Date: Mar 2009
Posts: 48
 

Default Linking pages from product pages

Hi all

When you are editing the product description and are using html to design it, is there an alternative to link to another page other than a static link?

This is what I am using
<a href="http://www.testsite.com/xcart/testpage.html">

I would like to use a dynamic link like:
<a href="testpage.html">
Because when I change my cart the the root directory all the links I have made will have to be redone.

Is that possible? What code do I have to use to enable these links?

Or should I keep the static link for SEO purposes?

Wow - So much to learn!
__________________
Gold 4.2.0
CDSEOPRO v.1.3.1
Advanced MiniCart
ezUpsell
One Page Checkout
Drug Test Kits
Reply With Quote
  #2  
Old 03-28-2009, 06:15 AM
  JWait's Avatar 
JWait JWait is offline
 

X-Man
  
Join Date: Nov 2005
Location: California
Posts: 2,440
 

Default Re: Linking pages from product pages

I don't understand why you would create a product page in html, x-cart creates product pages dynamically using templates.
__________________
Two Separate X-Cart Stores
Version 4.4.4 Gold - X-AOM - Vivid Dreams Aquamarine (modified) - Linux
Mods - Newest Products - View All -, and a few others. Numerous upgrades from 4.0.x series.
Integrated with Stone Edge Order Manager + POS

Version 4.1.12 Gold (fresh install) - X-AOM - Linux
Mods - XCSEO free
Reply With Quote
  #3  
Old 03-28-2009, 06:36 AM
 
Tim CDN Tim CDN is offline
 

Advanced Member
  
Join Date: Mar 2009
Posts: 48
 

Default Re: Linking pages from product pages

I am using html to design the layout of the product description - not the actual product page. Sorry, I wasn't very clear about that.

I want to link to static pages without having to input a static link.
__________________
Gold 4.2.0
CDSEOPRO v.1.3.1
Advanced MiniCart
ezUpsell
One Page Checkout
Drug Test Kits
Reply With Quote
  #4  
Old 03-28-2009, 10:55 AM
  gb2world's Avatar 
gb2world gb2world is offline
 

X-Wizard
  
Join Date: May 2006
Location: Austin, TX
Posts: 1,970
 

Default Re: Linking pages from product pages

I also am not clear on what you are trying to do and why
<a href="testpage.html">
would not work if testpage is a static page or rewritten URL created within xcart.

I don't use 4.2, but on 4.1.x, you can use a smarty variable that indicates your cart location:
<a href="{$current_location}/testpage.html">
This works in XCART - so if you are making html pages outside xcart, there is more involved in using the smarty variables.
__________________
X-CART (4.1.9,12/4.2.2-3/4.3.1-2/4.4.1-5)-Gold
(CDSEO, Altered-Cart On Sale, BCSE Preorder Backorder, QuickOrder, X-Payments, BCSE DPM Module)
Reply With Quote
  #5  
Old 03-28-2009, 02:44 PM
 
Tim CDN Tim CDN is offline
 

Advanced Member
  
Join Date: Mar 2009
Posts: 48
 

Default Re: Linking pages from product pages

Two issues
#1
What I am trying to do is link a to a page from either text or an image.

To link a page I am trying to use:
<a href="testpage.html">
this works with static pages - I think I have sorted this prob out.

#2

When I try to show an image into the product description I would like to use smarty but I am having problems

If I use:
<img src="{$ImagesDir}/test.gif" alt="" />

in the HTML of the product description it won't pull the image.

But if I use this:

<img src="http://www.testsite/images/test.gif" alt="" />

It works

Thanks for the help
__________________
Gold 4.2.0
CDSEOPRO v.1.3.1
Advanced MiniCart
ezUpsell
One Page Checkout
Drug Test Kits
Reply With Quote
  #6  
Old 03-29-2009, 04:28 AM
  JWait's Avatar 
JWait JWait is offline
 

X-Man
  
Join Date: Nov 2005
Location: California
Posts: 2,440
 

Default Re: Linking pages from product pages

In admin - general settings is the field "Parse Smarty tags in the content of embedded static pages" checked?
__________________
Two Separate X-Cart Stores
Version 4.4.4 Gold - X-AOM - Vivid Dreams Aquamarine (modified) - Linux
Mods - Newest Products - View All -, and a few others. Numerous upgrades from 4.0.x series.
Integrated with Stone Edge Order Manager + POS

Version 4.1.12 Gold (fresh install) - X-AOM - Linux
Mods - XCSEO free
Reply With Quote
  #7  
Old 03-29-2009, 04:55 AM
 
carpeperdiem carpeperdiem is offline
 

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

Default Re: Linking pages from product pages

Quote:
Originally Posted by Tim CDN
If I use:
<img src="{$ImagesDir}/test.gif" alt="" />

in the HTML of the product description it won't pull the image.

But if I use this:

<img src="http://www.testsite/images/test.gif" alt="" />

It works

Your images must live in /skin1/images

/skin1/images = {$ImagesDir}

DO NOT use /images unless you want to break your site when it goes https.
__________________
xcart 4.5.4 gold+ w/x-payments 1.0.6; xcart gold 4.4.4
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 05:15 PM.

   

 
X-Cart forums © 2001-2020