aboutsummaryrefslogtreecommitdiffstats
path: root/template/default
diff options
context:
space:
mode:
authorgweltas <gweltas@piwigo.org>2004-02-07 11:50:26 +0000
committergweltas <gweltas@piwigo.org>2004-02-07 11:50:26 +0000
commit65753539220ba870b738866c425c89d73753c727 (patch)
tree92e77bf4da8946d051f8d46176fbe1ead900c0d8 /template/default
parent1d9b840cf8421ad06d81035f209149eceb1b357f (diff)
Template modification
Split of the french language file git-svn-id: http://piwigo.org/svn/trunk@351 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to '')
-rw-r--r--template/default/about.tpl (renamed from template/default/about.vtp)16
-rw-r--r--template/default/category.tpl112
-rw-r--r--template/default/category.vtp98
-rw-r--r--template/default/footer.htm1
-rw-r--r--template/default/footer.tpl9
-rw-r--r--template/default/footer.vtp8
-rw-r--r--template/default/header.htm1
-rw-r--r--template/default/header.tpl12
-rw-r--r--template/default/header.vtp13
-rw-r--r--template/default/htmlfunctions.inc.php121
10 files changed, 193 insertions, 198 deletions
diff --git a/template/default/about.vtp b/template/default/about.tpl
index 5b416d1b8..a309e3dc2 100644
--- a/template/default/about.vtp
+++ b/template/default/about.tpl
@@ -1,20 +1,20 @@
<table style="width:100%;height:100%">
<tr align="center" valign="middle">
<td>
- {#frame_start}1px{#frame_begin}
- <div class="titrePage">{#about_title}</div>
- {#frame_end}
+ {F_START}1px{F_BEGIN}
+ <div class="titrePage">{PAGE_TITLE}</div>
+ {F_END}
<div style="margin-bottom:5px;">&nbsp;</div>
- {#frame_start}50%{#frame_begin}
+ {F_START}50%{F_BEGIN}
<div class="menu" style="white-space:normal;margin:10px;">
- {#about_message}
+ {L_ABOUT}
</div>
- {#frame_end}
+ {F_END}
<div style="text-align:center;margin:5px;">
- <a href="{#back_url}">{#about_return}</a>
+ <a href="{U_RETURN}">{L_RETURN}</a>
</div>
<div style="text-align:center;margin:5px;">
- <img src="./template/{#user_template}/images/php_sqreuil_artistes.gif" alt="php logo" />
+ <img src="./template/default/images/php_sqreuil_artistes.gif" alt="php logo" />
</div>
</td>
</tr>
diff --git a/template/default/category.tpl b/template/default/category.tpl
new file mode 100644
index 000000000..7feb34da3
--- /dev/null
+++ b/template/default/category.tpl
@@ -0,0 +1,112 @@
+<table style="width:100%;">
+ <tr>
+ <td valign="top" style="width:1%;padding:10px;">
+ {F_START}100%{F_BEGIN}
+ <div class="titreMenu">
+ <a href="{U_HOME}">{L_CATEGORIES}</a>
+ </div>
+ <div class="menu">
+ <!-- BEGIN category -->
+ {category.INDENT}
+ <!-- BEGIN bulletlink -->
+ <a href="{category.bulletlink.U_BULLET_LINK}"><img src="{category.bulletlink.BULLET_IMAGE}" style="border:none;" alt="" /></a>
+ <!-- END bulletlink -->
+ <!-- BEGIN bulletnolink -->
+ <img src="{category.bulletnolink.BULLET_IMAGE}" style="border:none;" alt="" />
+ <!-- END bulletnolink -->
+ &nbsp;<a href="{category.U_LINK}"><span title='{L_HINT_CATEGORY}' style="{category.T_NAME}">{category.LINK_NAME}</span>
+ &nbsp;<span class="menuInfoCat">[
+ <!-- BEGIN subcat -->
+ <span title="{category.NB_SUBCATS} {L_SUBCAT}">{category.NB_SUBCATS}</span>&nbsp;-
+ <!-- END subcat -->
+ <span title="{category.TOTAL_CAT} {L_IMG_AVAILABLE}">{category.TOTAL_CAT}</span>&nbsp;]</span></a>{category.CAT_ICON}<br />
+ <!-- END category -->
+
+ <div class="totalImages">[&nbsp;{NB_PICTURE}&nbsp;{L_TOTAL}&nbsp;]</div>
+ <!-- BEGIN favorites -->
+ <br />&nbsp;<img src="{T_COLLAPSED}" alt='' />&nbsp;<a href="{U_FAVORITE}"><span title="{L_FAVORITE_HINT}" style="font-weight:bold;">{L_FAVORITE}</span></a>&nbsp;<span class="menuInfoCat">[&nbsp;{favorites.NB_FAV}&nbsp;]</span>
+ <!-- END favorites -->
+ <br />&nbsp;<img src="{T_COLLAPSED}" alt='' />&nbsp;<span style="font-weight:bold;">{L_STATS}</span>
+ <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<img src="{T_COLLAPSED}" alt='' />&nbsp;<a href="{U_MOST_VISITED}"><span title="{L_MOST_VISITED_HINT}" style="font-weight:bold;">{S_TOP}&nbsp;{L_MOST_VISITED}</span></a>
+ <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<img src="{T_COLLAPSED}" alt='' />&nbsp;<a href="{U_RECENT}"><span title="{L_RECENT_HINT}" style="font-weight:bold;">{L_RECENT}</span></a> {T_SHORT}
+ </div>
+ {F_END}
+ <div style="margin-bottom:5px;">&nbsp;</div>
+ {F_START}100%{F_BEGIN}
+ <div class="titreMenu">{L_SUMMARY}</div>
+ <div class="menu">
+ <!-- BEGIN summary -->
+ &nbsp;<img src="{T_COLLAPSED}" alt=''/>&nbsp;<a href="{summary.U_SUMMARY}" title="{summary.TITLE}">{summary.NAME}</a><br />
+ <!-- END summary -->
+ <!-- BEGIN upload -->
+ <br />&nbsp;<img src="{T_COLLAPSED}" alt=''/>&nbsp;<a href="{upload.U_UPLOAD}">{L_UPLOAD}</a>
+ <!-- END upload -->
+ </div>
+ {F_END}
+ </td>
+ <td style="padding:5px;width:99%;" valign="top">
+ <table style="width:100%;">
+ <tr>
+ <td align="center">
+ {F_START}1%{F_BEGIN}
+ <div class="titrePage">{TITLE}</div>
+ {F_END}
+ <div style="margin-bottom:5px;">&nbsp;</div>
+ <!-- BEGIN thumbnails -->
+ <table class="thumbnail">
+ <!-- BEGIN line -->
+ <tr>
+ <!-- BEGIN thumbnail -->
+ <td valign="bottom" class="thumbnail">
+ <a href="{thumbnails.line.thumbnail.U_IMG_LINK}" class="back">
+ <img src="{thumbnails.line.thumbnail.IMAGE}"
+ alt="{thumbnails.line.thumbnail.IMAGE_ALT}"
+ title="{thumbnails.line.thumbnail.IMAGE_TITLE}"
+ class="imgLink" />
+ <br />
+ {thumbnails.line.thumbnail.IMAGE_NAME}</a>
+ {thumbnails.line.thumbnail.IMAGE_TS}
+ <!-- BEGIN nb_comments -->
+ <br />{thumbnails.line.thumbnail.NB_COMMENTS} {L_COMMENTS}
+ <!-- END nb_comments -->
+ </td>
+ <!-- END thumbnail -->
+ </tr>
+ <!-- END line -->
+ </table>
+ <!-- END thumbnails -->
+ </td>
+ </tr>
+ <tr>
+ <td align="left">
+ <!-- BEGIN cat_infos -->
+ <!-- BEGIN navigation -->
+ <div class="navigationBar">{cat_infos.navigation.NAV_BAR}</div>
+ <!-- END navigation -->
+ <!-- BEGIN comment -->
+ <div class="comments">{cat_infos.comment.COMMENTS}</div>
+ <!-- END comment -->
+ <div class="infoCat">
+ {L_NB_IMG} "{cat_infos.CAT_NAME}" : {cat_infos.NB_IMG_CAT}
+ </div>
+ <!-- END cat_infos -->
+ </td>
+ </tr>
+ <tr>
+ <td align="right">
+ {F_START}1%{F_BEGIN}
+ <div class="info">
+ {L_USER}&nbsp;{USERNAME}<br />
+ {L_RECENT_IMG}&nbsp;{S_SHORT_PERIOD}&nbsp;{L_DAYS}
+ {T_SHORT}<br />
+ {L_RECENT_IMAGE}&nbsp;{S_LONG_PERIOD}&nbsp;{L_DAYS}
+ {T_LONG}<br />
+ {L_SEND_MAIL}&nbsp;<a href="mailto:{S_MAIL}?subject={L_TITLE_MAIL}"><span style="font-weight:bold;">{S_WEBMASTER}</span></a>
+ </div>
+ {F_END}
+ </td>
+ </tr>
+ </table>
+ </td>
+ </tr>
+</table> \ No newline at end of file
diff --git a/template/default/category.vtp b/template/default/category.vtp
deleted file mode 100644
index bab094d54..000000000
--- a/template/default/category.vtp
+++ /dev/null
@@ -1,98 +0,0 @@
- <table style="width:100%;">
- <tr>
- <td valign="top" style="width:1%;padding:10px;">
- {#frame_start}100%{#frame_begin}
- <div class="titreMenu">
- <a href="{#home_url}">{#categories}</a>
- </div>
- <div class="menu">
- <!--VTP_category-->{#indent}<!--VTP_bullet_w_link--><a href="{#bullet_link}"><img src="{#bullet_url}" style="border:none;" alt="&gt;" /></a><!--/VTP_bullet_w_link--><!--VTP_bullet_wo_link--><img src="{#bullet_url}" style="border:none;" alt="&gt;" /><!--/VTP_bullet_wo_link-->&nbsp;<a href="{#link_url}"><span title="{#hint_category}" style="{#name_style}">{#link_name}</span>&nbsp;<span class="menuInfoCat">[&nbsp;<!--VTP_subcat--><span title="{#nb_subcats} {#sub-cat}">{#nb_subcats}</span>&nbsp;-&nbsp;<!--/VTP_subcat--><span title="{#total_cat} {#images_available}">{#total_cat}</span>&nbsp;]</span></a>{#cat_icon}<br />
- <!--/VTP_category-->
- <div class="totalImages">[&nbsp;{#nb_total_pictures}&nbsp;{#total}&nbsp;]</div>
- <!--VTP_favorites-->
- <br />&nbsp;<img src="{#lien_collapsed}" alt="&gt;" />&nbsp;<a href="{#url}"><span title="{#favorite_cat_hint}" style="font-weight:bold;">{#favorite_cat}</span></a>&nbsp;<span class="menuInfoCat">[&nbsp;{#nb_favorites}&nbsp;]</span>
- <!--/VTP_favorites-->
- <br />&nbsp;<img src="{#lien_collapsed}" alt="&gt;" />&nbsp;<span style="font-weight:bold;">{#stats}</span>
- <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<img src="{#lien_collapsed}" alt="&gt;" />&nbsp;<a href="{#most_visited_url}"><span title="{#most_visited_cat_hint}" style="font-weight:bold;">{#top_number}&nbsp;{#most_visited_cat}</span></a>
- <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<img src="{#lien_collapsed}" alt="&gt;" />&nbsp;<a href="{#recent_url}"><span title="{#recent_cat_hint}" style="font-weight:bold;">{#recent_cat}</span></a> {#icon_short}
- </div>
- {#frame_end}
- <div style="margin-bottom:5px;">&nbsp;</div>
- {#frame_start}100%{#frame_begin}
- <div class="titreMenu">{#title_menu}</div>
- <div class="menu">
- <!--VTP_summary-->
- &nbsp;<img src="{#lien_collapsed}" alt="&gt;"/>&nbsp;<a href="{#url}" title="{#title}">{#name}</a><br />
- <!--/VTP_summary-->
- <!--VTP_upload-->
- <br />&nbsp;<img src="{#lien_collapsed}" alt="&gt;"/>&nbsp;<a href="{#url}">{#upload_picture}</a>
- <!--/VTP_upload-->
- </div>
- {#frame_end}
- </td>
- <td style="padding:5px;width:99%;" valign="top">
- <table style="width:100%;">
- <tr>
- <td align="center">
- {#frame_start}1%{#frame_begin}
- <div class="titrePage">{#cat_title}</div>
- {#frame_end}
- <div style="margin-bottom:5px;">&nbsp;</div>
- <!--VTP_thumbnails-->
- <table class="thumbnail">
- <!--VTP_line-->
- <tr>
- <!--VTP_thumbnail-->
- <td valign="bottom" class="thumbnail">
- <a href="{#url}" class="back">
- <img src="{#src}"
- alt="{#alt}"
- title="{#title}"
- class="imgLink"/></a>
- <br />
- <a href="{#url}" class="back">{#name}</a>
- {#icon}
- <!--VTP_nb_comments-->
- <br />{#nb} {#comments}
- <!--/VTP_nb_comments-->
- </td>
- <!--/VTP_thumbnail-->
- </tr>
- <!--/VTP_line-->
- </table>
- <!--/VTP_thumbnails-->
- </td>
- </tr>
- <tr>
- <td align="left">
- <!--VTP_cat_infos-->
- <!--VTP_navigation-->
- <div class="navigationBar">{#navigation_bar}</div>
- <!--/VTP_navigation-->
- <!--VTP_comment-->
- <div class="comments">{#cat_comment}</div>
- <!--/VTP_comment-->
- <div class="infoCat">
- {#nb_image_category} "{#cat_name}" : {#cat_nb_images}
- </div>
- <!--/VTP_cat_infos-->
- </td>
- </tr>
- <tr>
- <td align="right">
- {#frame_start}1%{#frame_begin}
- <div class="info">
- {#connected_user}&nbsp;{#username}<br />
- {#recent_image}&nbsp;{#short_period}&nbsp;{#days}
- {#icon_short}<br />
- {#recent_image}&nbsp;{#long_period}&nbsp;{#days}
- {#icon_long}<br />
- {#send_mail}&nbsp;<a href="mailto:{#mail_webmaster}?subject={#title_send_mail}"><span style="font-weight:bold;">{#webmaster}</span></a>
- </div>
- {#frame_end}
- </td>
- </tr>
- </table>
- </td>
- </tr>
- </table> \ No newline at end of file
diff --git a/template/default/footer.htm b/template/default/footer.htm
deleted file mode 100644
index 501782eac..000000000
--- a/template/default/footer.htm
+++ /dev/null
@@ -1 +0,0 @@
-<!-- footer --> \ No newline at end of file
diff --git a/template/default/footer.tpl b/template/default/footer.tpl
new file mode 100644
index 000000000..f62f6e1f1
--- /dev/null
+++ b/template/default/footer.tpl
@@ -0,0 +1,9 @@
+<!-- BEGIN debug -->
+ <div class="copyright">{L_GEN_TIME} {S_TIME}</div>
+<!-- END debug -->
+ <!-- Please, do not remove this copyright. If you really want to,
+ contact me pierrick@z0rglub.com to find a solution on how
+ to show the origin of the script...-->
+ <div class="copyright">Powered by <a href="{U_SITE}" class="back">PhpWebGallery</a> {S_VERSION}</div>
+ </body>
+</html> \ No newline at end of file
diff --git a/template/default/footer.vtp b/template/default/footer.vtp
deleted file mode 100644
index 1cf62a5d5..000000000
--- a/template/default/footer.vtp
+++ /dev/null
@@ -1,8 +0,0 @@
- <div class="copyright">{#generation_time} {#time}</div>
- <!-- Please, do not remove this copyright. If you really want to,
- contact me pierrick@z0rglub.com to find a solution on how
- to show the origin of the script...-->
- <div class="copyright">Powered by <a href="{#site_url}" class="back">PhpWebGallery</a> {#version}</div>
- {#footer}
- </body>
-</html> \ No newline at end of file
diff --git a/template/default/header.htm b/template/default/header.htm
deleted file mode 100644
index 962fe8b58..000000000
--- a/template/default/header.htm
+++ /dev/null
@@ -1 +0,0 @@
-<!-- header -->
diff --git a/template/default/header.tpl b/template/default/header.tpl
new file mode 100644
index 000000000..b3bb96501
--- /dev/null
+++ b/template/default/header.tpl
@@ -0,0 +1,12 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="fr" lang="fr">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset={S_CONTENT_ENCODING}" />
+<meta http-equiv="Content-Style-Type" content="text/css" />
+<!-- BEGIN refresh -->
+<meta http-equiv="refresh" content="{S_REFRESH_TIME};url={U_REFRESH}">
+<!-- END refresh -->
+<title>{PAGE_TITLE}</title>
+<link rel="stylesheet" href="{T_STYLE}" type="text/css" />
+</head>
+<body>
diff --git a/template/default/header.vtp b/template/default/header.vtp
deleted file mode 100644
index e97197576..000000000
--- a/template/default/header.vtp
+++ /dev/null
@@ -1,13 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="fr" lang="fr">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset={#charset}" />
-<meta http-equiv="Content-Style-Type" content="text/css" />
-<!--VTP_refresh-->
-<meta http-equiv="refresh" content="{#time};url={#url}">
-<!--/VTP_refresh-->
-<title>{#title}</title>
-<link rel="stylesheet" href="{#style}" type="text/css" />
-</head>
-<body>
-{#header}
diff --git a/template/default/htmlfunctions.inc.php b/template/default/htmlfunctions.inc.php
index ad52bfc13..a3365b4a5 100644
--- a/template/default/htmlfunctions.inc.php
+++ b/template/default/htmlfunctions.inc.php
@@ -17,10 +17,8 @@
* *
***************************************************************************/
-//include( PREFIX_INCLUDE.'./template/'.$user['template'].'/theme/conf.php' );
$user['lien_expanded']='./template/'.$user['template'].'/theme/expanded.gif';
$user['lien_collapsed']='./template/'.$user['template'].'/theme/collapsed.gif';
-//include_once( PREFIX_INCLUDE.'./template/'.$user['template'].'/style.inc.php');
function get_icon( $date_comparaison )
{
@@ -104,22 +102,6 @@ function get_frame_start()
{
return '<table style="width:';
}
-/*
-function get_frame_begin()
-{
- return ';">
- <tr>
- <td style="border:1px dashed gray;width:100%;padding:5px;background-color:white;">';
-}
-
-function get_frame_end()
-{
- return '
- </td>
- </tr>
- </table>';
-}
-*/
function get_frame_begin()
{
@@ -158,86 +140,87 @@ function get_frame_end()
function initialize_template()
{
- global $vtp, $handle, $user, $lang;
+ global $template, $user, $lang;
+
+ $template->assign_vars(array(
+ 'F_START' => get_frame_start(),
+ 'F_BEGIN' => get_frame_begin(),
+ 'F_END' => get_frame_end()
+ )
+ );
+
- // $vtp->setGlobalVar( $handle, 'charset', $lang['charset'] );
- //$vtp->setGlobalVar( $handle, 'style', $user['style'] );
+ global $vtp, $handle;
+ if (isset($handle))
+ {
$vtp->setGlobalVar( $handle, 'frame_start', get_frame_start() );
$vtp->setGlobalVar( $handle, 'frame_begin', get_frame_begin() );
$vtp->setGlobalVar( $handle, 'frame_end', get_frame_end() );
- //$vtp->setVarF( $handle, 'header',
- // './template/'.$user['template'].'/header.htm' );
- //$vtp->setVarF( $handle, 'footer',
- // './template/'.$user['template'].'/footer.htm' );
+ }
}
-function display_category( $category, $indent, $handle )
+function display_category( $category, $indent )
{
- global $user,$lang,$vtp;
+ global $user,$lang,$template, $vtp, $handle;
+
+ $style='';
+ $url = './category.php?cat='.$category['id'];
+ $url.= '&amp;expand='.$category['expand_string'];
+ $name = $category['name'];
+ if ( $name == '' ) $name = str_replace( '_', ' ', $category['dir'] );
+ if ( $category['id_uppercat'] == '' )
+ {
+ $style = 'font-weight:bold;';
+ }
+
+ $template->assign_block_vars('category', array(
+ 'LINK_NAME' => $name,
+ 'INDENT' => $indent,
+ 'NB_SUBCATS'=>$category['nb_sub_categories'],
+ 'TOTAL_CAT'=>$category['nb_images'],
+ 'CAT_ICON'=>get_icon($category['date_last']),
+
+ 'T_NAME'=>$style,
+ 'U_LINK' => add_session_id($url)));
- $vtp->addSession( $handle, 'category' );
- $vtp->setVar( $handle, 'category.indent', $indent );
if ( $user['expand'] or $category['nb_sub_categories'] == 0 )
{
- $vtp->addSession( $handle, 'bullet_wo_link' );
- $vtp->setVar( $handle, 'bullet_wo_link.bullet_url',
- $user['lien_collapsed'] );
- $vtp->closeSession( $handle, 'bullet_wo_link' );
+ $template->assign_block_vars('category.bulletnolink', array('BULLET_IMAGE' => $user['lien_collapsed']));
}
else
{
- $vtp->addSession( $handle, 'bullet_w_link' );
- $url = './category.php';
- if (isset($page['cat']))
+ $url = './category.php';
+ if (isset($page['cat']))
{
- $url .='?cat='.$page['cat'];
- $url.= '&amp;expand='.$category['expand_string'];
+ $url .='?cat='.$page['cat'];
+ $url.= '&amp;expand='.$category['expand_string'];
}
else if ($category['expand_string']<>'')
{
- $url.= '?expand='.$category['expand_string'];
+ $url.= '?expand='.$category['expand_string'];
}
- $vtp->setVar( $handle, 'bullet_w_link.bullet_link', add_session_id($url) );
- if ( $category['expanded'] )
+
+ if ( $category['expanded'] )
{
- $vtp->setVar( $handle, 'bullet_w_link.bullet_url',
- $user['lien_expanded'] );
+ $img=$user['lien_expanded'];
}
else
{
- $vtp->setVar( $handle, 'bullet_w_link.bullet_url',
- $user['lien_collapsed'] );
+ $img=$user['lien_collapsed'];
}
- $vtp->closeSession( $handle, 'bullet_w_link' );
- }
-
- $url = './category.php?cat='.$category['id'];
- $url.= '&amp;expand='.$category['expand_string'];
- $vtp->setVar( $handle, 'category.link_url', add_session_id( $url ) );
-
- $name = $category['name'];
- if ( $name == '' ) $name = str_replace( '_', ' ', $category['dir'] );
- $vtp->setVar( $handle, 'category.link_name', $name );
-
- if ( $category['id_uppercat'] == '' )
- {
- $vtp->setVar( $handle, 'category.name_style', 'font-weight:bold;' );
- }
- if ( $category['nb_sub_categories'] > 0 )
- {
- $vtp->addSession( $handle, 'subcat' );
- $vtp->setVar( $handle,'subcat.nb_subcats',$category['nb_sub_categories'] );
- $vtp->closeSession( $handle, 'subcat' );
+
+ $template->assign_block_vars('category.bulletlink', array(
+ 'BULLET_IMAGE' => $img,
+ 'U_BULLET_LINK'=> add_session_id($url)
+ ));
}
- $vtp->setVar( $handle, 'category.total_cat', $category['nb_images'] );
- $vtp->setVar( $handle, 'category.cat_icon',get_icon($category['date_last']));
- $vtp->closeSession( $handle, 'category' );
// recursive call
if ( $category['expanded'] )
{
foreach ( $category['subcats'] as $subcat ) {
- display_category( $subcat, $indent.str_repeat( '&nbsp', 2 ), $handle );
+ $template->assign_block_vars('category.subcat', array());
+ display_category( $subcat, $indent.str_repeat( '&nbsp', 2 ));
}
}
}