Members: 278  •  Posts: 12615  •  Topics: 864  •  Please welcome bosanci28, our newest member.
Please login or register.

Login with username, password and session length
 

News:

Welcome To Graphics Mayhem

collapse

Author Topic: PlayGround Ultimate - Adding Icons  (Read 286 times)

0 Members and 1 Guest are viewing this topic.

Shortie

  • Administrator
  • Expert
  • Offline
  • Posts: 3637
  • The Ultimate Boss
  • OS:
  • Windows 7/Server 2008 R2
  • Browser:
  • Firefox 3.5.2
PlayGround Ultimate - Adding Icons
« on: August 09, 2009, 02:50:39 AM »
    Okay Guys n Gals

    This is long winded topic but should cover all you need to add extra icons to the PlayGround Ultimate Theme - for this tutorial we are going to use the Rules Mod but the process will work with any Mod which works via an Action or URL (note most Chat links use and external URL)

    Icons available are

    admin.png            arcade.png      buddies.png      cal.png        chat.png
    contact.png         download.png   favs.png          forum.png    friends.png
    gallery.png           help.png          home.png         login.png     login1.png
    logout.png           logout2.png      members.png    moderate.png      pm.png
    pmsome.png        profile.png        quiz.png           reg.png        rules.png
    search.png          video.png


    Now we need to decide what the URL is when you navigate to the mod - so set you theme to the SMF Core just for yourself

    Go

    Profile > Look and Layout > Change



    Once you have clicked change select the "SMF Default Theme - Core" Theme this is because as Mods as designed to work with the Default SMF Theme



    I love this ability to put images inline :D

    Now once the default theme as loaded you should see the button for the mod you want to add an icon for (in this case The Rules mod)



    Now click the Button created by the mod and look in the address bar of your browser and note the latter part of the URL in this case "?action=rules"



    Okay on to the fun bit of actually adding the icon - again the simple if you follow these steps and do not rush :D

    Download a copy of the index.template.php from the Playground Ultimate theme - open it in any good code editor (if you need one the Google is your friend) Note you can use notepad if you are using Windows but it can mess upp the file on odd occasions DO NOT USE SOMETHING LIKE WORD AS THAT WILL SCREW THE FILE

    No once the file is open do a search for the following

    Code: [Select]
    function template_dock_menu ()
    This is the code which does all the menu work and I have kept is condensed so that life is easier for you Guys n Gals

    Now we need to construct the dock item and assign a function to it - the code we need in this case is as follows - The pieces to note are in RED



    echo '
         ?action=rules"  >rules.png" alt="' . $txt['gmrules'] . '" />' . $txt['gmrules'] . ' ';

    Now save the file and upload it to your server

    Nearly there one more thing to do, we need to tell SMF what the text is to display under the icon - so now download the ThemeStrings.english.php file which can be found in the languages folder of the Theme

    edit the file again and add a line similar to the following

    $txt['gmrules'] = 'Rules';

    This will now tell SMF what text to put under the Icon

    Now up load the file to your server and that is it all should now be working if for some reason it is not displayed then the server file cache needs to be flushed to do this go

    Admin > Forum Maintenance > Routine

    and at the bottom of the page click the button to empty the file cache

    Voila all done

    We can of course take this further by assigning permissions to the icon so that it shows only to people who have the right - but we can address that on a per mod basis - also if you want to change the order of the icons then that can be done in the same manner just but reordering the code in the "function template_dock_menu ()"

    So enjoy but as always BACKUP YOUR FILES BEFORE EDITING
    « Last Edit: August 09, 2009, 04:01:59 AM by Shortie »
    Thank You, "Guest" For Reading My Post.

    mastram

    • Practiced
    • Offline
    • Posts: 40
    • OS:
    • Windows XP
    • Browser:
    • MS Internet Explorer 6.0
    Re: PlayGround Ultimate - Adding Icons
    « Reply #1 on: August 16, 2009, 06:41:54 AM »
      from where can i downlod icons and where is add button option

      Shortie

      • Administrator
      • Expert
      • Offline
      • Posts: 3637
      • The Ultimate Boss
      • OS:
      • Windows 7/Server 2008 R2
      • Browser:
      • Firefox 3.5.2
      Re: PlayGround Ultimate - Adding Icons
      « Reply #2 on: August 16, 2009, 06:45:10 AM »
        The icons are already in the stuff you have uploaded - that is why it is soooooooooo  Large and of course it is the Ultimate :D:D:D

        I am getting you correct there is no add a Dock item it has to be done manually

        If you can zip up the playground ultimate Index.template.php and upload it here and tell me which icons / mods you want it to work with then I will have a look and do the manual edits

        Shortie
        « Last Edit: August 16, 2009, 06:48:07 AM by Shortie »
        Thank You, "Guest" For Reading My Post.

        Nicole23

        • Bystander
        • Offline
        • Posts: 1
        • OS:
        • Windows XP
        • Browser:
        • MS Internet Explorer 8.0
        Re: PlayGround Ultimate - Adding Icons
        « Reply #3 on: August 28, 2009, 03:43:51 PM »
          Hi,

          Good job :)

          I search Wiki  icon to the PlayGround Ultimate Theme :)

          Thank's for help :)

          Have a nice day.
           


          Search


          Latest Activity.
          Novembers Graphics Mayhem Wallpaper by Shortie
          [Today at 07:48:08 AM]


          Need some badges... please by Green CoW
          [Today at 04:19:17 AM]


          Icon For Top To Link To Wiki by Shortie
          [Today at 02:42:14 AM]


          Windows 7 Walls by NerdBoy
          [Yesterday at 07:51:35 PM]


          More Distinct For SMF RC2 by the yicker
          [Yesterday at 11:40:32 AM]


          November's Logo Challenge "Up Top" (2009)... by NerdBoy
          [Yesterday at 05:41:46 AM]


          What's the deal with SMF? by NerdBoy
          [Yesterday at 05:40:12 AM]


          Deep Red 2 For SMF RC2 by Shortie
          [Yesterday at 04:22:26 AM]


          help in a photo by SoLoGHoST
          [November 18, 2009, 08:34:10 PM]


          Topic Count in Profiles by live627
          [November 18, 2009, 06:14:20 PM]


          ATI Catalyst™ version 9.11 released by Nukegaming
          [November 18, 2009, 03:44:16 PM]


          themed logo challenge by Shortie
          [November 17, 2009, 02:29:20 PM]



          Page created in 0.113 seconds with 28 queries.