News:

Wondering if this will always be free?  See why free is better.

Main Menu

[2.0 RC3] add a "view new topic" button

Started by Raffoz, May 08, 2010, 06:36:07 PM

Previous topic - Next topic

Raffoz

i'd like to add in the forum a "view new topic button"...

in the place indicated in the attacjed image...

how can i do it?
for the button i need a graphic manipolation, or it's just frame and text?

thanks...
MacOsX (last)
SMF 2.0.15 and 2.1.2 (different forums)
Chrome (last) or Safari (last)

Yağız...

Find in ./Themes/default/index.template.php:
echo '

</ul>
</div>';

Replace with:
echo '
<li id="button_new_topic">
<a class="firstlevel" href="{url}">
<span class="firstlevel">{title}</span>
</a>
</li>
</ul>
</div>';

Find ./Themes/default/css/index.css
.dropmenu li ul
{
z-index: 90;

Add before:
.dropmenu li#button_new_topic
{
float: right;
padding: 0;
margin: 0;
position: relative;
}


Don't forget to replace {url} and {title} in the code that you have added in index.template.php.

Raffoz

thanks!

two more questions:

1) how can i make the button with the backgroung of the "Forum" one? i'd like to have in standby way of the button, the same background the "forum" button has when i go over it with the mouse...

2) and how making it orange when i pass over it with the mouse?
MacOsX (last)
SMF 2.0.15 and 2.1.2 (different forums)
Chrome (last) or Safari (last)

Yağız...

Find:
<a class="firstlevel" href="{url}">
Replace with:
<a class="active firstlevel" href="{url}">

Raffoz

thanks!!! :)
sorry for my questions, but before questioning here, i try modifying alone, but i can't reach what i want... :(

ok, now:

1) how can i invert colors only for that single button? i'd like that in standy the color of this button is dark grey, and only when hover the color is orange...

2) if i insert this button, with your code, it creates one more white line space the menu (forum, admin, search, profile, etc etc)...
how is possible to insert it without creating this space horizontal line that create a scroll of everything more down?
or better: how is possible to create it in the second option i put in my previous attached image? (http://www.simplemachines.org/community/index.php?action=dlattach;topic=380469.0;attach=144454;image)
without creating a more white horizontal space?

thanks for your time helping me! :)
MacOsX (last)
SMF 2.0.15 and 2.1.2 (different forums)
Chrome (last) or Safari (last)

Yağız...

Quote from: Raffaele1977 on May 11, 2010, 01:53:28 AM
1) how can i invert colors only for that single button? i'd like that in standy the color of this button is dark grey, and only when hover the color is orange...
I tried to modify but I'm not good at all with CSS :( You can try to post at Graphics and Templates boards.

Quote2) if i insert this button, with your code, it creates one more white line space the menu (forum, admin, search, profile, etc etc)...
how is possible to insert it without creating this space horizontal line that create a scroll of everything more down?
or better: how is possible to create it in the second option i put in my previous attached image? (http://www.simplemachines.org/community/index.php?action=dlattach;topic=380469.0;attach=144454;image)
without creating a more white horizontal space?
Hmm, weird ... I didn't have any problems with that, maybe you have more buttons than me. I'll try to look at that.

Advertisement: