Use custom forum images.

Guides & Snippets for phpBB3. Try the Snippets here and share Your own Snippets
There is no support here! Only Read Access!
User avatar
Steve
BBCoder VI
BBCoder VI
Posts: 814
Joined: 05 Mar 2010, 01:10
BBCodes: 2000
Favourite BBCode: p**n tube
Favourite MOD: Non of Stokers

Use custom forum images.

Post by Steve »

Description:
Removes the standard forum icons from index page and allows you to use custom images more in theme with your forum.
Recomended snippet coloured Unread Forums and Topics : viewtopic.php?f=9&t=648
instructions
Open styles/prosilver/template/forumlist_body.html
find:

Code: Select all

<li class="header">
					<dl class="icon">
replace with:

Code: Select all

<li class="header">
					<!-- IF SCRIPT_NAME == "index" --><dl class="no_icon"><!-- ELSE --><dl class="icon"><!-- ENDIF -->
find:

Code: Select all

<dl class="icon" style="background-image: url({forumrow.FORUM_FOLDER_IMG_SRC}); background-repeat: no-repeat;">
replace with:

Code: Select all

<!-- IF SCRIPT_NAME == "index" --><dl class="no_icon"><!-- ELSE --><dl class="icon" style="background-image: url({forumrow.FORUM_FOLDER_IMG_SRC}); background-repeat: no-repeat;"><!-- ENDIF -->
Open styes/prosilver/theme/content.css
find:

Code: Select all

dl.icon dt {
	padding-left: 45px;					/* Space for folder icon */
	background-repeat: no-repeat;
	background-position: 5px 95%;		/* Position of topic icon */
}
add after:

Code: Select all

dl.no_icon dt {
	padding-left: -45px;					
	background-repeat: no-repeat;
}
Refresh template and theme in acpanel for prosilver.
fixed.PNG
before.PNG
after.PNG
*Update instructions for allignment bug and to remove coloured notification:
[spoiler]Open styles/prosilver/template/forumlist_body.html
find:

Code: Select all

<li class="header">
					<dl class="icon">
replace with:

Code: Select all

<li class="header">
					<!-- IF SCRIPT_NAME == "index" --><dl class="no_icon"><!-- ELSE --><dl class="icon"><!-- ENDIF -->
Find:

Code: Select all

<!-- IF forumrow.S_UNREAD_FORUM --><a href="{forumrow.U_VIEWFORUM}" class="forumtitle" style="color:#FF0000;">{forumrow.FORUM_NAME}</a><!-- ELSE --><a href="{forumrow.U_VIEWFORUM}" class="forumtitle">{forumrow.FORUM_NAME}</a><!-- ENDIF --><br />
Replace with:

Code: Select all

<a href="{forumrow.U_VIEWFORUM}" class="forumtitle">{forumrow.FORUM_NAME}</a><br />
Open styes/prosilver/theme/content.css
find:

Code: Select all

dl.icon dt {
	padding-left: 45px;					/* Space for folder icon */
	background-repeat: no-repeat;
	background-position: 5px 95%;		/* Position of topic icon */
}
add after:

Code: Select all

dl.no_icon dt {
	padding-left: -45px;					
	background-repeat: no-repeat;
}

This parts to remove coloured forum title notification.
find:

Code: Select all

<!-- IF SCRIPT_NAME == "index" --><dl><!-- ELSE --><dl class="icon" style="background-image: url({forumrow.FORUM_FOLDER_IMG_SRC}); background-repeat: no-repeat;"><!-- ENDIF -->
replace with:

Code: Select all

<!-- IF SCRIPT_NAME == "index" --><dl class="no_icon"><!-- ELSE --><dl class="icon" style="background-image: url({forumrow.FORUM_FOLDER_IMG_SRC}); background-repeat: no-repeat;"><!-- ENDIF -->
Now use this coloured Unread Forums and Topics : http://www.phpbb3bbcodes.com[/spoiler]

prosilver instructions only,subsilver2 upon request.
You add your forum image in admin control panel here
forum image.PNG
heredia21 » 15 Apr 2010, 17:55 wrote:Ok. But about the forum image how can I text centered with image.
Sorry cant achieve that with the layout of the html for forum name and description etc.
NAPWR wrote: Nice, Stoker is Hot
download/file.php?id=2327&mode=view
User avatar
Stoker
Site Admin
Site Admin
Posts: 3525
Joined: 12 May 2008, 23:26
BBCodes: 239
Favourite BBCode: Anipro
Favourite MOD: PrettyPhoto
Location: Denmark
Contact:

Re: Use custom forum images and coloured notification.

Post by Stoker »

Nice one ninja.
You can do lots of different stuff instead of using a color.
Board rules! No PM support
User avatar
Steve
BBCoder VI
BBCoder VI
Posts: 814
Joined: 05 Mar 2010, 01:10
BBCodes: 2000
Favourite BBCode: p**n tube
Favourite MOD: Non of Stokers

Re: Use custom forum images and coloured notification.

Post by Steve »

like flying ducks or summit.Want to keep it simple its a snippet ;)
NAPWR wrote: Nice, Stoker is Hot
download/file.php?id=2327&mode=view
cisco007
BBCoder VI
BBCoder VI
Posts: 1015
Joined: 16 Mar 2010, 18:14
Location: Don't really know!

Re: Use custom forum images and coloured notification.

Post by cisco007 »

yeah, i am pretty sure many people would want something like this!
User avatar
Inner Circle
BBCoder III
BBCoder III
Posts: 107
Joined: 20 Mar 2010, 20:25
Location: Germany
Contact:

Re: Use custom forum images and coloured notification.

Post by Inner Circle »

Looks good!
Denny
BBCoder II
BBCoder II
Posts: 29
Joined: 10 Mar 2010, 17:48

Re: Use custom forum images and coloured notification.

Post by Denny »

Nice feature. My subsilver2 already has this feature, but some people may not be aware of it being there.
User avatar
Steve
BBCoder VI
BBCoder VI
Posts: 814
Joined: 05 Mar 2010, 01:10
BBCodes: 2000
Favourite BBCode: p**n tube
Favourite MOD: Non of Stokers

Re: Use custom forum images and coloured notification.

Post by Steve »

where? yes you can use custom forum images with prosilver but this removes the normal forum icon
NAPWR wrote: Nice, Stoker is Hot
download/file.php?id=2327&mode=view
Denny
BBCoder II
BBCoder II
Posts: 29
Joined: 10 Mar 2010, 17:48

Re: Use custom forum images and coloured notification.

Post by Denny »

In your third picture above, is the same as what I see in subsilver2
User avatar
Steve
BBCoder VI
BBCoder VI
Posts: 814
Joined: 05 Mar 2010, 01:10
BBCodes: 2000
Favourite BBCode: p**n tube
Favourite MOD: Non of Stokers

Re: Use custom forum images and coloured notification.

Post by Steve »

oh well thats just there for members who dont know its there,or dont know how to add forum images ;)
NAPWR wrote: Nice, Stoker is Hot
download/file.php?id=2327&mode=view
User avatar
Sir Xiradorn
BBCoder II
BBCoder II
Posts: 10
Joined: 08 Mar 2010, 11:36
Location: MMM....i don't know.....
Contact:

Re: Use custom forum images and coloured notification.

Post by Sir Xiradorn »

Wery good work.....i had add a small addon to colour also the unread topic title
In viewforum_body.html i modified this

Code: Select all

<a href="{topicrow.U_VIEW_TOPIC}" class="topictitle">{topicrow.TOPIC_TITLE}</a>
in this way

Code: Select all

<a href="{topicrow.U_VIEW_TOPIC}"<!-- IF topicrow.S_UNREAD_TOPIC -->style="color:#FF0000;"<!-- ENDIF --> class="topictitle">{topicrow.TOPIC_TITLE}</a>
EN language torturer :twisted:
Admin Leader & Founder of: Xiradorn Lab - www.xiradorn.it
Locked