Jump to content
  • 0

Шаблон из joomla в smarty


atosdo
 Share

Question

Всем привет.

Есть такой вопрос.

Имеется шаблон сверстанный в joomla через <div>/css.

И есть движок в котором шаблон создан через smarty - в .tpl-ях.

В тех .tpl куча smarty-кода да и еще в табличной верстке.

Приведу немного кода:


<body style="margin: 0px;" onload="get_parseGET(); InComparisonList();{if (($data.user_type eq 2 || ($data.user_type eq 3 && $data.agency_approve eq 1)) && $data.id_country && $data.in_base && $use_maps_in_account)||($use_maps_in_viewprofile && $profile.country_name && $view eq 'general' && (($registered eq 1 && $group_type eq 1) || ($registered eq 1 && $contact_for_free) || $mhi_registration || $contact_for_unreg) && ($profile.in_base || $profile.company_data.in_base))||(($profile.type eq 2 || $profile.type eq 4) && $view eq 'map' && $data.in_base && $use_maps_in_viewprofile)} getMapGlobal("{$map.name}", "map_container", "{$profile.adress}", "{$profile.city_name}", "{$profile.region_name}", "{$profile.country_name}", "{$profile.lat}", "{$profile.lon}");{/if}">
<table cellpadding="0" cellspacing="0" width="100%" border="0">
<tr valign="top">
<td align="center">
<noscript><div style="padding-top: 10px;"><font class="error">{$lang.default_select.enable_javascript}</font><div></noscript>
<table cellpadding="0" cellspacing="0" class={if $section_name == "index"}"index_page"{else}"page"{/if} border="0">
<tr>
<td height="48" align="left">
<a href='{$server}{$site_root}/{if $registered}homepage.php{else}index.php{/if}' class="home_link">{$lang.default_select.home_page}</a>
<!--{section name=m loop=$lang_menu}
{if $lang_menu[m].vis eq 1}
<a class="lang_menu{if $lang_menu[m].id_lang eq $lang_code}_active{/if}" href="{$file_name}?lang_code={$lang_menu[m].id_lang}{$add_to_lang}">{$lang_menu[m].value}</a> 
{/if}
{/section}-->
</td>
<td height="48" align="right">
{strip}
<font class="hidden">
{if $registered}
<font class="text"><b>{$user[1]}</b></font>  <font class="text">|</font> 
<span id="comparison_str" {if !$comparison_ids_cnt}style="display: none;"{/if}>
 <a href="{$server}{$site_root}/compare.php">{$lang.default_select.comparison_list} ({$comparison_ids_cnt})</a>
  <font class="text">|</font> 
</span>
{if $lang_menu}
<select onchange="document.location.href = '{$file_name}?lang_code='+this.value+'{$add_to_lang}'">
{section name=m loop=$lang_menu}
{if $lang_menu[m].vis eq 1}
<option value="{$lang_menu[m].id_lang}" {if $lang_menu[m].id_lang eq $lang_code}selected{/if}>{$lang_menu[m].value}</option>
{/if}
{/section}
</select>
  <font class="text">|</font>
{/if}
{if !$mhi_services}
{if $period_rest>0}{if $lang_menu}  {/if}<font class="text">{$lang.headers.period_rest}:</font> <font class="text"><a href="services.php?sel=group">{$period_rest} {if $day_id eq 1}{$lang.default_select.days_1}{elseif $day_id eq 2}{$lang.default_select.days_2}{elseif $day_id eq 3}{$lang.default_select.days_3}{/if}</a>  <font class="text">|</font>{if !$lang_menu}  {/if}{/if}
{if $lang_menu}  {/if}<font class="text">{$lang.headers.user_account}:</font> <a href="./services.php" {if $section_name == 'services'} class="user_menu_link_active" {/if}>{$cur_symbol} {$user_account}</a>  <font class="text">|</font>
{/if}
{section name=m loop=$homepage_user_menu}
{if $smarty.section.m.index}  <font class="text">|</font>{/if}  <a href="{$homepage_user_menu[m].href}" {if $homepage_user_menu[m].onclick} onClick="{$homepage_user_menu[m].onclick}" {/if} {if $section_name == $homepage_user_menu[m].name} class="user_menu_link_active" {/if}>{$homepage_user_menu[m].value}</a>
{if $homepage_user_menu[m].new>0} <img src="{$site_root}{$template_root}{$template_images_root}/mail_alert.gif" border="0" vspace="0" hspace="0" alt="{$lang.default_select.unread_messages}">{/if}
{/section}
{else}
<span id="comparison_str" {if !$comparison_ids_cnt}style="display: none;"{/if}>
<a href="{$server}{$site_root}/compare.php">{$lang.default_select.comparison_list} ({$comparison_ids_cnt})</a>
  <font class="text">|</font>  
</span>
{if $lang_menu}
<select onchange="document.location.href = '{$file_name}?lang_code='+this.value+'{$add_to_lang}'">
{section name=m loop=$lang_menu}
{if $lang_menu[m].vis eq 1}
<option value="{$lang_menu[m].id_lang}" {if $lang_menu[m].id_lang eq $lang_code}selected{/if}>{$lang_menu[m].value}</option>
{/if}
{/section}
</select>
{if $index_user_menu}
  <font class="text">|</font>  
{/if}
{/if}
{section name=m loop=$index_user_menu}
{if $smarty.section.m.index}  |   {/if}<a href="{$index_user_menu[m].href}" {if $index_user_menu[m].onclick} onClick="{$index_user_menu[m].onclick}" {/if}>{$index_user_menu[m].value}</a>
{/section}
{/if}
</font>
{/strip}
</td>
</tr>
</table>
</td>
</tr>
...

Стоит ли заниматься переводом joomla шаблона в smarty?

Насколько это трудоемко?

Стоит ли с этим возиться или это сплошная головная боль?

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. See more about our Guidelines and Privacy Policy