MyBB Community Forums

Full Version: DVZ Shoutbox - Add Submit button next to the message field
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
This tutorial will show you how you can add "Submit" button next to the message field. I don't know ofr older versions of this plugin, but in latest version Submit button is displayed below message field, in my opinion looks bad like that. So, if anyone else ever wanted to do this but didn't knew how, now you can do that with these few simple steps.

Picture preview: https://prnt.sc/sd585k

Step #1
Go to Admin Control Panel > Templates & Style > Templates > Global Templates > dvz_shoutbox_panel

Step #2
Find: 
<input type="text" class="text" placeholder="{$lang->dvz_sb_default}" maxlength="{$maxlength}" autocomplete="off" />

and above that line paste this code:
<div style="overflow: hidden; padding-right: .5em;">


Step #3
Find and remove this line:
<input type="submit" style="display:none" />

Step #4
Find this line (You added it in step #2):

<div style="overflow: hidden; padding-right: .5em;">

and above that add this piece of code:
<input type="submit" class="button" style="float:right;" value="Send">

Done! The final template should look like this:
<div class="panel">
<form>
<input type="submit" class="button" style="float:right;" value="Send">	
<div style="overflow: hidden; padding-right: .5em;">
<input type="text" class="text" placeholder="{$lang->dvz_sb_default}" maxlength="{$maxlength}" autocomplete="off" /> 
</div>
</form>
</div>
Well done!

If I can give a suggestion, it would be better to hide the submit button and put a button through which you get a modalbox with all available smilies.

<a href="javascript:MyBB.popupWindow('/misc.php?action=smilies&amp;popup=true&amp;editor=message_input&amp;modal=1')" title="smilies">smilies</a>
(2020-05-08, 08:45 PM)Xalysis Wrote: [ -> ]Well done!

If I can give a suggestion, it would be better to hide the submit button and put a button through which you get a modalbox with all available smilies.

<a href="javascript:MyBB.popupWindow('/misc.php?action=smilies&amp;popup=true&amp;editor=message_input&amp;modal=1')" title="smilies">smilies</a>

Thanks for your suggestion, but it won't work that way. Already tested. Beside that, there are already tutorials how to add smileys.
self solved