I'm trying to use an onmouseover event to change the cursor to a custom .cur image.
onMouseOver="th is.style.cursor ='icons/cursor.cur';"
The above code works fine in IE but not in Firefox. It's important the users know where they can click.
Could anyone help please?
Nov 24 '09
19 7252 gits 5,390
Recognized Expert Moderator Expert
so using the pointer should be sufficient ... since it shows the standard 'here you can click' cursor? ... i'm not quite sure whether I would use another cursor or image except I would need it for a browser based game ... or why is it essential to have another custom cursor?
kind regards
I can use the pointer but using the custom cursor just helps remind us whether we are logged in as user or administrator.
It don't suppose it's essential but it does improve the look. I just thought it should be possible.
acoder 16,027
Recognized Expert Moderator MVP
I may be wrong, but I think you need to specify a default, e.g. "auto" or "default" for the custom cursor to work, e.g. - onmouseover="this.style.cursor=\"url(icons/cursor.cur),auto\";"
You could also consider using CSS only with "hover".
gits 5,390
Recognized Expert Moderator Expert
in case it would be essential then have a look here and see if it helps ... but for your specific purpose personally i just would apply another style to the app's background-color or something more visible as a cursor ...
kind regards
PS: ahh ... try acoder's hint first ... may be it helps? ... as i said before ... i never used custom cursors before :)
Is .cur a proprietary M$ format that only IE supports?
rnd me 427
Recognized Expert Contributor @DMsy2
yes and no.
.cur is basically a monochrome bitmap, so it may be viewable when loaded as a bmp, which many browsers handle.
Firefox allows .cur since 2.0 according to MDC, this is your best bet:
Thanks for all your help, acoder's solution of adding the defualt afterwards works. Adding the url(***.cur) stopped working in IE but when I added the default it worked again in IE and now works in Firefox.
Many thanks all,
I now have it working in IE, Firefox, Safari and Google Chrome. Any ideas how to get it working in Opera?
acoder 16,027
Recognized Expert Moderator MVP
I don't think Opera supports custom cursors.
I also have a similar problem but it's work for me when i entered the full path to the cursor file.
Sign in to post your reply or Sign up for a free account.
Similar topics |
by: Simon Wigzell |
last post by:
I have an image with several links in it in mapped areas. I am using a
custom cursor on the page and would like to have a custom cursor appear on
mouse over of the mapped links. Something like:
This works for the body, font or img tag:
<body style="cursor: url('cursor2.cur')">
<font style="cursor: url('cursor1.cur')">Text</font>
<img style="cursor: url('cursor1.cur')" src="...etc...">
|
by: VK |
last post by:
I have this code failing to work in IE: getElementsByTagName doesn't
return elements from my JS namespace. What's wrong?
<html xmlns:js>
<head>
<title>Que</title>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
|
by: piccolo |
last post by:
This is the first time I've posted a 'help' request, so please be patient.
I've created a DOM web page where with the usage of usemap images on the page change upon rollover using JavaScript. Other than href, is there a way to make the cursor change upon rollover?
Only when a particular area has been clicked on do I wish for others to react to a rollover. This is all done in JS within the same page, and it works - except for the mouse...
|
by: Andy Baxter |
last post by:
hello,
I'm writing a panoramic image viewer in javascript. When the mouse is over
the image, I want it to be a crosshair (over most of the image), or a
hand/pointer (when it's over an image map region). The image map is
created in javascript, but doesn't set any 'cursor' style rules.
The problem I'm having is I have two images embedded inside two divs. The
outer div has style='... cursor:crosshair', but when I move over the image...
|
by: mrsd2c |
last post by:
I am building custom attributes as a means to pass data from the client
to the server. To accomplish this task, a class of "postback" is
applied to a link or button. When the link or button is clicked,
custom attributes are parsed from the link and submitted to the
application as hidden form fields. The code below better illustrates
the HTML:
<a class="postback" c:myAttribute1="value"
c:myAttribute2="value">submit</a>
| |
by: mshankar |
last post by:
hi, friends any one know the solution for how to set the image to a cursor in firefox using javascript
i know to set this
by using stylesheet
cursor :url("ravishankar.cur"),pointer
but using javascript depending the requirement can we change or assign the image cursor ?
help me
if any one knows the solution for this .
bye
Ravishankar Maduri
|
by: ryezack |
last post by:
i have an image map with an onmouseover event thats calls a javascript function style cursor is hand. this works in IE but not in firefox. here's the code:
<script type="text/javascript">
<!--
function onMouseOver() {
document.body.style.cursor="hand";
}
function onMouseOut() {
document.body.style.cursor="default";
|
by: Klaus Brune |
last post by:
Hello all,
When one tabs through a form (specifically, in Firefox), all the text in
a field is automatically selected.
What I'm looking for is a way to put a function (in onFocus perhaps)
that will automatically move to the END of the existing text (a blinking
cursor).
Yes, I've Googled, but cannot seem to locate just what I'm looking for.
|
by: Prisoner at War |
last post by:
Hello, Everyone:
Is there any other values or whatever-it's-called to the cursor
property in CSS??
So far, I only know of cursor:pointer (or, for MSIE, cursor:hand)....
Any way to load in one's own somehow??
Just a noob at this...TIA!!
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
| |
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |