Page Index Toggle Pages: 1 Send TopicPrint
Hot Topic (More than 10 Replies) [DONE] CSS Buttons for YaBB 2.2 (Read 12669 times)
Carsten
God Member
*****
Offline


...to much YaMS

Posts: 3281
Location: Langå
Joined: Aug 2nd, 2002
Gender: Male
[DONE] CSS Buttons for YaBB 2.2
Nov 29th, 2007 at 5:41pm
Print Post  
This mod has now been released and moved to the final mods board: http://www.boardmod.org/yabb/YaBB.pl?board=newsy22;action=display;num=1196974355...

Ever wanted to add a new set of graphic buttons to your YaBB but gave up because it was to much trouble making more than 60 different graphics?

With this mod you'll get the job done by making only 2 - yes TWO - small graphics!!! One left part 20x10 px and one right part 260x20 px in .png or .gif format. Give them the same name except for the last part which must be '_left' and '_right'. Place them directly in the 'yabbfiles/Buttons' folder and - Voila - they will appear in the Style Sheed wysiwyg editor for you to add to your templates.

Format for new button:

UnikeName_left.png (10x20 px)
UnikeName_right.png (260x20 px)


Also added a new extra "Menu.def" to load all 3 menu modes from only one file. The format for adding new buttons to the new "Menu.def" file compared to "old style" is:

emplate-or-mod

For the "Home" button it looks like this:

New Menu.def style:
home,home|img_txt|103|img_txt|103|imgmenu|tmp

Old Menu0.def:
'home' => "<img src=\"$imagesdir/home.$imgext\" alt=\"$img_txt{'103'}\" border=\"0\" /> <span class=\"imgmenu\">$img_txt{'103'}</span>",

Old Menu1.def:
'home' => "<span class=\"imgmenu\">$img_txt{'103'}</span>",

Old Menu2.def:
'home' => "<img src=\"$html_root/Buttons/$button_language/home.$imgext\" alt=\"$img_txt{'103'}\" border=\"0\" />",


Included in the zip package are new 'default.css' and 'yabb21.css' - if you dont want to overwrite your existing .css files you can copy the styles from the 'css_adds.txt' file (also included in the zip) and paste them into your .css file(s).

If the template in use does not have the css-button styles in it the board will automatically load the old menu definitions.

Edited:
Bug making the preview button take any text attribute selected for any other element - new beta 0.3 zip attached.

« Last Edit: Dec 6th, 2007 at 9:03pm by Carsten »  

released.gif ( 3 KB | Downloads )
released.gif

If you knock your head against a brick wall and hear a hollow sound, it's not necessarily coming from the wall.
Back to top
 
IP Logged
 
Captain John
Senior Member
****
Offline


Pass to Port !

Posts: 264
Location: Reno Beach
Joined: Jan 18th, 2007
Gender: Male
Re: CSS Buttons for YaBB 2.2
Reply #1 - Nov 30th, 2007 at 7:23pm
Print Post  
Absolutely Great work Carsten .. Many users will love this.
  

Love to live and love on the water
Back to top
 
IP Logged
 
Carsten
God Member
*****
Offline


...to much YaMS

Posts: 3281
Location: Langå
Joined: Aug 2nd, 2002
Gender: Male
Re: CSS Buttons for YaBB 2.2
Reply #2 - Dec 2nd, 2007 at 3:26pm
Print Post  
Attached what i consider the final version to the first post. Now you have even more control over the css buttons being able to change the position of the icon and text inside the buttons.
« Last Edit: Dec 3rd, 2007 at 1:03am by Carsten »  

cssbuttons2.gif ( 32 KB | Downloads )
cssbuttons2.gif

If you knock your head against a brick wall and hear a hollow sound, it's not necessarily coming from the wall.
Back to top
 
IP Logged
 
Jeff
God Member
*****
Offline


There are no bugs there
are only features

Posts: 2552
Joined: Jan 14th, 2005
Gender: Male
Re: CSS Buttons for YaBB 2.2
Reply #3 - Dec 2nd, 2007 at 3:56pm
Print Post  
woow. Nice Work Carsten.
  

greetings
Jeff
Back to top
WWW  
IP Logged
 
qersys
Senior Member
****
Offline


Yes, I am

Posts: 342
Location: SF
Joined: Dec 29th, 2002
Gender: Male
Re: CSS Buttons for YaBB 2.2
Reply #4 - Dec 2nd, 2007 at 7:08pm
Print Post  
Very cool Carsten, works great  Smiley
  
Back to top
IP Logged
 
qersys
Senior Member
****
Offline


Yes, I am

Posts: 342
Location: SF
Joined: Dec 29th, 2002
Gender: Male
Re: CSS Buttons for YaBB 2.2
Reply #5 - Dec 2nd, 2007 at 10:28pm
Print Post  
I was just playing around making some buttons. Gee Whiz this makes so many other things possible. Thanks again.
  

menunew.jpg ( 28 KB | Downloads )
menunew.jpg
Back to top
IP Logged
 
Carsten
God Member
*****
Offline


...to much YaMS

Posts: 3281
Location: Langå
Joined: Aug 2nd, 2002
Gender: Male
Re: CSS Buttons for YaBB 2.2
Reply #6 - Dec 2nd, 2007 at 10:34pm
Print Post  
@ Cap. JetLi and qersys

Thanks guys - coming from a support wizard, a graphics wizard and a template wizard this really means a lot to me  Wink
  

If you knock your head against a brick wall and hear a hollow sound, it's not necessarily coming from the wall.
Back to top
 
IP Logged
 
Outumuro
God Member
*****
Offline


Publisher - YaBB Toolbar

Posts: 569
Location: Los Angeles
Joined: Apr 14th, 2004
Gender: Male
Re: CSS Buttons for YaBB 2.2
Reply #7 - Dec 3rd, 2007 at 12:03am
Print Post  
Nice work Carsten.  That screen capture looks awesome.  Can't wait to try this out. Smiley
  


Back to top
WWW  
IP Logged
 
Carsten
God Member
*****
Offline


...to much YaMS

Posts: 3281
Location: Langå
Joined: Aug 2nd, 2002
Gender: Male
Re: CSS Buttons for YaBB 2.2
Reply #8 - Dec 3rd, 2007 at 12:49am
Print Post  
Thx Outumuro - hope you'll enjoy it.

Made a very, very...very small change in the mod file - actually so small i did not change the version number. Just to change the left padding for the preview buttons from 4 to 6 pixel as it should be. To make up for this mistake i've added a new "water" button.

New zip attached to first post.

btw. Forgot to mention a small but usefull addition - the very observant viewer may have noticed that the name of the template you are working on is now pre-written in the "Save ass" box unless it's "default" so you don't have to write it every time you want to save your changes.
  

If you knock your head against a brick wall and hear a hollow sound, it's not necessarily coming from the wall.
Back to top
 
IP Logged
 
Carsten
God Member
*****
Offline


...to much YaMS

Posts: 3281
Location: Langå
Joined: Aug 2nd, 2002
Gender: Male
Re: CSS Buttons for YaBB 2.2
Reply #9 - Dec 3rd, 2007 at 1:46am
Print Post  
oups - a bug making the preview button take any attribute selected for any other element - new zip attached to first post.
  

If you knock your head against a brick wall and hear a hollow sound, it's not necessarily coming from the wall.
Back to top
 
IP Logged
 
ThM
God Member
*****
Offline



Posts: 585
Location: Germany, Nds.
Joined: May 21st, 2006
Gender: Male
Re: CSS Buttons for YaBB 2.2
Reply #10 - Dec 3rd, 2007 at 7:55am
Print Post  
Hi ...

great Tool ....  Wink


Edited:
I've installed without errors, upload all Files from the *zip File and set chmod. But i missed the Buttons on the right side .... Looks at the Screenshot.


What i'm doing wrong  Undecided


Run's now. I have upload the Buttons to the wrong Place  :rolleyes4:

And here comes the translation for german Users in Templates.lng

German_Sie

Code
Select All
'buttontext' => 'CSS Buttons',
'buttondescription' => 'Hier können Sie die Position des Icon, den Text innerhalb des Buttons sowie die Hintergrund Grafik für den Button ändern.',
'moveicon1' => 'Icon nach unten setzen um:',
'moveicon2' => 'Icon nach rechts setzen um:',
'iconspace' => 'Icon Abstand zum Text:',
'movetext' => 'Text nach unten setzen um:', 



German_Du

Code
Select All
'buttontext' => 'CSS Buttons',
'buttondescription' => 'Hier kannst Du die Position des Icon, den Text innerhalb des Buttons sowie die Hintergrund Grafik für den Button ändern.',
'moveicon1' => 'Icon nach unten setzen um:',
'moveicon2' => 'Icon nach rechts setzen um:',
'iconspace' => 'Icon Abstand zum Text:',
'movetext' => 'Text nach unten setzen um:', 



Best regards .... ThM
« Last Edit: Dec 3rd, 2007 at 12:22pm by ThM »  

Greeting ThM
Back to top
 
IP Logged
 
Carsten
God Member
*****
Offline


...to much YaMS

Posts: 3281
Location: Langå
Joined: Aug 2nd, 2002
Gender: Male
Re: [DONE] CSS Buttons for YaBB 2.2
Reply #11 - Dec 6th, 2007 at 9:07pm
Print Post  
I have released this mod as final and moved it to the "Final Mods for YaBB 2.2" board.
  

If you knock your head against a brick wall and hear a hollow sound, it's not necessarily coming from the wall.
Back to top
 
IP Logged
 
Spikecity
God Member
*****
Offline


Beer anyone ?

Posts: 2630
Location: New York
Joined: Apr 16th, 2002
Gender: Male
Re: [DONE] CSS Buttons for YaBB 2.2
Reply #12 - May 18th, 2010 at 1:34pm
Print Post  
This Topic was moved here from BETA Mods for YaBB 2.2/2.2.1/2.2.2/2.2.3 [move by] Spikecity.
  

Nothing to add here Smiley
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint