[3.2] Welche Bewandtnis mit Twig?

Alles zu Styles, Templates, Icons und Smilies für phpBB 3.3, sowie allgemeine Designfragen zur Integration von phpBB in bestehende Websites.
Forumsregeln
Bei Style spezifischen Fragen ist der Stylename und die Downloadquelle des Styles erforderlich sowie die URL vom betroffenen Forum.
ZNC
Mitglied
Beiträge: 229
Registriert: 21.05.2014 13:48
Wohnort: Köln

[3.2] Welche Bewandtnis mit Twig?

Beitrag von ZNC »

In dem Thread Konverter für phpBB-Syntax in TWIG-Syntax las ich, dass vermutlich irgendwann die phpBB-Templatestruktur auf die Twig-php-Templateengine umgestellt werden. In dem prosilver-Style sind scheinbar schon um die 90 diesbezügliche Änderungen zu sehen.

Heißt das, dass bereits Twig greift? Warum eine andere Sprache, die dann zu erlernen wäre?
Der, die, das, wer, wie. was ... wer nicht fragt bleibt dumm. :D
Benutzeravatar
Crizzo
Administrator
Administrator
Beiträge: 11954
Registriert: 19.05.2005 21:45
Kontaktdaten:

Re: [3.2] Welche Bewandtnis mit Twig?

Beitrag von Crizzo »

Hi,

Twig ist eine Template Engine, die Standardengine von Symfony (das PHP Framework was phpBB seit Version 3.1 nutzt). Siehe https://twig.symfony.com

Aktuell ist es so, dass phpBB intern die klassischen Template Angaben zu Twig umwandeln muss. Das kostet Rechenzeit, wenn man jetzt z. B. seine Extension bereits vorab umbaut, wird die Rechenzeit gespart.

Ergo ist zu erwarten, dass irgendwann Twig die aktuelle Syntax komplett ersetzt.

Grüße
Benutzeravatar
Tastenplayer
Mitglied
Beiträge: 2054
Registriert: 02.07.2010 19:35
Wohnort: Zuchwil/SO - Schweiz
Kontaktdaten:

Re: [3.2] Welche Bewandtnis mit Twig?

Beitrag von Tastenplayer »

ZNC hat geschrieben:In dem Thread Konverter für phpBB-Syntax in TWIG-Syntax las ich, dass vermutlich irgendwann die phpBB-Templatestruktur auf die Twig-php-Templateengine umgestellt werden. In dem prosilver-Style sind scheinbar schon um die 90 diesbezügliche Änderungen zu sehen.
Heißt das, dass bereits Twig greift? Warum eine andere Sprache, die dann zu erlernen wäre?
Da ich gesehen habe, dass im FTH_Tropic Style alle Templates mit % geschrieben sind, habe ich mal den Prosilverstyle von 3.2.1 unter die Lupe genommen. Jedoch in den Templates(navbar_footer/header, overall_footer/header) scheint alles beim Alten zu sein. Wo sollen diese Änderungen im Prosilver passiert sein?

Man ist nun etwas verunsichert. Soll man denn jetzt seinen Style konvertieren? Blicke da momentan nicht so ganz durch. Was soll diese Änderung bewirken? Wird der Style dadurch schneller?
Meine phpBB Styles & More
Be the best version of yourself rather than a bad copy of someone else!
Benutzeravatar
oxpus
Ehemaliges Teammitglied
Beiträge: 5389
Registriert: 03.02.2003 12:33
Wohnort: Bad Wildungen
Kontaktdaten:

Re: [3.2] Welche Bewandtnis mit Twig?

Beitrag von oxpus »

Tastenplayer hat geschrieben:[...]Soll man denn jetzt seinen Style konvertieren? Blicke da momentan nicht so ganz durch. Was soll diese Änderung bewirken? Wird der Style dadurch schneller?
Wenn Zeit dafür da ist, macht es Sinn, den Style der eigenen Extensions bereits jetzt in der Twig-Syntax aufzubauen, da diese zur Laufzeit deutlich schneller abgearbeitet werden (ich bin zur Zeit zu faul dazu, daher warte ich noch etwas ab, bzw. schiebe das noch vor mir her).
Allerdings nutzt das phpBB zur Zeit noch einen Cache für alle Template-Dateien so dass diese Konvertierung zur Laufzeit in der Regel nur einmal gemacht werden muss, da anschließend immer der Template-Cache verwendet wird.
Aber auch die Prüfung, ob sich eine Template-Datei erneuert hat, kostet ja auch Rechenzeit, abgesehen von einer dann nötigen neuen Konvertierung. Und die Cache-Dateien belegen zusätzlichen Speicherplatz auf dem Server (wobei das bei den aktuellen Webspace/Webserver-Angeboten kaum noch ins Gewicht fällt).

Ja, das phpBB selber nutzt aktuell noch die "alte" phpBB-Methoden in den Template-Dateien, aber ich denke, dass kann sich in einer der nächsten größeren Updates auch ändern und alle Forum-Styles könnten dann bereits in Twig ausgeliefert werden.
In wie weit dann weiterhin ein eingebauter "Konverter" für einen Cache vorhanden ist, um als "Übergangslösung" für Extension zu dienen, bleibt zur Zeit offen. Ich denke, für ein Release als Übergangszeit könnte das Sinn machen, aber wohl spätestens danach sollten auch alle Extension Template-Files nach Twig konvertiert sein, da hierdurch schlichtweg einiges an Rechenzeit eingespart werden kann.
Und letztlich wird dadurch ja auch die Ladezeit der Forum-Seiten verkürzt, was sich positiv für alle Nutzer auswirkt.

Kurzum:
Aktuell besteht noch kein akuter Handlungsbedarf, die eigenen Extension-Templates auf Twig zu konvertieren, aber nach und nach sollte man das dann doch tun, um später nicht alles auf einmal machen zu müssen (mir graut es jetzt schon davor, bei der Anzahl an Template-Dateien, die ich bereits erstellt habe).
Grüße
OXPUS
Kein Support bei unaufgeforderten PNs, E-Mails oder auf anderem Weg!!
Benutzeravatar
Tastenplayer
Mitglied
Beiträge: 2054
Registriert: 02.07.2010 19:35
Wohnort: Zuchwil/SO - Schweiz
Kontaktdaten:

Re: [3.2] Welche Bewandtnis mit Twig?

Beitrag von Tastenplayer »

oxpus hat geschrieben:(mir graut es jetzt schon davor, bei der Anzahl an Template-Dateien, die ich bereits erstellt habe).
Mit der Ext. von Hifikabin soll das ja nicht allzuschlimm sein 8)
Meine phpBB Styles & More
Be the best version of yourself rather than a bad copy of someone else!
Benutzeravatar
oxpus
Ehemaliges Teammitglied
Beiträge: 5389
Registriert: 03.02.2003 12:33
Wohnort: Bad Wildungen
Kontaktdaten:

Re: [3.2] Welche Bewandtnis mit Twig?

Beitrag von oxpus »

Werde ich sehen...
Grüße
OXPUS
Kein Support bei unaufgeforderten PNs, E-Mails oder auf anderem Weg!!
Benutzeravatar
Crizzo
Administrator
Administrator
Beiträge: 11954
Registriert: 19.05.2005 21:45
Kontaktdaten:

Re: [3.2] Welche Bewandtnis mit Twig?

Beitrag von Crizzo »

Hier noch ein Thema von phpBB.com, es erklärt den Unterschied zwischen phpBB Syntax und Twig.

https://www.phpbb.com/community/viewtop ... &t=2424606
ZNC
Mitglied
Beiträge: 229
Registriert: 21.05.2014 13:48
Wohnort: Köln

Re: [3.2] Welche Bewandtnis mit Twig?

Beitrag von ZNC »

@Crizzo, dann sind die Angaben, die ich als scheinbare Twig-Anpassungen im prosilver-Style und in den Sprachdateien gesehen habe, keine? Greift überhaupt Twig für Sprachdateien?

@Tastenplayer, das sind die, die ich meine und die ich in den Templates von prosilver gefunden hab:

Code: Alles auswählen

bbcode.html	<span style="font-size: {SIZE}%; line-height: 116%;">
navbar_footer.html	{% endspaceless %}
navbar_footer.html	{% spaceless %}
navbar_footer.html	{% endspaceless %}
navbar_footer.html	{% spaceless %}
overall_header.html	<link rel="alternate" type="application/atom+xml" title="{L_FEED} - {L_FEED_NEWS}" href="{{ path("phpbb_feed_news") }}">
overall_header.html	<link rel="alternate" type="application/atom+xml" title="{L_FEED} - {L_ALL_FORUMS}" href="{{ path("phpbb_feed_forums") }}">
overall_header.html	<link rel="alternate" type="application/atom+xml" title="{L_FEED} - {L_FEED_TOPICS_NEW}" href="{{ path("phpbb_feed_topics") }}">
overall_header.html	<link rel="alternate" type="application/atom+xml" title="{L_FEED} - {L_FEED_TOPICS_ACTIVE}" href="{{ path("phpbb_feed_topics_active") }}">
overall_header.html	<link rel="alternate" type="application/atom+xml" title="{L_FEED} - {L_FORUM} - {FORUM_NAME}" href="{{ path("phpbb_feed_forum", { forum_id : S_FORUM_ID } ) }}">
overall_header.html	<link rel="alternate" type="application/atom+xml" title="{L_FEED} - {L_TOPIC} - {TOPIC_TITLE}" href="{{ path("phpbb_feed_topic", { topic_id : S_TOPIC_ID } ) }}">
overall_header.html	<link rel="alternate" type="application/atom+xml" title="{L_FEED} - {SITENAME}" href="{{ path("phpbb_feed_index") }}">
plupload.html	"Uploaded %d/%d files": "{LA_PLUPLOAD_UPLOADED}",
plupload.html	"File: %s, size: %d, max file size: %d": "{LA_PLUPLOAD_FILE_DETAILS}",
ucp_pm_viewmessage.html	{% set REMAINDER=contact.S_ROW_COUNT % 4 %}
viewtopic_body.html	{% set REMAINDER=postrow.contact.S_ROW_COUNT % 4 %}
@oxpus,
Wenn Zeit dafür da ist, macht es Sinn, den Style der eigenen Extensions bereits jetzt in der Twig-Syntax aufzubauen, ...
das würde ja heißen, dass man derzeit zweigleisig fährt.

Lieben Dank Euch
Der, die, das, wer, wie. was ... wer nicht fragt bleibt dumm. :D
Benutzeravatar
Tastenplayer
Mitglied
Beiträge: 2054
Registriert: 02.07.2010 19:35
Wohnort: Zuchwil/SO - Schweiz
Kontaktdaten:

Re: [3.2] Welche Bewandtnis mit Twig?

Beitrag von Tastenplayer »

Crizzo hat geschrieben:Hier noch ein Thema von phpBB.com, es erklärt den Unterschied zwischen phpBB Syntax und Twig.

https://www.phpbb.com/community/viewtop ... &t=2424606
Danke - einige Sachen sind allerdings etwas schwer zu verstehen, wenn man nicht sattelfest mit dem Fachenglisch ist. Respektive man kann es auch falsch verstehen, wenn es nicht ganz korrekt von einem übersetzt wird.

@oxpus
Der Style FTH_Tropic scheint eben schon total mit Twig zu sein(jedenfalls die Template Dateien) - deshalb war ich verunsichert was ich jetzt mit meinen Styles machen soll.
https://www.phpbb.com/customise/db/style/fth_tropic/

@ZNC
Minimalistisch

Hier die vieforumbody_html vom Style FTH_Tropic die mich so verunsicherte

Code: Alles auswählen

{% INCLUDE 'overall_header.html' %}
{% EVENT viewforum_forum_title_before %}
<h2 class="forum-title">{% EVENT viewforum_forum_name_prepend %}<a href="{{ U_VIEW_FORUM }}">{{ FORUM_NAME }}</a>{% EVENT viewforum_forum_name_append %}</h2>
{% EVENT viewforum_forum_title_after %}
{% if FORUM_DESC or MODERATORS or U_MCP %}
<div>
	<!-- NOTE: remove the style="display: none" when you want to have the forum description on the forum body -->
	{% if FORUM_DESC %}<div style="display: none !important;">{{ FORUM_DESC }}<br /></div>{% endif %}
	{% if MODERATORS %}<p><strong>{% if S_SINGLE_MODERATOR %}{{ lang('MODERATOR') }}{% else %}{{ lang('MODERATORS') }}{% endif %}{{ lang('COLON') }}</strong> {{ MODERATORS }}</p>{% endif %}
</div>
{% endif %}

{% if S_FORUM_RULES %}
	<div class="rules{% if U_FORUM_RULES %} rules-link{% endif %}">
		<div class="inner">

		{% if U_FORUM_RULES %}
			<a href="{{ U_FORUM_RULES }}">{{ lang('FORUM_RULES') }}</a>
		{% else %}
			<strong>{{ lang('FORUM_RULES') }}</strong><br />
			{{ FORUM_RULES }}
		{% endif %}

		</div>
	</div>
{% endif %}

{% if S_HAS_SUBFORUM %}
{% if not S_IS_BOT and U_MARK_FORUMS %}
	<div class="action-bar compact">
		<a href="{{ U_MARK_FORUMS }}" class="mark-read rightside" data-ajax="mark_forums_read">{{ lang('MARK_SUBFORUMS_READ') }}</a>
	</div>
{% endif %}
	{% INCLUDE 'forumlist_body.html' %}
{% endif %}

{% if S_DISPLAY_POST_INFO or loops.pagination|length or TOTAL_POSTS or TOTAL_TOPICS %}
	<div class="action-bar bar-top">

	{% if not S_IS_BOT and S_DISPLAY_POST_INFO %}
			{% EVENT viewforum_buttons_top_before %}

		<a href="{{ U_POST_NEW_TOPIC }}" class="button" title="{% if S_IS_LOCKED %}{{ lang('FORUM_LOCKED') }}{% else %}{{ lang('POST_TOPIC') }}{% endif %}">
			{% if S_IS_LOCKED %}
				<span>{{ lang('BUTTON_FORUM_LOCKED') }}</span> <i class="icon fa-lock fa-fw" aria-hidden="true"></i>
			{% else %}
				<span>{{ lang('BUTTON_NEW_TOPIC') }}</span> <i class="icon fa-pencil fa-fw" aria-hidden="true"></i>
			{% endif %}
		</a>
			{% EVENT viewforum_buttons_top_after %}
	{% endif %}

	{% if S_DISPLAY_SEARCHBOX %}
		<div class="search-box" role="search">
			<form method="get" id="forum-search" action="{{ S_SEARCHBOX_ACTION }}">
			<fieldset>
				<input class="inputbox search tiny" type="search" name="keywords" id="search_keywords" size="20" placeholder="{{ lang('SEARCH_FORUM') }}" />
				<button class="button button-search" type="submit" title="{{ lang('SEARCH') }}">
					<i class="icon fa-search fa-fw" aria-hidden="true"></i><span class="sr-only">{{ lang('SEARCH') }}</span>
				</button>
				<a href="{{ U_SEARCH }}" class="button button-search-end" title="{{ lang('SEARCH_ADV') }}">
					<i class="icon fa-cog fa-fw" aria-hidden="true"></i><span class="sr-only">{{ lang('SEARCH_ADV') }}</span>
				</a>
				{{ S_SEARCH_LOCAL_HIDDEN_FIELDS }}
			</fieldset>
			</form>
		</div>
	{% endif %}

	<div class="pagination">
		{% if not S_IS_BOT and U_MARK_TOPICS and loops.topicrow|length %}<a href="{{ U_MARK_TOPICS }}" class="mark" accesskey="m" data-ajax="mark_topics_read">{{ lang('MARK_TOPICS_READ') }}</a> &bull; {% endif %}
		{{ TOTAL_TOPICS }}
		{% if loops.pagination|length %}
			{% INCLUDE 'pagination.html' %}
		{% else %}
			&bull; {{ PAGE_NUMBER }}
		{% endif %}
	</div>

	</div>
{% endif %}

{% if S_NO_READ_ACCESS %}

	<div class="panel">
		<div class="inner">
		<strong>{{ lang('NO_READ_ACCESS') }}</strong>
		</div>
	</div>

	{% if not S_USER_LOGGED_IN and not S_IS_BOT %}

		<form action="{{ S_LOGIN_ACTION }}" method="post">

		<div class="panel">
			<div class="inner">

			<div class="content">
				<h3><a href="{{ U_LOGIN_LOGOUT }}">{{ lang('LOGIN_LOGOUT') }}</a>{% if S_REGISTER_ENABLED %}&nbsp; &bull; &nbsp;<a href="{{ U_REGISTER }}">{{ lang('REGISTER') }}</a>{% endif %}</h3>

				<fieldset class="fields1">
				<dl>
					<dt><label for="username">{{ lang('USERNAME') }}{{ lang('COLON') }}</label></dt>
					<dd><input type="text" tabindex="1" name="username" id="username" size="25" value="{{ USERNAME }}" class="inputbox autowidth" /></dd>
				</dl>
				<dl>
					<dt><label for="password">{{ lang('PASSWORD') }}{{ lang('COLON') }}</label></dt>
					<dd><input type="password" tabindex="2" id="password" name="password" size="25" class="inputbox autowidth" autocomplete="off" /></dd>
					{% if S_AUTOLOGIN_ENABLED %}<dd><label for="autologin"><input type="checkbox" name="autologin" id="autologin" tabindex="3" /> {{ lang('LOG_ME_IN') }}</label></dd>{% endif %}
					<dd><label for="viewonline"><input type="checkbox" name="viewonline" id="viewonline" tabindex="4" /> {{ lang('HIDE_ME') }}</label></dd>
				</dl>
				<dl>
					<dt>&nbsp;</dt>
					<dd><input type="submit" name="login" tabindex="5" value="{{ lang('LOGIN') }}" class="button1" /></dd>
				</dl>
				{{ S_LOGIN_REDIRECT }}
				</fieldset>
			</div>

			</div>
		</div>

		</form>

	{% endif %}

{% endif %}

{% EVENT viewforum_body_topic_row_before %}

{% for topicrow in loops.topicrow %}

	{% if not topicrow.S_TOPIC_TYPE_SWITCH and not topicrow.S_FIRST_ROW %}
		</ul>
		</div>
	</div>
	{% endif %}

	{% if topicrow.S_FIRST_ROW or not topicrow.S_TOPIC_TYPE_SWITCH %}
		<div class="forumbg{% if topicrow.S_TOPIC_TYPE_SWITCH and (topicrow.S_POST_ANNOUNCE or topicrow.S_POST_GLOBAL) %} announcement{% endif %}">
		<div class="inner">
		<ul class="topiclist">
			<li class="header">
				<dl class="row-item">
					<dt{% if S_DISPLAY_ACTIVE %} id="active_topics"{% endif %}><div class="list-inner">{% if S_DISPLAY_ACTIVE %}{{ lang('ACTIVE_TOPICS') }}{% elseif topicrow.S_TOPIC_TYPE_SWITCH and (topicrow.S_POST_ANNOUNCE or topicrow.S_POST_GLOBAL) %}{{ lang('ANNOUNCEMENTS') }}{% else %}{{ lang('TOPICS') }}{% endif %}</div></dt>
					<dd class="posts">{{ lang('REPLIES') }}</dd>
					<dd class="views">{{ lang('VIEWS') }}</dd>
					<dd class="lastpost"><span>{{ lang('LAST_POST') }}</span></dd>
				</dl>
			</li>
		</ul>
		<ul class="topiclist topics">
	{% endif %}

		{% EVENT viewforum_body_topicrow_row_before %}
		<li class="row{% if topicrow.S_ROW_COUNT is even %} bg1{% else %} bg2{% endif %}{% if topicrow.S_POST_GLOBAL %} global-announce{% endif %}{% if topicrow.S_POST_ANNOUNCE %} announce{% endif %}{% if topicrow.S_POST_STICKY %} sticky{% endif %}{% if topicrow.S_TOPIC_REPORTED %} reported{% endif %}">
			{% EVENT viewforum_body_topic_row_prepend %}
			<dl class="row-item {{ topicrow.TOPIC_IMG_STYLE }}">
				<dt{% if topicrow.TOPIC_ICON_IMG and S_TOPIC_ICONS %} style="background-image: url({{ T_ICONS_PATH }}{{ topicrow.TOPIC_ICON_IMG }}); background-repeat: no-repeat;"{% endif %} title="{{ topicrow.TOPIC_FOLDER_IMG_ALT }}">
					{% if topicrow.S_UNREAD_TOPIC and not S_IS_BOT %}<a href="{{ topicrow.U_NEWEST_POST }}" class="row-item-link"></a>{% endif %}
					<div class="list-inner">
						{% EVENT topiclist_row_prepend %}
						{% if topicrow.S_UNREAD_TOPIC and not S_IS_BOT %}
							<a class="unread" href="{{ topicrow.U_NEWEST_POST }}">
								<i class="icon fa-file fa-fw icon-red icon-md" aria-hidden="true"></i><span class="sr-only">{{ NEW_POST }}</span>
							</a>
						{% endif %}
						<a href="{{ topicrow.U_VIEW_TOPIC }}" class="topictitle">{{ topicrow.TOPIC_TITLE }}</a>
						{% if topicrow.S_TOPIC_UNAPPROVED or topicrow.S_POSTS_UNAPPROVED %}
							<a href="{{ topicrow.U_MCP_QUEUE }}" title="{{ lang('TOPIC_UNAPPROVED') }}">
								<i class="icon fa-question fa-fw icon-blue" aria-hidden="true"></i><span class="sr-only">{{ lang('TOPIC_UNAPPROVED') }}</span>
							</a>
						{% endif %}
						{% if topicrow.S_TOPIC_DELETED %}
							<a href="{{ topicrow.U_MCP_QUEUE }}" title="{{ lang('TOPIC_DELETED') }}">
								<i class="icon fa-recycle fa-fw icon-green" aria-hidden="true"></i><span class="sr-only">{{ lang('TOPIC_DELETED') }}</span>
							</a>
						{% endif %}
						{% if topicrow.S_TOPIC_REPORTED %}
							<a href="{{ topicrow.U_MCP_REPORT }}" title="{{ lang('TOPIC_REPORTED') }}">
								<i class="icon fa-exclamation fa-fw icon-red" aria-hidden="true"></i><span class="sr-only">{{ lang('TOPIC_REPORTED') }}</span>
							</a>
						{% endif %}
						<br />
						{% EVENT topiclist_row_topic_title_after %}

						{% if not S_IS_BOT %}
						<div class="responsive-show" style="display: none;">
							{{ lang('LAST_POST') }} {{ lang('POST_BY_AUTHOR') }} {{ topicrow.LAST_POST_AUTHOR_FULL }} &laquo; <a href="{{ topicrow.U_LAST_POST }}" title="{{ lang('GOTO_LAST_POST') }}">{{ topicrow.LAST_POST_TIME }}</a>
							{% if topicrow.S_POST_GLOBAL and FORUM_ID != topicrow.FORUM_ID %}<br />{{ lang('POSTED') }} {{ lang('IN') }} <a href="{{ topicrow.U_VIEW_FORUM }}">{{ topicrow.FORUM_NAME }}</a>{% endif %}
						</div>
							{% if topicrow.REPLIES %}
							<span class="responsive-show" style="display: none;">{{ lang('REPLIES') }}{{ lang('COLON') }} <strong>{{ topicrow.REPLIES }}</strong></span>
							{% endif %}
						{% endif %}

						<div class="topic-poster responsive-hide">
							{% if topicrow.S_HAS_POLL %}<i class="icon fa-bar-chart fa-fw" aria-hidden="true"></i>{% endif %}
							{% if topicrow.ATTACH_ICON_IMG %}<i class="icon fa-paperclip fa-fw" aria-hidden="true"></i>{% endif %}
							{{ lang('POST_BY_AUTHOR') }} {{ topicrow.TOPIC_AUTHOR_FULL }} &raquo; {{ topicrow.FIRST_POST_TIME }}
							{% if topicrow.S_POST_GLOBAL and FORUM_ID != topicrow.FORUM_ID %} &raquo; {{ lang('IN') }} <a href="{{ topicrow.U_VIEW_FORUM }}">{{ topicrow.FORUM_NAME }}</a>{% endif %}
						</div>

						{% if topicrow.pagination|length %}
						<div class="pagination">
							<span><i class="icon fa-clone fa-fw" aria-hidden="true"></i></span>
							<ul>
							{% for pagination in topicrow.pagination %}
								{% if pagination.S_IS_PREV %}
								{% elseif pagination.S_IS_CURRENT %}<li class="active"><span>{{ pagination.PAGE_NUMBER }}</span></li>
								{% elseif pagination.S_IS_ELLIPSIS %}<li class="ellipsis"><span>{{ lang('ELLIPSIS') }}</span></li>
								{% elseif pagination.S_IS_NEXT %}
								{% else %}<li><a class="button" href="{{ pagination.PAGE_URL }}">{{ pagination.PAGE_NUMBER }}</a></li>
								{% endif %}
							{% endfor %}
							</ul>
						</div>
						{% endif %}

						{% EVENT topiclist_row_append %}
					</div>
				</dt>
				<dd class="posts"><span class="badge count">{{ topicrow.REPLIES }}</span> <dfn>{{ lang('REPLIES') }}</dfn></dd>
				<dd class="views"><span class="badge count">{{ topicrow.VIEWS }}</span> <dfn>{{ lang('VIEWS') }}</dfn></dd>
				<dd class="lastpost">
					<span><dfn>{{ lang('LAST_POST') }} </dfn>{{ lang('POST_BY_AUTHOR') }} {{ topicrow.LAST_POST_AUTHOR_FULL }}
						{% if not S_IS_BOT %}
							<a href="{{ topicrow.U_LAST_POST }}" title="{{ lang('GOTO_LAST_POST') }}">
								<i class="icon fa-external-link-square fa-fw icon-lightgray icon-md" aria-hidden="true"></i><span class="sr-only">{{ VIEW_LATEST_POST }}</span>
							</a>
						{% endif %}
						<br />{{ topicrow.LAST_POST_TIME }}
					</span>
				</dd>
			</dl>
			{% EVENT viewforum_body_topic_row_append %}
		</li>
		{% EVENT viewforum_body_topic_row_after %}

	{% if topicrow.S_LAST_ROW %}
			</ul>
		</div>
	</div>
	{% endif %}

{% else %}
	{% if S_IS_POSTABLE %}
	<div class="panel">
		<div class="inner">
		<strong>{{ lang('NO_TOPICS') }}</strong>
		</div>
	</div>
	{% endif %}
{% endfor %}

{% if loops.topicrow|length and not S_DISPLAY_ACTIVE %}
	<div class="action-bar bar-bottom">
		{% if not S_IS_BOT and S_DISPLAY_POST_INFO %}
			{% EVENT viewforum_buttons_bottom_before %}

			<a href="{{ U_POST_NEW_TOPIC }}" class="button" title="{% if S_IS_LOCKED %}{{ lang('FORUM_LOCKED') }}{% else %}{{ lang('POST_TOPIC') }}{% endif %}">
			{% if S_IS_LOCKED %}
				<span>{{ lang('BUTTON_FORUM_LOCKED') }}</span> <i class="icon fa-lock fa-fw" aria-hidden="true"></i>
			{% else %}
				<span>{{ lang('BUTTON_NEW_TOPIC') }}</span> <i class="icon fa-pencil fa-fw" aria-hidden="true"></i>
			{% endif %}
			</a>

			{% EVENT viewforum_buttons_bottom_after %}
		{% endif %}

		{% if S_SELECT_SORT_DAYS and not S_IS_BOT %}
			<form method="post" action="{{ S_FORUM_ACTION }}">
			{% INCLUDE 'display_options.html' %}
			</form>
		{% endif %}

		<div class="pagination">
			{% if not S_IS_BOT and U_MARK_TOPICS and loops.topicrow|length %}<a href="{{ U_MARK_TOPICS }}" data-ajax="mark_topics_read">{{ lang('MARK_TOPICS_READ') }}</a> &bull; {% endif %}
			{{ TOTAL_TOPICS }}
			{% if loops.pagination|length %}
				{% INCLUDE 'pagination.html' %}
			{% else %}
				 &bull; {{ PAGE_NUMBER }}
			{% endif %}
		</div>
	</div>
{% endif %}

{% INCLUDE 'jumpbox.html' %}

{% if S_DISPLAY_ONLINE_LIST and U_VIEWONLINE %}
	<div class="stat-block online-list">
		<h3><a href="{{ U_VIEWONLINE }}">{{ lang('WHO_IS_ONLINE') }}</a></h3>
		<p>{{ LOGGED_IN_USER_LIST }}</p>
	</div>
{% endif %}

{% if S_DISPLAY_POST_INFO %}
	<div class="stat-block permissions">
		<h3>{{ lang('FORUM_PERMISSIONS') }}</h3>
		<p>{% for rules in loops.rules %}{{ rules.RULE }}<br />{% endfor %}</p>
	</div>
{% endif %}

{% INCLUDE 'overall_footer.html' %}
Meine phpBB Styles & More
Be the best version of yourself rather than a bad copy of someone else!
Benutzeravatar
canonknipser
Ehemaliges Teammitglied
Beiträge: 2053
Registriert: 10.09.2011 11:14
Kontaktdaten:

Re: [3.2] Welche Bewandtnis mit Twig?

Beitrag von canonknipser »

Tastenplayer hat geschrieben:Mit der Ext. von Hifikabin soll das ja nicht allzuschlimm sein
Na ja, es war kasimi
ZNC hat geschrieben:das würde ja heißen, dass man derzeit zweigleisig fährt.
Ja, in der template-Dateien sind aktuell sowohl die klassische phpBB-Syntax als auch die TWIG-Syntax parallel zugelassen. Anscheinend wurde bei einigen Änderungen in core-prosilver-Dateien davon auch schon Gebrauch gemacht.
Crizzo hat geschrieben:Aktuell ist es so, dass phpBB intern die klassischen template-Angaben zu Twig umwandeln muss. Das kostet Rechenzeit,
Nicht nur das, macht es auch fehleranfällig, z.B.:
Grüße, canonknipser
"there are only 10 types of people: those, who understand binary and those, who don't"
just arrived ;) - Bilder
Kein Support via PN, nur im Board und (manchmal) im IRC
Antworten

Zurück zu „Styles, Templates und Grafiken“