X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   (SOLVED) i need include .jsp file in .tpl file (https://forum.x-cart.com/showthread.php?t=3227)

maki 06-17-2003 03:12 PM

(SOLVED) i need include .jsp file in .tpl file
 
Hi all !!! i am newbie member, & my english is very poor sorry :P

i have one question:

i need call .jsp file from .tpl file ... is possible ???

i create a new link embedded in home.php page with the metod of editing home_main.tpl:

{elseif $smarty.get.mode eq "revelar"}
{include file="customer/main/revelar.tpl"}


& creating revelar.tpl:

{ include file="location.tpl" last_location="Revelar On-Line"}
{capture name=dialog}
{include file="jsp/login.jsp"} -----> is correct?
{/capture}
{ include file="dialog.tpl" title="Revelado On-Line" content=$smarty.capture.dialog extra="width=100%"}


& add new link in corresponding whit necessary file:

Revelar

but the .jsp file is no ready :(

i attempt to incorporate one independent module in jsp and to integrate it in x-cart

any idea ??

snorocket 06-17-2003 06:11 PM

what is .jsp?
 
is .jsp a javascript? if so you'll need to use the literal smarty tags like below with the include statement in between the literal tags, try it and see if it works, anythings worth a shot, let us know if it works

{literal}
include("http://www.yourwebsite.com/path/to/jsp/login.jsp");
{/literal}

shan 06-17-2003 06:13 PM

see http://smarty.php.net for more info on using smarty templates

maki 06-18-2003 12:45 AM

Re: what is .jsp?
 
Quote:

Originally Posted by snorocket
is .jsp a javascript? if so you'll need to use the literal smarty tags like below with the include statement in between the literal tags, try it and see if it works, anythings worth a shot, let us know if it works

{literal}
include("http://www.yourwebsite.com/path/to/jsp/login.jsp");
{/literal}


hi !!!

i have changed in .tpl file:

{ include file="location.tpl" last_location="Revelar On-Line"}
{capture name=dialog}
{literal}
include("http://xxx.xxx.xxx.xxx/jsp/login.jsp");
{/literal}

{/capture}
{ include file="dialog.tpl" title="Revelado On-Line" content=$smarty.capture.dialog extra="width=100%"}

but what appears it is the text chain: include("http://xxx.xxx.xxx.xxx/jsp/login.jsp");

where i am mistaken?

maki 06-19-2003 06:56 AM

Solved
 
{ include file="location.tpl" last_location="Revelar On-Line"}
{capture name=dialog}
{fetch file="jsp/login.jsp"} -----> fetch is the command
{/capture}
{ include file="dialog.tpl" title="Revelado On-Line" content=$smarty.capture.dialog extra="width=100%"}


:P


All times are GMT -8. The time now is 06:02 AM.

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