|
Author |
Message |
CJM
Junior WebHelper

Joined: 07 Jan 2005
Posts: 1
|
Posted:
Fri Jan 07, 2005 6:32 pm (18 years, 2 months ago) |
  |
Hi all,
I am relatively new at this javascript thing having only taught it to myself in the last couple weeks and I just learned HTML a few months ago, but i have come across a problem.
I want to change the cursor to an hourglass while a function that takes a few seconds is running.
This is what the code looks like
<SCRIPT LANGUAGE="javascript" TYPE="text/javascript">
...
function cursorChangeOn() {
document.body.style.cursor = "wait";
}
function cursorChangeOff() {
document.body.style.cursor = "default";
}
function retrieveData(){...}
function timeout() {
setTimeout("retrieveData();cursorChangeOff()",10)
}
...
</SCRIPT>
</BODY>
...
<input name="button" type="button" onClick= "cursorChangeOn();timeout()" value="Retrieve Data">
I also am not sure if you are aloud to call more than one function after an onClick command. If there is a easier way to do this or is there something wrong with the code i would appriciate the help.
Thank you. |
|
|
    |
 |
ScottB
Junior WebHelper

Joined: 04 Jul 2005
Posts: 4
Location: Britain
|
Posted:
Mon Jul 04, 2005 1:39 pm (17 years, 8 months ago) |
  |
I wont go into any javascript as I'm not exactly an expert, but I do know you can change the cursor using CSS and the cursor property.
e.g.
Code: |
<style type="text/css">
div:hover{ cursor:wait }
</style>
|
Alternativly you could change the cursor when the mouse or keyboard do something, using onload or something simular:
Code: |
<p onmouseover="this.style.cursor='wait'" onmouseout="this.style.cursor='default'" />
|
I know it's probably not what you looking for but I hope it's helpful. |
|
|
     |
 |
Vitopa
Junior WebHelper

Joined: 26 Feb 2015
Posts: 12
Location: Ellicott City, Md.
|
Posted:
Fri Jul 10, 2015 5:28 pm (7 years, 8 months ago) |
  |
Ok, ive been looking everywhere in the files to see if there is a way to change that random pitch sound effect with the menu cursor in SSHD and i cant find it. Does anyone in SZ know how to do it? |
|
|
        |
 |
|
|
You cannot post new topics in this forum. You cannot reply to topics in this forum. You cannot edit your posts in this forum. You cannot delete your posts in this forum. You cannot vote in polls in this forum.
|
Page generation time: 0.216975 seconds :: 19 queries executed :: All Times are GMT
Powered by phpBB 2.0
© 2001, 2002 phpBB Group :: Based on an FI Theme
| |