how to disable fields

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
itsmani1
Forum Regular
Posts: 791
Joined: Mon Sep 29, 2003 2:26 am
Location: Islamabad Pakistan
Contact:

how to disable fields

Post by itsmani1 »

hi there....

i want to create a timer on clint end for one to 20 minutes and 2nd thing i want is to disable pasting something in text field:

can i do that using php?


Regards!
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

1. that's Javascript, not PHP. Hint: setTimeout()
2. if you want to disable a field entirely from being typed in (at all) ..

Code: Select all

<input type="text" name="hi" value="I am read-only" disabled="disabled" />

...and check your private messages. :?
Post Reply