You are here: Re: form character counter help « PHP Language « IT news, forums, messages
Re: form character counter help

Posted by Janwillem Borleffs on 11/05/05 15:50

Joker7 wrote:
> Question is the away to do what the Java Script below is doing but in
> PHP as I don't like using Java Script if I can help it.
> I need a way to count and show the user of the form how many
> characters are left.
>

JavaScript = (most of the cases) client side & PHP = server side;

The stuff you are doing with JavaScript can only be done by PHP by sending
regular calls to the server, where PHP validates the input. These calls need
to be triggered by JavaScript, so apart from the fact that the server will
be called frequently, this solution will not be very practical.

The best thing you can do is put both the JavaScript and server side PHP
validation in place. When JavaScript is enabled on the client, it does its
stuff and the PHP script on the server will complement the validation.


JW

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация