Advertisement:

Author Topic: Board Icons  (Read 33114 times)

Offline Dream Portal Team

  • Semi-Newbie
  • *
  • Posts: 89
    • Dream Portal
Board Icons
« on: February 01, 2013, 04:04:22 PM »
Link to Mod

This Mod allows you to have different Icons for your Boards when modifying your boards through the SMF Admin.  You can select No New Post Icons, New Post Icons, and even Redirect Icons.  There are several paths to choose from and you can even supply outside links for these icons that can represent your Boards.  You can supply icons for Child Boards as well.

There are 5 different path options to choose from:

http:// = This points to any URL that you want (can point to a url on your forum or on any other site).

{$boardurl} = Points to the url that is your SMF ROOT URL where SMF is installed.

{$scripturl} = Points to your SMF ROOT URL + index.php so you can apply actions to the url if need be (this was decided to be added, in case your $boardurl path is not within your $scripturl path, for security or any other reason(s)).

Default Theme = This path will always point to the default SMF CURVE Theme (./Themes/default/).

This Theme = This path points to whatever Theme the user has selected within their profile (wasn't thinking at the time when I decided on the name for this, but will most likely change in the future to Theme Specific instead).  The Great thing about the "This Theme" path, is that you can have different images for different themes, as long as they are along the same path for each theme, and have the same filename.

FYI:  This Mod was created a long time ago, back in 2011 and was offered to members of DP.net for having high post counts, however, I think it would be more useful for everyone to enjoy this mod!

ENJOY
This is the universal account for the Dream Portal Team. All messages sent to this account will be discarded.  Please visit us at:  Dream Portal dot net for support and extensions to Dream Portal.

Offline tMicky

  • Jr. Member
  • **
  • Posts: 146
  • Gender: Female
Re: Board Icons
« Reply #1 on: May 12, 2013, 08:12:58 AM »
Hello, where is the settings to activate this mod and select the images.

thanks

Offline Dream Portal Team

  • Semi-Newbie
  • *
  • Posts: 89
    • Dream Portal
Re: Board Icons
« Reply #2 on: May 17, 2013, 03:41:53 AM »
This Mods settings are located within the SMF Admin Boards section.  To see them you will either "Add" a New Board, or "Modify" an existing board.
This is the universal account for the Dream Portal Team. All messages sent to this account will be discarded.  Please visit us at:  Dream Portal dot net for support and extensions to Dream Portal.

Offline fatyhxd41

  • Jr. Member
  • **
  • Posts: 110
Re: Board Icons
« Reply #3 on: August 24, 2013, 05:01:27 PM »
Hi. Thanks for this useful mod but I cannot see option to add images. I'm using SMF 2.0.5 and at the moment this mod don't support 2.0.5. Just supports until 2.0.4. This is because of I cannot see option to add images? If yes, please do support for 2.0.5.

Offline Arantor

  • Resident Overthinker
  • SMF Friend
  • SMF Legend
  • *
  • Posts: 69,088
    • StoryBB/StoryBB on GitHub
Re: Board Icons
« Reply #4 on: August 24, 2013, 05:02:41 PM »
All mods for 2.0.4 will work on 2.0.5 - as per How can I install a mod that doesn't work in my SMF version?

If it's not showing up that probably means it didn't install properly.
Don’t try to tell me that some power can corrupt a person. You haven’t had enough to know what it’s like.

Nothing turns to hate so bitter as what once was love.

Offline Burke ♞ Knight

  • SMF Hero
  • ******
  • Posts: 3,534
Re: Board Icons
« Reply #5 on: August 27, 2013, 01:44:04 AM »
Installed this on new site I'm working on.
Perfect idea for boards that are for certain games, etc.

However, I set it up, and the default icons still show.
Cleared file cache, browser cache, and tried 4 different browsers.
Still not showing custom icon for board.

Any ideas?

Web Site

Look at the GTA category, Grand Theft Auto I is edited for the custom icon. Should be showing:

Offline SoLoGHoST

  • SMF Hero
  • ******
  • Posts: 1,796
  • Gender: Male
  • Real coders do not need to comment their code!
    • Dream Portal
Re: Board Icons
« Reply #6 on: August 28, 2013, 11:50:27 PM »
I have a few ideas.  First idea is use Dream Portal on your site and it will look way better...lol.  But to each their own!

2nd idea I have is A.  I haven't tested this mod in SMF 2.0.5 yet, and B. What are your settings for the Boards?  Image of settings would be most appropriate and easier to debug.  and finally, C - 2 Part Question:  If you are using image paths, do the images exist?  Are you using Default Theme or Theme Specific for the select box?

Again, Image of settings would be most appropriate!

Offline Burke ♞ Knight

  • SMF Hero
  • ******
  • Posts: 3,534
Re: Board Icons
« Reply #7 on: August 28, 2013, 11:57:45 PM »
The image I posted is where the mod is supposed to be finding the image, so yes, it does exist. (Even I wondered if this was case, with how servers are at times...LOL )

Attached is screeshot of settings for the one board that should be using the posted image.

Offline SoLoGHoST

  • SMF Hero
  • ******
  • Posts: 1,796
  • Gender: Male
  • Real coders do not need to comment their code!
    • Dream Portal
Re: Board Icons
« Reply #8 on: August 29, 2013, 12:25:45 AM »
Use {$boardurl} in your situation.  Image attached of how to set it up.  Also, if the images do not exist upon saving of the form, it will not update the Board with those images, instead it will clear the Image Board Settings.

Also, it will work if you add http:// to the beginning of www.burkeknight.com/images/yourimage.gif

Just cause the select box says http:// in it, doesn't mean you should exclude that from the URL.  If it is http:// in the select box, you will need to also have it's value start off with http://

Offline Burke ♞ Knight

  • SMF Hero
  • ******
  • Posts: 3,534
Re: Board Icons
« Reply #9 on: August 29, 2013, 12:33:35 AM »
Nope. Still only showing the default.

Guess it does not work with 2.0.5 for some reason.

Even tried to go with default theme to test, and that shows the default theme's image.

P.S. As for Dream Portal, would give it a try, but so used to SP, and it's pages....LOL

If include the http:// it auto-removes it.

Offline SoLoGHoST

  • SMF Hero
  • ******
  • Posts: 1,796
  • Gender: Male
  • Real coders do not need to comment their code!
    • Dream Portal
Re: Board Icons
« Reply #10 on: August 29, 2013, 12:38:55 AM »
Yeah, I just installed SMF 2.0.5, and installed Board Icons on a FRESH INSTALL of SMF 2.0.5 and works PERFECTLY!  See for yourself here:  http://devs.dream-portal.net/smf205/index.php

You must have a mod installed that is interfering with Board Icons somehow... or possibly the theme itself.  If you switch to the Default Curve theme, does it than display the Board Icon?

Offline Burke ♞ Knight

  • SMF Hero
  • ******
  • Posts: 3,534
Re: Board Icons
« Reply #11 on: August 29, 2013, 12:44:25 AM »
No mods that should have anything to do with this...
Hmm... Very strange, indeed....

Well, guess it just wont be possible on this site, then.
I'll have to check things out if can, but I don't see any mods that should affect this.

Even tried to go with default theme to test, and that shows the default theme's image.

Offline Dream Portal Team

  • Semi-Newbie
  • *
  • Posts: 89
    • Dream Portal
Re: Board Icons
« Reply #12 on: August 29, 2013, 12:47:23 AM »
Did you install the Anecdota Theme before or after installing Board Icons?  You might try completely uninstalling Board Icons Mod, and than Re-Installing the mod.  That might fix your problem!

Make note of any errors that show in the Anecdota Theme (will be listed at bottom of mod installation page) upon re-installation of Board Icons Mod.
This is the universal account for the Dream Portal Team. All messages sent to this account will be discarded.  Please visit us at:  Dream Portal dot net for support and extensions to Dream Portal.

Offline Burke ♞ Knight

  • SMF Hero
  • ******
  • Posts: 3,534
Re: Board Icons
« Reply #13 on: August 29, 2013, 12:50:41 AM »
Theme was installed before.
No errors on Board Icon install.

Looking over the mod's install files now, to see if anything I missed that may clue us in on what's wrong.
Looks nice and clean in those files, by the way, nicely done mod. :)

Offline Dream Portal Team

  • Semi-Newbie
  • *
  • Posts: 89
    • Dream Portal
Re: Board Icons
« Reply #14 on: August 29, 2013, 12:59:49 AM »
This mod was created about 3 years ago, it is a poor excuse for a mod nowadays with SMF Hooks having been introduced into the mix.  But thanks anyways...

Anyways, you must have done something right, cause I see the icon on your site now.
This is the universal account for the Dream Portal Team. All messages sent to this account will be discarded.  Please visit us at:  Dream Portal dot net for support and extensions to Dream Portal.

Offline Burke ♞ Knight

  • SMF Hero
  • ******
  • Posts: 3,534
Re: Board Icons
« Reply #15 on: August 29, 2013, 01:01:17 AM »
Bingo!

Found it!

Somehow, it did not do the edit to the BoardIndex.template.php file.

Had no errors on install, yet the edit was not done.
Very strange.

Works now, though. :)

This is most likely why it missed it without error:

Code: [Select]
<file name="$themedir/BoardIndex.template.php">
<operation error="ignore">

Offline Dream Portal Team

  • Semi-Newbie
  • *
  • Posts: 89
    • Dream Portal
Re: Board Icons
« Reply #16 on: August 29, 2013, 01:03:39 AM »
Awesome.  Ok, I suppose that is a critical operation than.  Will get around soon to updating it without ignoring that operation on error.

Thanks :)
This is the universal account for the Dream Portal Team. All messages sent to this account will be discarded.  Please visit us at:  Dream Portal dot net for support and extensions to Dream Portal.

Offline samborabora

  • Full Member
  • ***
  • Posts: 517
Re: Board Icons
« Reply #17 on: September 23, 2013, 10:35:29 AM »
I would love to have the board icons included in other pages, such as next to the message title of the Post New Topic pages, and embedded into some SimplePortal blocks. What code should I use to show the custom board icon next to the subject input box of the New Topic page for the relevant forum I'm posting in?

Offline SoLoGHoST

  • SMF Hero
  • ******
  • Posts: 1,796
  • Gender: Male
  • Real coders do not need to comment their code!
    • Dream Portal
Re: Board Icons
« Reply #18 on: September 25, 2013, 02:29:57 AM »
Honestly, for blocks with Simple Portal, I don't know how you would do it.  With Dream Portal, you can add layouts per board, and than the modules (blocks) on that layout will only show for that board.  So, for this, you could use the "Custom Module" and have the image inserted into it with a Transparent Module Template and will only show the image for that board and that board alone.

What might be better is to use a Custom Block in Simple Portal with PHP as the Code type (if possible) and have it show on the forum, and test it via the $_REQUEST['board'] variable.  You could than have it grab an image based on the board id returned within $_REQUEST['board'].

For example:

Code: [Select]
global $boardurl;
if (!empty($_REQUEST['board']))
    echo '
        <img src="' . $boardurl . '/images/boardicons/board_' . $_REQUEST['board'] . '" alt="" />';

So, this would output the image based on the following naming convention:  "board_{board id}"

Where {board_id} is the actual id value of the board that gets returned from $_REQUEST['board'].  If this variable is empty, it will not be shown.  Therefore this will be sure to display on all pages within the board (hopefully).  And you could use the same code within the Post.php and/or Post.template.php for when users are creating New Topics.  Ofcourse, you should probably check to be sure it is an integer value, but that I'll leave up to you.

Offline jomaber

  • Newbie
  • *
  • Posts: 2
Re: Board Icons
« Reply #19 on: November 26, 2013, 08:13:12 AM »
Anyone knows if this mod is compatible with 2.0.6 version?