TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

Members
  • Total Members: 3,963
  • Latest: BiZaJe
Stats
  • Total Posts: 195,917
  • Total Topics: 21,308
  • Online today: 884
  • Online ever: 8,223 (February 19, 2025, 04:35:35 AM)
Users Online
  • Users: 0
  • Guests: 332
  • Total: 332

Shoutbox - Pressing 'enter' to post

Started by VanKlomp, November 05, 2010, 08:03:03 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

VanKlomp

Hello

Apologies if this has been posted but I can't find it.

I want to amend the shoutbox so that when a user presses 'enter' it posts, instead of moving to the next line.

I know I'll have to apply this change when I upgrade in future, but this is how my old shout box worked and for ease of use for my users I want to copy that behaviour.

Thanks

V

IchBin

It does this because < textarea > are meant to have more than one line of text. If you don't want to change the textarea to an <input type="text" /> then you'll need to add some javascript to do this. Something like what is suggested on this page.
http://www.codingforums.com/archive/index.php/t-146505.html

You'll need to add it most likely to the Themes/default/TPShout.template.php file.

This website is proudly hosted on Crocweb Cloud Website Hosting.