|
-
Feb 3rd, 2010, 09:07 AM
#1
Thread Starter
New Member
[RESOLVED] How to do a vertical and horizontal line?
Hello! I'm trying to do something, but without sucess.
How to do a vertical and horizontal line centered on mouse pointer, but using javascript?
Anyone knows any code that do this? Or where can I find it?
I will appreciate any help.
Thanks! 
Alan
-
Feb 3rd, 2010, 09:34 AM
#2
Fanatic Member
Re: How to do a vertical and horizontal line?
edit: i don't know why but i didnt get the part of the mouse pointer.. but css would be enough
Edit: didn't notice you're new, welcome to the forums
if you got what you needed then please mark the thread as resolved by going to thread tools and mark thread as resolved.
Last edited by Justa Lol; Feb 3rd, 2010 at 10:40 AM.
-
Feb 3rd, 2010, 10:04 AM
#3
Re: How to do a vertical and horizontal line?
I assume you mean like having a crosshair cursor.
If you Google "Crosshair cursor + javascript", you'll find tons of examples on how to do what you need.
For example: http://www.webtoolkit.info/javascrip...om-cursor.html
-
Feb 3rd, 2010, 10:24 AM
#4
Re: How to do a vertical and horizontal line?
Ugh, folks - CSS! Javascript should only ever happen for things you can't do with ordinary markup and styling.
Code:
body{cursor:crosshair;}
Are you familiar with CSS, iuky? If not, I will definitely explain the above in more depth.
-
Feb 3rd, 2010, 10:35 AM
#5
Re: How to do a vertical and horizontal line?
 Originally Posted by SambaNeko
Ugh, folks - CSS! Javascript should only ever happen for things you can't do with ordinary markup and styling.
Code:
body{cursor:crosshair;}
Are you familiar with CSS, iuky? If not, I will definitely explain the above in more depth.
I had always thought the cursor property didn't work in Firefox, but looking into it I can't find any documentation on that.
Do you know if there was ever an issue for it? I coulda swore there was once upon a time.
*edit* ah, it seems it is only for certain values that it fails. Crosshair is one that works across all browsers.
-
Feb 3rd, 2010, 10:41 AM
#6
Fanatic Member
Re: How to do a vertical and horizontal line?
only custom cursors don't work, the system cursors will work, i mean those who are selected as default for pointer, link, crosshair... whatever..
-
Feb 3rd, 2010, 12:20 PM
#7
Thread Starter
New Member
-
Feb 3rd, 2010, 12:37 PM
#8
Re: How to do a vertical and horizontal line?
-
Feb 3rd, 2010, 02:54 PM
#9
Thread Starter
New Member
Re: How to do a vertical and horizontal line?
 Originally Posted by kows
Thanks everybody and thanks Kows, it's exactly what I want.
Bye!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|