PHP Warning: mysql_query(): Access denied for user 'root'@'localhost' (using password: NO) in ..../includes/class_postbit.php(265) : eval()'d code on line 2

PHP Warning: mysql_query(): A link to the server could not be established in ..../includes/class_postbit.php(265) : eval()'d code on line 2

PHP Warning: mysql_num_rows() expects parameter 1 to be resource, boolean given in ..../includes/class_postbit.php(265) : eval()'d code on line 3

PHP Warning: mysql_query(): Access denied for user 'root'@'localhost' (using password: NO) in ..../includes/class_postbit.php(265) : eval()'d code on line 2

PHP Warning: mysql_query(): A link to the server could not be established in ..../includes/class_postbit.php(265) : eval()'d code on line 2

PHP Warning: mysql_num_rows() expects parameter 1 to be resource, boolean given in ..../includes/class_postbit.php(265) : eval()'d code on line 3

PHP Warning: mysql_query(): Access denied for user 'root'@'localhost' (using password: NO) in ..../includes/class_postbit.php(265) : eval()'d code on line 2

PHP Warning: mysql_query(): A link to the server could not be established in ..../includes/class_postbit.php(265) : eval()'d code on line 2

PHP Warning: mysql_num_rows() expects parameter 1 to be resource, boolean given in ..../includes/class_postbit.php(265) : eval()'d code on line 3

PHP Warning: mysql_query(): Access denied for user 'root'@'localhost' (using password: NO) in ..../includes/class_postbit.php(265) : eval()'d code on line 2

PHP Warning: mysql_query(): A link to the server could not be established in ..../includes/class_postbit.php(265) : eval()'d code on line 2

PHP Warning: mysql_num_rows() expects parameter 1 to be resource, boolean given in ..../includes/class_postbit.php(265) : eval()'d code on line 3
detecting a keystroke? - Vista Help Forum

Go Back   Vista Help Forum » Web Design & Development » Programming
Reply
 
Thread Tools Display Modes
  #1  
Old 04-11-2008
Kolyn_Kryw's Avatar
Kolyn_Kryw Kolyn_Kryw is offline
neophyte
 
Join Date: Apr 2008
Posts: 3
Kolyn_Kryw is on a distinguished road
Send a message via ICQ to Kolyn_Kryw Send a message via Skype™ to Kolyn_Kryw
Arrow detecting a keystroke?

so considering i know nothing about programming, could this be done in vbscript?
would it be like pages of typing or is it simple
_________________
perfumes how to quit smoking

Reply With Quote
  #2  
Old 04-16-2008
awesomo awesomo is offline
Member - Class 3
 
Join Date: Jan 2007
Posts: 114
awesomo is on a distinguished road
Default

You should be use a onSubmit or onKeyUp or validation function tied to your form input. check out this quick bit below.

http://www.vbforums.com/archive/index.php/t-146017.html
Reply With Quote
  #3  
Old 06-02-2008
Mirey86's Avatar
Mirey86 Mirey86 is offline
neophyte
 
Join Date: Jun 2008
Location: canada
Posts: 3
Mirey86 is on a distinguished road
Send a message via ICQ to Mirey86
Default

Of course guy ,
Seems that you're just a designer and have just worked with web designer softwares .

The first thing you must specify is that which object you want to track it about keystroke ?
Is that your entire page ?
Is that just a textbox ?
is that a button ?
is that an image ?

let me take you the example about image ,which is the same as textbox and button (different from document) :

You've got this tag :
PHP Code:
<img src="http://examplesite/folder/image.png" onkeypress="imgKeyPressed()" /> 
the parameter "onkeypress" specifies the function that handles the event of "keypress".
If you've not studied math , a function is a set of commands that are applied to an input to produce and output . In this case , we've said that if key pressed "over this image" , do the actions speicifed in imgKeyPressed function .
Now let's keep on creating our function , Here's the vbscript code :
PHP Code:
<script language="vbscript" type="text/vbscript">
sub imgKeyPressed()
end sub
</script>
 
Now you've got to write your commands between sub .... and end sub .
For example to show user , which key's been pressed :
PHP Code:
<script language="vbscript" type="text/vbscript">
sub imgKeyPressed()
    
msgbox chr(event.keyCode)
end sub
</script>
 
This is all you need to write , But what if you want to specify the function for your entire document itself ?
PHP Code:
<script language="vbscript" type="text/vbscript">
body.document.onkeypress imgKeyPressed
sub imgKeyPressed
()
end sub
</script>
 
notice that at the end of bold line , I've not put the parentheses , In this case you've just got to specifiy the function name , and nothing else !

The final code that you should write is here :

For img, button, input, etc. :
PHP Code:
<img src="..." onkeypress="imgKeyPressed()" />
 
<
script language="vbscript" type="text/vbscript">
sub imgKeyPressed()
end sub
</script>
 
and for your document (anything that is being shown in explorer window , of course when your keyboard cursor is not in a textbox , or your mouse has not clicked on any object , in this case you've got write the above script for that object) :
PHP Code:
<script language="vbscript" type="text/vbscript">
document.onkeypress docKeyPress
sub docKeyPressed
()
end sub
</script>
 
Need further help ? I'm ready !
Reply With Quote
  #4  
Old 09-12-2008
awesomo awesomo is offline
Member - Class 3
 
Join Date: Jan 2007
Posts: 114
awesomo is on a distinguished road
Default

Great example/post Mirey86. pos+ rep!
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Windows Vista is not detecting Broadcom 802.11 adapter after intalling Vista SP1 sagar_gupta Vista Networking Forum 0 03-25-2008 08:22 PM