Block "Bekanntmachungen" tunen [1.1.0b]

Forum für das phpBB3 Portal von
phpbb3portal.com (Version 1.1.0b) - kein Support mehr für das phpbb3portal
User avatar

Topic author
Kevin
Site Admin
Posts: 2994
Joined: 7. January 2006 21:11
phpBB.de User: Saint
phpBB.com User: Saint_hh
Location: Hamburg

Block "Bekanntmachungen" tunen [1.1.0b]

Post by Kevin »

Eine Überarbeitung der Bekanntmachungen.
Achtung: funktioniert nur im "kompakten Block Style"!
bekanntmachungen.gif
Öffne styles/prosilver/template/portal/block/announcements_compact.html
suche:

Code: Select all

<img src="{T_THEME_PATH}/images/arrow_right.gif" /> 
						<a href="{announcements_row.U_VIEW_COMMENTS}"><strong style="font-size:1.1em;">{announcements_row.TITLE}</strong></a>
						<br style="clear:both" />
						<span style="float: left;">
							<a href="{announcements_row.U_VIEW_COMMENTS}" title="{L_VIEW_COMMENTS}"><span style="font-size:0.9em;"><em>{L_COMMENTS}: {announcements_row.REPLIES}</em></span></a>
							<span style="font-size:0.9em;"><em>{L_TOPIC_VIEWS}: {announcements_row.TOPIC_VIEWS}</em></span>
						</span>
						<span style="float: right;">{announcements_row.TIME}</span>
						<br />
ersetze durch:

Code: Select all

						<span style="float: left;"><img src="{T_THEME_PATH}/images/arrow_right.gif" /> 
						<!-- <a href="{announcements_row.U_VIEW_COMMENTS}"><strong style="font-size:1.1em;">{announcements_row.TITLE}</strong></a> -->
						<a href="{announcements_row.U_VIEW_COMMENTS}" title="Zur Bekanntmachung"><strong style="font-size:1.1em;">{announcements_row.TITLE}</strong></a></span>
						<span style="float: right;">Letzter Beitrag von: <strong><a href="{announcements_row.U_USER_PROFILE}">{announcements_row.POSTER}</a></strong></span>
						<br style="clear:both" />
						<span style="float: left;">
							<a href="{announcements_row.U_VIEW_COMMENTS}" title="{L_VIEW_COMMENTS}"><span style="font-size:0.9em;"><em>{L_COMMENTS}: {announcements_row.REPLIES}</em></span></a>
							<span style="font-size:0.9em;"><em>{L_TOPIC_VIEWS}: {announcements_row.TOPIC_VIEWS}</em></span>
						</span>
						<span style="float: right;">{announcements_row.TIME}</span>
						<hr />

Den folgenden Abschnitt kann man ignorieren, wenn man bereits die Modifizierung Block "aktuelle Beiträge" tunen [1.1.0b] vorgenommen hat.

Öffne /portal/includes/functions.php
suche:

Code: Select all

   $sql = 'SELECT
            t.forum_id,
            t.topic_id,
            t.topic_last_post_id,
            t.topic_time,
            t.topic_title,
            t.topic_attachment,
            t.topic_views,
            t.poll_title,
            t.topic_replies,
            t.forum_id,
            t.topic_poster,
            u.username,
            u.user_id,
            u.user_type,
            u.user_colour,
            p.post_id,
            p.post_text,
            p.post_attachment,
            p.enable_smilies,
            p.enable_bbcode,
            p.enable_magic_url,
            p.bbcode_bitfield,
            p.bbcode_uid
        FROM
            ' . TOPICS_TABLE . ' AS t,
            ' . USERS_TABLE . ' AS u,
            ' . POSTS_TABLE . ' AS p
        WHERE
            ' . $topic_type . '
            ' . $from_forum . '
            ' . $post_time . '
            t.topic_poster = u.user_id AND
            t.topic_first_post_id = p.post_id AND
            t.topic_status <> 2 AND
            t.topic_approved = 1
und ersetze durch:

Code: Select all

    $sql = 'SELECT
            t.forum_id,
            t.topic_id,
            t.topic_last_post_id,
            t.topic_last_post_time,
            t.topic_title,
            t.topic_attachment,
            t.topic_views,
            t.poll_title,
            t.topic_replies,
            t.forum_id,
            t.topic_last_poster_id,
            u.username,
            u.user_id,
            u.user_type,
            u.user_colour,
            p.post_id,
            p.post_text,
            p.post_attachment,
            p.enable_smilies,
            p.enable_bbcode,
            p.enable_magic_url,
            p.bbcode_bitfield,
            p.bbcode_uid
        FROM
            ' . TOPICS_TABLE . ' AS t,
            ' . USERS_TABLE . ' AS u,
            ' . POSTS_TABLE . ' AS p
        WHERE
            ' . $topic_type . '
            ' . $from_forum . '
            ' . $post_time . '
            t.topic_last_poster_id = u.user_id AND
            t.topic_first_post_id = p.post_id AND
            t.topic_status <> 2 AND
            t.topic_approved = 1
suche:

Code: Select all

$posts[$i]['topic_time'] = $user->format_date($row['topic_time']);                         
und ersetze durch:

Code: Select all

$posts[$i]['topic_time'] = $user->format_date($row['topic_last_post_time']);                         
You do not have the required permissions to view the files attached to this post.
~~~ They say the definition of madness is doing the same thing and expecting a different result ~~~

Kein Support per PN / No support via PM!
User avatar

Redbull254
Former Team Member
Posts: 693
Joined: 19. January 2006 23:50
Location: Kamen

Re: Block "Bekanntmachungen" tunen [1.1.0b]

Post by Redbull254 »

Hallo, Kevin ;-)

klappt wie nicht anders zu erwarten, perfekt. :!:

Änderungen sind alle Valid XHTML 1.0 Strict!
LG
Walter

"Klug ist nicht, wer keine Fehler macht. Klug ist der, der es versteht, sie zu korrigieren."

Return to “phpBB3 Portal”