Simple Machines Community Forum

SMF Support => SMF 2.0.x Support => Topic started by: zzpoointzz on November 16, 2011, 04:17:37 PM

Title: Double
Post by: zzpoointzz on November 16, 2011, 04:17:37 PM
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fimg507.imageshack.us%2Fimg507%2F8576%2Fcapturebp.png&hash=58ba19273a0ef4cc7d7d0123599a6ae50e1fe467) (http://imageshack.us/photo/my-images/507/capturebp.png/)

The image has the requests :)
Title: Re: Double
Post by: kat on November 16, 2011, 05:23:38 PM
As that's a custom theme, zzzzzzzz, you're more likely to get the help you need from that theme's support topic.

Unless, of course, this is happening if you use the SMF default theme, as well.
Title: Re: Double
Post by: Illori on November 16, 2011, 05:28:12 PM
i think what they want to do is remove the linktree from the topic listing and maybe board index, that would be an edit of the default theme unless the custom theme has BoardIndex.template.php and Display.template.php as part of it.
Title: Re: Double
Post by: zzpoointzz on November 17, 2011, 04:17:58 AM
its always been there (from wen i installed the forum, that means that i had the def. theme at the start), asking this now to make a clean up of the forum.. makiing it tidy (even this forum has the same double things)
Title: Re: Double
Post by: kat on November 17, 2011, 06:12:39 AM
So, it's the "Reply", "Addpoll", "Notify", etc. buttons, yes?

One at the top and one at the bottom.

For some reason, you want them just at the top? Bottom?

I assume that they're there, so that you don't have to keep going up/down a full page to click one.
Title: Re: Double
Post by: zzpoointzz on November 17, 2011, 10:06:40 AM
sorry for my slow posting:

yes, they are those buttons.
Just at the bottom

your right, but i don't think that someone would reply whit out reading the thread (that means that he has to scroll to the end of the page)
so, they are useless
Title: Re: Double
Post by: kat on November 17, 2011, 11:17:45 AM
Actually, I use them quite a lot, myself.

Just at the bttom. You want them to STAY, just at the bottom?

Or, you want them to be removed, just at the bottom?

In the theme's Display.template.php, you'll find this:

// Build the normal button array.
$normal_buttons = array(
'reply' => array('test' => 'can_reply', 'text' => 'reply', 'image' => 'reply.gif', 'lang' => true, 'url' => $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';last_msg=' . $context['topic_last_message'], 'active' => true),
'add_poll' => array('test' => 'can_add_poll', 'text' => 'add_poll', 'image' => 'add_poll.gif', 'lang' => true, 'url' => $scripturl . '?action=editpoll;add;topic=' . $context['current_topic'] . '.' . $context['start']),
'notify' => array('test' => 'can_mark_notify', 'text' => $context['is_marked_notify'] ? 'unnotify' : 'notify', 'image' => ($context['is_marked_notify'] ? 'un' : '') . 'notify.gif', 'lang' => true, 'custom' => 'onclick="return confirm(\'' . ($context['is_marked_notify'] ? $txt['notification_disable_topic'] : $txt['notification_enable_topic']) . '\');"', 'url' => $scripturl . '?action=notify;sa=' . ($context['is_marked_notify'] ? 'off' : 'on') . ';topic=' . $context['current_topic'] . '.' . $context['start'] . ';' . $context['session_var'] . '=' . $context['session_id']),
'mark_unread' => array('test' => 'can_mark_unread', 'text' => 'mark_unread', 'image' => 'markunread.gif', 'lang' => true, 'url' => $scripturl . '?action=markasread;sa=topic;t=' . $context['mark_unread_time'] . ';topic=' . $context['current_topic'] . '.' . $context['start'] . ';' . $context['session_var'] . '=' . $context['session_id']),
'send' => array('test' => 'can_send_topic', 'text' => 'send_topic', 'image' => 'sendtopic.gif', 'lang' => true, 'url' => $scripturl . '?action=emailuser;sa=sendtopic;topic=' . $context['current_topic'] . '.0'),
'print' => array('text' => 'print', 'image' => 'print.gif', 'lang' => true, 'custom' => 'rel="new_win nofollow"', 'url' => $scripturl . '?action=printpage;topic=' . $context['current_topic'] . '.0'),
);


Getting rid of that gets rid of them, for the most part, both top and bottom.

So, I'll need to do a lot of figuring-out, for not a lot of reward.

Gimme a while...
Title: Re: Double
Post by: kat on November 17, 2011, 11:32:10 AM
Nope.

I can get rid of them, entirely. But, not just one of them.
Title: Re: Double
Post by: zzpoointzz on November 17, 2011, 11:42:58 AM
bottom stays, top goes,

if you could eplayn i would try :)

anyway thanks
Title: Re: Double
Post by: kat on November 17, 2011, 11:56:06 AM
Well, that bit of code that I posted shows the buttons.

Trouble is, if you remove it, it removes the buttons from both the top and the bottom.

So, there must be some other bit of code doing stuff and I can't figure-out which bit.

I could probably work it out, eventually, using a bit of the ol' "Trial and error".

But, apart from the fact that you can do that, yourself, someone with a braincell could probably figure it out in a few seconds!

I thought it was probably sensible to wait for that person with a braincell to join in. ;)
Title: Re: Double
Post by: Illori on November 17, 2011, 12:01:39 PM
display.template.php

Code (find) Select
<div class="nextlinks">', $context['previous_next'], '</div>', template_button_strip($normal_buttons, 'right'), '

Code (replace) Select
<div class="nextlinks">', $context['previous_next'], '</div>','

K@ was editing out the whole thing, but not where it is called to show in the template which is the "normal_buttons"
Title: Re: Double
Post by: zzpoointzz on November 17, 2011, 12:15:48 PM
It Happened !!! lololo :)
Title: Re: Double
Post by: Illori on November 17, 2011, 12:17:50 PM
what happened?
Title: Re: Double
Post by: zzpoointzz on November 17, 2011, 12:20:01 PM
read Kats last post :)
QuoteI thought it was probably sensible to wait for that person with a braincell to join in.
Title: Re: Double
Post by: Illori on November 17, 2011, 12:26:32 PM
so did that fix your issue?
Title: Re: Double
Post by: zzpoointzz on November 17, 2011, 12:29:24 PM
thanks, it worked, but it took just the buttons away:

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fimg210.imageshack.us%2Fimg210%2F7162%2F16128203.png&hash=7d5c34969d371fb7391466aabf3efc0ce3a61396) (http://imageshack.us/photo/my-images/210/16128203.png/)
Title: Re: Double
Post by: Illori on November 17, 2011, 12:31:49 PM
that was what i understood you wanted done, when asked you said the buttons not the linktree or the next/prev links, it will take some more work to figure that part out.
Title: Re: Double
Post by: zzpoointzz on November 17, 2011, 12:34:04 PM
oh sorry, whit the distance of 24 hours of posting here i did not remember what i was really asking
Title: Re: Double
Post by: Illori on November 17, 2011, 12:36:09 PM
<div class="nextlinks">', $context['previous_next'], '</div>', template_button_strip($normal_buttons, 'right'), ' in the orginal file just remove that whole line and it will take out the next/prev links

index.template.php

// Show the navigation tree.
theme_linktree();

and remove that and it will remove the upper link tree from every page, it can not just be removed from the thread page.
Title: Re: Double
Post by: zzpoointzz on November 17, 2011, 12:42:55 PM
* Perfect *   :)
********
Title: Re: Double
Post by: zzpoointzz on November 17, 2011, 12:50:23 PM
to ad some space thru the google ads and the menu ?

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fimg267.imageshack.us%2Fimg267%2F6420%2Fcapthure.png&hash=33426aeb3891937fd5392a21e0dd175c134be78f) (http://imageshack.us/photo/my-images/267/capthure.png/)
Title: Re: Double
Post by: Illori on November 17, 2011, 12:55:26 PM
that is not a default feature so i have no idea how you added them, if you used a mod post in the mods support thread.
Title: Re: Double
Post by: zzpoointzz on November 17, 2011, 12:58:58 PM
so to ads some spacing i have to go in the google mod and ad space in the html ?
Title: Re: Double
Post by: zzpoointzz on November 17, 2011, 01:03:06 PM
Edit: done it, went in the ads menu and added a <p> </p> :)
Title: Re: Double
Post by: ARG01 on November 17, 2011, 01:47:11 PM
If you want to remove the bottom linktree as well look for this in the default themes Display.template.php and Message.template.php:
// Show the lower breadcrumbs.
theme_linktree();


and just comment that out:
// Show the lower breadcrumbs.
//theme_linktree();


If you have a custom theme with it's own Message.template.php file you may be required to do the same there.

;)