News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Reply Button In Every Post

Started by Joe N, April 08, 2009, 01:39:28 AM

Previous topic - Next topic

luuuciano

btw, the first change I made it like this:

// Simple Reply Button
      if ($context['can_reply'] && !empty($options['display_quick_reply']))
      echo '
               <li class="reply_button"><a href="#quickreply">', $txt['reply'], '</a></li>';
else
      echo '
               <li class="reply_button"><a href="', $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies'], '">', $txt['reply'], '</a></li>';


so, it goes to bottom when the user have quick reply on...

any way to go down, and the cursor in the reply section?
No me agradan los foros que no te dejan borrar TU PROPIO usuario, como por ejemplo smfsimple.com.
E incluso te mandan emails no solicitados, de los cuales, quizá, no puedas escapar porque NO te dejan posibilidad a deshabilitarlos (a menos que NO te tengan en su lista negra).

luuuciano

how can be the "<li class="reply_button"><a href="#quickreply">', $txt['reply'], '</a></li>" section to make focus on the textarea?

I mean the cursor, so the user is ready to write... without having to clic in the textarea...

(I have tried a few javascript... but I really have no idea about JS......)
No me agradan los foros que no te dejan borrar TU PROPIO usuario, como por ejemplo smfsimple.com.
E incluso te mandan emails no solicitados, de los cuales, quizá, no puedas escapar porque NO te dejan posibilidad a deshabilitarlos (a menos que NO te tengan en su lista negra).

T3CHN0

I am using this mod now in RC3 but it doesn't work. I did use it in 1.1.11 & loved it. work perfect as how I wanted it to work.
but after upgrading my forum I can't install it in the
admin section and had to add the code to display.template.php my self.
the reply icon shows now but when clicking on the reply
my page just moves to the bottom of the forum page. 

is there something I can change in this coding to make it work with RC3


// Simple Reply Button
if ($context['can_reply'] && !empty($options['display_quick_reply']))
echo '
<li><a href="#quickreply">', $respond_button, '</a></li>';
else
echo '
<li><a href="', $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies'], '">', $respond_button, '</a></li>';

      // Can they reply? Have they turned on quick reply?
      if ($context['can_reply'] && !empty($options['display_quick_reply']))
         echo '
                     <li><a href="', $scripturl, '?action=post;quote=', $message['id'], ';topic=', $context['current_topic'], '.', $context['start'], ';num_replies=', $context['num_replies'], '" onclick="return oQuickReply.quote(', $message['id'], ');">', $reply_button, '</a></li>';


Please is anyone can help. thankyou

!RFAN

lolzz.. on my forum... there is a link for reply and it works fine but no icon.. other buttons have icons but reply buttons dsnt show any icon or text.. but link works fine..
i can notice the presence of link by hovering... m using rc3...


gbsothere

If you used the package manager, it only places the edits in Default's template.  You must manually place this mod's edits in Babylon's Display.template.php.  Just use the 1.1.11 pulldown on the mod's page and the parsing instructions will be found there.

:)
My apologies, but I am taking a break from accepting PM requests for support.  If I am not currently assisting you, please do not ask as long as this notice is posted.  Thank you.

I Don't Want To Grow Old Alone


It has been proven that Steely Dan reduces the occurrence of road rage, according to an independent study.



A reminder about admin / ftp passwords etc.


gbsothere

If you'll attach Babylon's Display.template.php, I'll take a look at it, Blade_Runner, and see if I can find a solution.  If I can't, someone else who can will probably weigh in. 

:)
My apologies, but I am taking a break from accepting PM requests for support.  If I am not currently assisting you, please do not ask as long as this notice is posted.  Thank you.

I Don't Want To Grow Old Alone


It has been proven that Steely Dan reduces the occurrence of road rage, according to an independent study.



A reminder about admin / ftp passwords etc.


gbsothere

I'm asking around, Blade_Runner, because it's beyond my scope.  That last "add" string would have to be rewritten to work with your theme, I guess. 

I'm believing that one of the code-savvy members here will be able to clinch it, though.  :)
My apologies, but I am taking a break from accepting PM requests for support.  If I am not currently assisting you, please do not ask as long as this notice is posted.  Thank you.

I Don't Want To Grow Old Alone


It has been proven that Steely Dan reduces the occurrence of road rage, according to an independent study.



A reminder about admin / ftp passwords etc.

gbsothere

Blade_Runner, upload the attached file to Babylon's theme directory but, before you do, pull the unedited one from your server out onto your desktop.  That way, if this goes awry, you can just re-upload your original.   :)
My apologies, but I am taking a break from accepting PM requests for support.  If I am not currently assisting you, please do not ask as long as this notice is posted.  Thank you.

I Don't Want To Grow Old Alone


It has been proven that Steely Dan reduces the occurrence of road rage, according to an independent study.



A reminder about admin / ftp passwords etc.

Blade_Runner

I tried, it doesn't work.

The codes from the first part is missing. Even after adding it in, it still does not work.

The code for the first part is as follows:
----------------------------------
      // Simple Reply Button
      if ($context['can_reply'] && !empty($options['display_quick_reply']))
      echo '<a href="#quickreply">', $respond_button, '</a>';
      else
      echo '<a href="', $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies'], '">', $respond_button, '</a>';
----------------------------------
             

gbsothere

Ah.....  I just placed the edit in the file you'd sent me earlier and I thought the first part was in it.   :o

I'll ask around about this, and hopefully, in the meantime, someone (who actually knows what he's doing) will see this and weigh in.
My apologies, but I am taking a break from accepting PM requests for support.  If I am not currently assisting you, please do not ask as long as this notice is posted.  Thank you.

I Don't Want To Grow Old Alone


It has been proven that Steely Dan reduces the occurrence of road rage, according to an independent study.



A reminder about admin / ftp passwords etc.

gbsothere

#113
Well, Blade_Runner....   my method is known as "duct tape".  *grin*  But I installed the babylon Theme (it wasn't on my test board) and I got it to work.


Upload this attached file and see if anything blows up.

It works for me, but my forum is used to duct tape, so yours might be more particular.   :D

(Save your original onto your desktop first, before sending this up, just in case you need to re-upload it.)

Let me know?
My apologies, but I am taking a break from accepting PM requests for support.  If I am not currently assisting you, please do not ask as long as this notice is posted.  Thank you.

I Don't Want To Grow Old Alone


It has been proven that Steely Dan reduces the occurrence of road rage, according to an independent study.



A reminder about admin / ftp passwords etc.


Blade_Runner

This is only a slight problem left. It does not work for guest. According to the description, it is suppose to show. It's not important and I don't need that function. Just want to let others who might want to install know about this.

gbsothere

My boards, both test and active, are very heavily guarded against allowing guests any access at all, so I'm guessing at this, but I imagine you'd just need to make sure that the "Guest" member group has permission to post replies to topics checked. Also, you may need to check "Boards" in your admin panel (modify) and make sure that the boards in question allow guests to access them.

The first edit in the mod is simple enough, so I won't bother with that one.  The second edit (and this is just for the babylon Theme) is:

Find:

// Can they reply?  Have they turned on quick reply?

and add before:

      // How about replying at any point?

if ($context['can_reply'] && !empty($options['display_quick_reply']))
         echo '
                           <a href="', $scripturl, '?action=post;reply=', $message['id'], ';topic=', $context['current_topic'], '.', $context['start'], ';num_replies=', $context['num_replies'], ';sesc=', $context['session_id'], '" onclick="doReply(', $message['id'], ', \'', $context['session_id'], '\'); return false;">', ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/reply_sm.gif" alt="' . $txt[146] . '" border="0" />' : $txt[146]), '</a>';
      // So... quick reply is off, but they *can* reply?
      elseif ($context['can_reply'])
         echo '
                           <a href="', $scripturl, '?action=post;reply=', $message['id'], ';topic=', $context['current_topic'], '.', $context['start'], ';num_replies=', $context['num_replies'], ';sesc=', $context['session_id'], '">', ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/reply_sm.gif" alt="' . $txt[146] . '" border="0" />' : $txt[146]), '</a>';



I also added $respond_button to the global settings (in two places) to get rid of a forum error. 


I'm glad it's functioning for you.   :)
My apologies, but I am taking a break from accepting PM requests for support.  If I am not currently assisting you, please do not ask as long as this notice is posted.  Thank you.

I Don't Want To Grow Old Alone


It has been proven that Steely Dan reduces the occurrence of road rage, according to an independent study.



A reminder about admin / ftp passwords etc.

~DS~

"There is no god, and that's the simple truth. If every trace of any single religion were wiped out and nothing were passed on, it would never be created exactly that way again. There might be some other nonsense in its place, but not that exact nonsense. If all of science were wiped out, it would still be true and someone would find a way to figure it all out again."
~Penn Jillette – God, NO! – 2011

gbsothere

Quote from: Dismal Shadow on June 30, 2010, 10:48:58 PM
Duct tape for 2.0 RC3?  :P


The time has come for me to cave in and install an RC3 test board, today.   :D
My apologies, but I am taking a break from accepting PM requests for support.  If I am not currently assisting you, please do not ask as long as this notice is posted.  Thank you.

I Don't Want To Grow Old Alone


It has been proven that Steely Dan reduces the occurrence of road rage, according to an independent study.



A reminder about admin / ftp passwords etc.

gbsothere

Well, DS.......   it's Duct Tape, for sure.....  *grin*......   but I have it working for 2.0 RC3.  Well, one disclaimer.... if it's supposed to work with "quick reply", then I don't have that working, but the mod never really addressed quick reply, as far as I can tell.  If you have a reply button in every post, I suppose that eliminates the need for quick reply?

Nothing blew up and there are no errors.  (I'm shocked!)   Here's what I did:

In (Default) Display.template.php, find:

                // Can they reply? Have they turned on quick reply?

Add before:

            // Simple Reply Button
if ($context['can_reply'] && !empty($options['display_quick_reply']))
echo '
<li class="respond_button"><a href="', $scripturl, '?action=post;reply=', $message['id'], ';topic=', $context['current_topic'], '.', $context['start'], ';num_replies=', $context['num_replies'], '">', $txt['reply'], '</a></li>';




In (Default/css) index.css, find:

ul.quickbuttons li.reply_all_button
{
background: url(../images/theme/quickbuttons.png) no-repeat 0 -180px;
}


Add before:

ul.quickbuttons li.respond_button
{
background: url(../images/theme/quickbuttons.png) no-repeat 0 -180px;
}




(You might want to keep some "clean" copies from your server on standby, in case you smell smoke.)

:D
My apologies, but I am taking a break from accepting PM requests for support.  If I am not currently assisting you, please do not ask as long as this notice is posted.  Thank you.

I Don't Want To Grow Old Alone


It has been proven that Steely Dan reduces the occurrence of road rage, according to an independent study.



A reminder about admin / ftp passwords etc.

Advertisement: