[Durham] Spare RAM

Scott Wilcox sc0tt at x0f.org
Sat Jun 20 12:07:48 UTC 2009


I got it working :)

It ended up being pretty complex but actually works quite well!

Thanks for your reply though Oliver, it was very appreciated!

Scott.

On 17/6/09 20:54, Oliver Burnett-Hall wrote:
> On 17/06/2009, Scott Wilcox<sc0tt at x0f.org>  wrote:
>    
>> Now, when pulling the points of the note box, I have the x,y relative to
>> the image itself. I'm trying to grab the position of the parent element
>> then adding that to the x,y to give me the final position.
>>
>> The problem is that when I'm trying to get the position of the parent
>> element, I'm getting different results in browsers and the locations are
>> off by about 50px;
>>      
>
> It's a long time since I've done much browser-based Javascript (I was
> hoping that you'd have a language query!), so I'm not sure how much
> I'll be able to help with this.
>
> How are you attempting to do this?  And what browsers does this need
> to work on?  There are quite a lot of rendering issues that you could
> be running into.  And things get much, much harder if IE5 is a target
> browser.
>
> The way I'd approach this problem (which is probably not the right
> way) is to forget Javascript for a while, and work on getting a CSS
> style that can correctly position a<div/>  element relative to the
> image on all target browsers.  Write a static HTML page and tweak
> until it works.  When you've got this, all you'll have to do is use
> Javascript to fetch the coordinates and information to be displayed,
> then created the div and style it, offsetting it as required.
>
> - olly
>
> _______________________________________________
> Durham mailing list   -   Durham at mailman.lug.org.uk
> https://mailman.lug.org.uk/mailman/listinfo/durham
> http://www.nelug.org.uk/
>
>    
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.lug.org.uk/pipermail/durham/attachments/20090620/6fe37b31/attachment.htm 


More information about the Durham mailing list