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

New .TPL Trouble

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 05-20-2007, 08:16 AM
  Terrybraley's Avatar 
Terrybraley Terrybraley is offline
 

Senior Member
  
Join Date: Oct 2005
Location: Atlanta Georgia
Posts: 142
 

Default New .TPL Trouble

I created a new tpl file to show up under the search.tpl. I placed it in the head.tpl under the search.tpl. No problem. Everything works but I can't get it to exspand the width 100%.

www.roadrashapparel.com/novelties/home.php

You see the links, Home,,,,,,
The blue line won't exspand 100%

any suggestions?
Attached Files
File Type: txt head.txt (2.7 KB, 74 views)
File Type: txt hor_categories.txt (750 Bytes, 71 views)
__________________
Road Rash Apparel LLC
www.roadrashapparel.com

X-Cart Gold Ver.4.1.8
DSEFU Mod
PHP 4.3.11
MySQL server 4.1.22-max-log
MySQL client 5.0.18
Web server Apache
Operation system Linux
Perl 5.008
XML parser (expat) 1.95.6
Reply With Quote
  #2  
Old 05-20-2007, 08:17 AM
 
balinor balinor is offline
 

Veteran
  
Join Date: Oct 2003
Location: Connecticut, USA
Posts: 30,253
 

Default Re: New .TPL Trouble

Terry please don't post questions in the Completed Custom Mods forum. Moving to Template Editing.
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #3  
Old 05-20-2007, 08:29 AM
  Terrybraley's Avatar 
Terrybraley Terrybraley is offline
 

Senior Member
  
Join Date: Oct 2005
Location: Atlanta Georgia
Posts: 142
 

Default Re: New .TPL Trouble

sorry about that balinor
__________________
Road Rash Apparel LLC
www.roadrashapparel.com

X-Cart Gold Ver.4.1.8
DSEFU Mod
PHP 4.3.11
MySQL server 4.1.22-max-log
MySQL client 5.0.18
Web server Apache
Operation system Linux
Perl 5.008
XML parser (expat) 1.95.6
Reply With Quote
  #4  
Old 05-21-2007, 08:29 AM
  Terrybraley's Avatar 
Terrybraley Terrybraley is offline
 

Senior Member
  
Join Date: Oct 2005
Location: Atlanta Georgia
Posts: 142
 

Default Re: New .TPL Trouble

Anybody?
__________________
Road Rash Apparel LLC
www.roadrashapparel.com

X-Cart Gold Ver.4.1.8
DSEFU Mod
PHP 4.3.11
MySQL server 4.1.22-max-log
MySQL client 5.0.18
Web server Apache
Operation system Linux
Perl 5.008
XML parser (expat) 1.95.6
Reply With Quote
  #5  
Old 05-21-2007, 09:56 AM
  n00bert's Avatar 
n00bert n00bert is offline
 

Advanced Member
  
Join Date: Feb 2007
Posts: 46
 

Default Re: New .TPL Trouble

Hi Terrybraley,

In Firefox on a mac, the two blue horizontal lines already stretch to 100% of the width of the "page". Do you want the blue lines to stretch to 100% of the viewport?

regards,
n00bert
__________________
Version 4.1.6 Gold

urban-kings.com
urbanwear and street fashion specialist
Reply With Quote
  #6  
Old 05-21-2007, 10:24 AM
  JWait's Avatar 
JWait JWait is offline
 

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

Default Re: New .TPL Trouble

Um.. in your "hor_categories" why is the table width="0" ?
__________________
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 05-22-2007, 05:18 AM
  Terrybraley's Avatar 
Terrybraley Terrybraley is offline
 

Senior Member
  
Join Date: Oct 2005
Location: Atlanta Georgia
Posts: 142
 

Default Re: New .TPL Trouble

If tried changing it to 100%, does no good.
__________________
Road Rash Apparel LLC
www.roadrashapparel.com

X-Cart Gold Ver.4.1.8
DSEFU Mod
PHP 4.3.11
MySQL server 4.1.22-max-log
MySQL client 5.0.18
Web server Apache
Operation system Linux
Perl 5.008
XML parser (expat) 1.95.6
Reply With Quote
  #8  
Old 05-22-2007, 10:16 AM
  JWait's Avatar 
JWait JWait is offline
 

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

Default Re: New .TPL Trouble

I see some other potential problems... in your head.txt file (which I assume is head.tpl)

<TABLE border="0" cellpadding="0" cellspacing="0" width="100%">
<TR>
<TD width="107">&nbsp;</TD>
<TD><A href="{$http_location}"><IMG src="{$ImagesDir}/xlogo.gif" width="100%" height="100%" border="0"></A></TD>
<TD valign="top" align="right">
{if $usertype eq "C"} <<<<<<<<<<<<<<<<<< what is the purpose of this if statement?

{/if}
</TD></TR>
</TABLE>
<TABLE border="0" cellpadding="0" cellspacing="0" width="100%">
<TR>
<TD colspan="2" class="VertMenuBorder"><IMG src="{$ImagesDir}/spacer.gif" width="1" height="1" border="0"></TD>
</TR>
<TR>
<TD class="HeadLine" height="22">
{if $usertype eq "C"}
{ include file="customer/search.tpl" }
{/if}
</TD>
<TD class="HeadLine" height="22">
{if $usertype eq "C"}
{ include file="login.tpl" }
{/if}

<tr>
<td class="" width="100%">{include file="customer/hor_categories.tpl"}</td> <<<<<< this will be inside the cell above that includes your login.tpl (and that cell is not closed)
</tr>

<TD class="HeadLine" align="right">
{if ($usertype eq "C" || $usertype eq "B")and $all_languages_cnt gt 1}
<TABLE border="0" cellpadding="0" cellspacing="0">
<FORM action="home.php" method="GET" name="sl_form">
<INPUT type="hidden" name="redirect" value="{$smarty.server.PHP_SELF}?{$smarty.server.Q UERY_STRING|escape}">
<TR>
<TD>
<B>{$lng.lbl_select_language}:&nbsp;</B>
<SELECT name="sl" onChange="javascript: document.sl_form.submit()">
{section name=ai loop=$all_languages}
<OPTION value="{$all_languages[ai].code}"{if $store_language eq $all_languages[ai].code} selected{/if}>{$all_languages[ai].language}</OPTION>
{/section}
</SELECT>
</TD></TR>
</FORM>
</TABLE>
{else}
&nbsp;
{/if}
</TD>
</TR>
<TR>
<TD colspan="2" class="VertMenuBorder"><IMG src="{$ImagesDir}/spacer.gif" width="1" height="1" border="0"></TD>
</TR>
{******** Remove this line to display how much products there are online ****
<TR>
<TD colspan="2" class="NumberOfArticles" align="right">{insert name="productsonline"} {$lng.lbl_products} {if $config.Appearance.show_in_stock eq "Y"}{$lng.lbl_and} {insert name="itemsonline"} {$lng.lbl_items} {/if}{$lng.lbl_online}&nbsp;</TD>
</TR>
**** Remove this line to display how much products there are online ********}
<TR>
<TD colspan="2" valign="middle" height="32">
<TABLE cellspacing="0" cellpadding="0" border="0" width="100%" height="18">
<TR>
<TD><IMG src="{$ImagesDir}/spacer.gif" width="1" height="18" border="0"></TD>
{if (($main eq 'catalog' && $cat ne '') || $main eq 'product' || ($main eq 'comparison' && $mode eq 'compare_table') || ($main eq 'choosing' && $smarty.get.mode eq 'choose')) && $config.Appearance.enabled_printable_version eq 'Y'}
<TD width="100%" valign="middle" align="right">{include file="printable.tpl"}</TD>
<TD><IMG src="{$ImagesDir}/spacer.gif" width="176" height="1" border="0"></TD>
{/if}
</TR>
</TABLE>
</TD>
</TR>
</TABLE>
__________________
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
  #9  
Old 05-22-2007, 01:27 PM
  Terrybraley's Avatar 
Terrybraley Terrybraley is offline
 

Senior Member
  
Join Date: Oct 2005
Location: Atlanta Georgia
Posts: 142
 

Default Re: New .TPL Trouble

{* $Id: head.tpl,v 1.40.2.4 2005/11/15 09:25:38 max Exp $ *}
<TABLE border="0" cellpadding="0" cellspacing="0" width="100%">
<TR>
<TD width="107">&nbsp;</TD>
<TD><A href="{$http_location}"><IMG src="{$ImagesDir}/xlogo.gif" width="100%" height="100%" border="0"></A></TD>
<TD valign="top" align="right">
{if $usertype eq "C"}
{include file="customer/top_menu.tpl"} <<<<<< i added this back >>>>>>
{/if}
</TD></TR>
</TABLE>
<TABLE border="0" cellpadding="0" cellspacing="0" width="100%">
<TR>
<TD colspan="2" class="VertMenuBorder"><IMG src="{$ImagesDir}/spacer.gif" width="1" height="1" border="0"></TD>
</TR>
<TR>
<TD class="HeadLine" height="22">
{if $usertype eq "C"}
{ include file="customer/search.tpl" }
{/if}
</TD>
<TD class="HeadLine" height="22">
{if $usertype eq "C"}
{ include file="login.tpl" }
{/if}

<tr>
<td class="" width="100%">{include file="customer/hor_categories.tpl"}</td>
</tr>

<TD class="HeadLine" align="right">
{if ($usertype eq "C" || $usertype eq "B")and $all_languages_cnt gt 1}
<TABLE border="0" cellpadding="0" cellspacing="0">
<FORM action="home.php" method="GET" name="sl_form">
<INPUT type="hidden" name="redirect" value="{$smarty.server.PHP_SELF}?{$smarty.server.Q UERY_STRING|escape}">
<TR>
<TD>


as far as the :
<tr>
<td class="" width="100%">{include file="customer/hor_categories.tpl"}</td> <<<<<< this will be inside the cell above that includes your login.tpl (and that cell is not closed)
</tr>

It added the links below the search.tpl

Look at www.roadrashapparel.com/novelties/home.php

But it doesn't exspand 100%, not on IE
__________________
Road Rash Apparel LLC
www.roadrashapparel.com

X-Cart Gold Ver.4.1.8
DSEFU Mod
PHP 4.3.11
MySQL server 4.1.22-max-log
MySQL client 5.0.18
Web server Apache
Operation system Linux
Perl 5.008
XML parser (expat) 1.95.6
Reply With Quote
  #10  
Old 05-22-2007, 02:10 PM
  JWait's Avatar 
JWait JWait is offline
 

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

Default Re: New .TPL Trouble

I think the table that you have both search and login is "wrapping" to the next line.
Try this...

<TD class="HeadLine" height="22">
{if $usertype eq "C"}
{ include file="customer/search.tpl" }
{/if}
</TD>
<TD class="HeadLine" height="22">
{if $usertype eq "C"}
{ include file="login.tpl" }
{/if}
{* added to close cell and start categories in new cell *}
</TD></TR>
{* / added to close cell and start categories in new cell *}
<tr>
<td class="" width="100%">{include file="customer/hor_categories.tpl"}</td>
</tr>

++++++++++++++++++++
Since the "class" in the code above is blank ("") it will show as whatever your default text is, is that what you want?

Also, I don't understand why the table in hor_categories is only 430 px wide. That could be what is making the "gray bar" only go half way across the page. The blue line goes 100%.
__________________
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
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:36 PM.

   

 
X-Cart forums © 2001-2020