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

Static Page Include Problem

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 08-28-2009, 06:49 PM
 
sharingsunshine sharingsunshine is offline
 

Senior Member
  
Join Date: Aug 2005
Location: Palmyra, VA
Posts: 149
 

Default Static Page Include Problem

Hello,

I have embedded static pages I want to include a .tpl file in. I am doing this thru the pages.tpl file. Here is my code in the pages.tpl file:

Code:
{* $Id: pages.tpl,v 1.3.2.1 2005/01/19 06:42:51 max Exp $ *} {capture name=dialog} {if $smarty.get.pageid eq "1" or $smarty.get.pageid eq "2" or $smarty.get.pageid eq "3" or $smarty.get.pageid eq "4" or $smarty.get.pageid eq "5" or $smarty.get.pageid eq "6" or $smarty.get.pageid eq "7" or $smarty.get.pageid eq "8" or $smarty.get.pageid eq "9" or $smarty.get.pageid eq "12"} {include file="rjw/welcome_ship.tpl"} {elseif $smarty.get.pageid eq "11"} {include file="rjw/sitemap.tpl"} {/if} {if $page_content ne ''} {if $config.General.parse_smarty_tags eq "Y"} {eval var=$page_content} {else} {$page_content} {if $smarty.get.pageid eq "1" or $smarty.get.pageid eq "2" or $smarty.get.pageid eq "3" or $smarty.get.pageid eq "4" or $smarty.get.pageid eq "5" or $smarty.get.pageid eq "6" or $smarty.get.pageid eq "7" or $smarty.get.pageid eq "8" or $smarty.get.pageid eq "9" or $smarty.get.pageid eq "12"} {include file="rjw/welcome_ship.tpl"}{/if} {/if} {/if} {/capture} {include file="dialog.tpl" title=$page_data.title content=$smarty.capture.dialog extra="width=100%"}

This is the same arrangement I have used for another copy of x-cart I have that isn't as current. I have ticked in general setting "Parse Smarty tags in the content of embedded static pages: "

For some reason it isn't recognizing the .tpl file. I have looked in the source code of page in question and no navigation bar is being displayed.

Please let me know why this isn't working. The 4.0.19 is the one I am having trouble with.

Thanks,


Randal
__________________
***********************
Visit Our Other Web Sites!
∙ Nutritional Herbs and Supplements
<a href="http://www.theherbsplace.com"> The Herbs Place </a>
∙ Frugal Ideas and a Forum To Submit Your Questions
<a href="http://www.thefrugallife.com"> The Frugal Life </a>
∙ Healthy and Natural Pet Products
<a href="http://www.healthypetcorner.com"> Healthy Pet Corner </a>
***********************

Joined 08/02/05
X-Cart Gold Version 4.3.2
Linux RedHat Enterprise
Reply With Quote
  #2  
Old 09-07-2009, 03:20 PM
  JWait's Avatar 
JWait JWait is offline
 

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

Default Re: Static Page Include Problem

Is "rjw/welcome_ship.tpl" the .tpl it is not recognizing? Does it exist in the folder "skin1/rjw/" ?
__________________
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 09-08-2009, 05:02 AM
 
sharingsunshine sharingsunshine is offline
 

Senior Member
  
Join Date: Aug 2005
Location: Palmyra, VA
Posts: 149
 

Default Re: Static Page Include Problem

Yes, that is what X-Cart found out. I thought it was uploaded because I could see it. However, the code was not being brought in by the .tpl file. Instead, it was being brought in by a language variable but it was news to me.

I am embarrassed that it was so simple of a solution.

Instead of going through the pages.tpl interface, I was also needing to embed the smarty code into an individual static page. Do you know what syntax I would use for that?

Thanks,

Randal
__________________
***********************
Visit Our Other Web Sites!
∙ Nutritional Herbs and Supplements
<a href="http://www.theherbsplace.com"> The Herbs Place </a>
∙ Frugal Ideas and a Forum To Submit Your Questions
<a href="http://www.thefrugallife.com"> The Frugal Life </a>
∙ Healthy and Natural Pet Products
<a href="http://www.healthypetcorner.com"> Healthy Pet Corner </a>
***********************

Joined 08/02/05
X-Cart Gold Version 4.3.2
Linux RedHat Enterprise
Reply With Quote
  #4  
Old 09-08-2009, 05:14 AM
  ARW VISIONS's Avatar 
ARW VISIONS ARW VISIONS is offline
 

X-Man
  
Join Date: Jan 2007
Location: Pensacola, FL
Posts: 2,536
 

Default Re: Static Page Include Problem

Are there not individual pages in that version of x-cart?
__________________
xcart 5.1.2
Reply With Quote
  #5  
Old 09-08-2009, 05:24 AM
 
sharingsunshine sharingsunshine is offline
 

Senior Member
  
Join Date: Aug 2005
Location: Palmyra, VA
Posts: 149
 

Default Re: Static Page Include Problem

Yes, there are individual pages but at the time I needed to do it at the pages.tpl level because there were too many to address.

But as you can see from my last reply I now need to have the ability at the individual level and now I need to know that syntax.

Thanks,

Randal
__________________
***********************
Visit Our Other Web Sites!
∙ Nutritional Herbs and Supplements
<a href="http://www.theherbsplace.com"> The Herbs Place </a>
∙ Frugal Ideas and a Forum To Submit Your Questions
<a href="http://www.thefrugallife.com"> The Frugal Life </a>
∙ Healthy and Natural Pet Products
<a href="http://www.healthypetcorner.com"> Healthy Pet Corner </a>
***********************

Joined 08/02/05
X-Cart Gold Version 4.3.2
Linux RedHat Enterprise
Reply With Quote
  #6  
Old 09-08-2009, 05:46 AM
  ARW VISIONS's Avatar 
ARW VISIONS ARW VISIONS is offline
 

X-Man
  
Join Date: Jan 2007
Location: Pensacola, FL
Posts: 2,536
 

Default Re: Static Page Include Problem

Can't you just put your content directly in the static page.

I guess I don't understand what you are trying to do.
__________________
xcart 5.1.2
Reply With Quote
  #7  
Old 09-08-2009, 06:34 AM
 
sharingsunshine sharingsunshine is offline
 

Senior Member
  
Join Date: Aug 2005
Location: Palmyra, VA
Posts: 149
 

Default Re: Static Page Include Problem

Yes, I can put the content in the static page directly. However, it is content that needs to be in several static pages and it changes over time. It lists a shipping charge and that can change based on the manufacturers requirments.

Therefore, I was wanting to put in a .tpl file that I can change one time, if necessary, and it will be changed automatically through all of the static pages.

Hope that makes more sense.

Randal
__________________
***********************
Visit Our Other Web Sites!
∙ Nutritional Herbs and Supplements
<a href="http://www.theherbsplace.com"> The Herbs Place </a>
∙ Frugal Ideas and a Forum To Submit Your Questions
<a href="http://www.thefrugallife.com"> The Frugal Life </a>
∙ Healthy and Natural Pet Products
<a href="http://www.healthypetcorner.com"> Healthy Pet Corner </a>
***********************

Joined 08/02/05
X-Cart Gold Version 4.3.2
Linux RedHat Enterprise
Reply With Quote
  #8  
Old 09-08-2009, 06:41 AM
  cflsystems's Avatar 
cflsystems cflsystems is offline
 

Veteran
  
Join Date: Apr 2007
Posts: 14,190
 

Default Re: Static Page Include Problem

On static pages window make sure you tick "Parse Smarty tags in the content of embedded pages"
__________________
Steve Stoyanov
CFLSystems.com
Web Development
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 04:37 AM.

   

 
X-Cart forums © 2001-2020