how do i limit this textfield to three words?

<input type='text' size='40' name='search' style='font-size:16px; font-family:Arial;font-weight:bold;' />

i only want three words to be allowed entered.

Hi,

You need to play with javascript.

This code may help you.


Thank you.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.