Ricky Elrod

Navigation

Skip navigation.

Search

Site navigation

Email conversation

FromRicky Elrod
ToMe
SubjectDragable layers question used with possibly another script??
Date7 May 2006 03:27
Attachmentdemo page and image of a mini window script
Hello.I am trying to make an OS simulation site.
Heres the script of the icon, dragable layer. Again, this is supposed to be
an icon.

createDragableLayer(
  '<a onmouseout=MM_swapImgRestore("icon1","","../sun.jpg",0) '+
  'onmouseover=MM_swapImage("icon1","","../sun.jpg",0) '+
  'ondblclick="____________"><img src="../mr smith.jpg" name="icon1" '+
  'alt="" width="117" height="94" border="0" id="icon1"></a>',
 100, 149, 'drag_1installer')

Now on double click, I want it to open a popup script. How do i point it to
the particular popup window? I have the popup script already  (unless you
have one that would be easier to use)

Heres the script for that.    the main script is in another file (popup.js)
and I am attaching all of the files in a zip.


<script language="javascript">

window.onload=function(){

// welcome
new popUp(200, 200, 370, 175, "Welcome", "Hello! Welcome to the OS "+
 "simulation side of my site! As you may recall, way back when I first "+
 "got into web design, I desided to do something like this. Well now it "+
 "has happened! I hope you enjoy it!  <br><i>[brand]</i>", "#00385c",
 "lightgrey", "9pt sans-serif", "Welcome!", "silver", "lightgrey", "gray",
 "black", "black", true, true, true, true, false, false,'min.gif',
 'max.gif','close.gif','resize.gif');

}
</script>

Attached is a zip file of the popup script and a picture of what I am
talking about.
Thanks a million.
Ricky
FromMe
ToRicky Elrod
SubjectRe: Dragable layers question used with possibly another script??
Date8 May 2006 13:29
Ricky,

Should be as simple removing the onload function, then using this:
ondblclick="new popUp(...etc...);"
although that is going to get messy with lots of content, so I suggest you
do this:

<script type="text/javascript">
function openFoo() {
  new popUp(...etc...);
}
</script>
...
ondblclick="openFoo();"


Mark 'Tarquin' Wilton-Jones - author of http://www.howtocreate.co.uk/
FromRicky Elrod
ToMe
SubjectRe: Dragable layers question used with possibly another script??
Date9 May 2006 00:18
Didn't really help.

Where do i put the

window.onload=function(){     ??????

I'm new to this, sorry
FromMe
ToRicky Elrod
SubjectRe: Dragable layers question used with possibly another script??
Date9 May 2006 11:06
Ricky,

> Where do i put the
>
> window.onload=function(){     ??????

You don't. That part is not needed any more.

If you need further help with how to use the popup script, I suggest you
contact the author of that script, as they will be in a much better position
to help you. Their contact details are in the top of the popup.js file.

However, I will warn you that is is a poorly written script. Several of its
features - such as fading - break in Opera and Safari, without any good
reason. It uses a stupid and inaccurate sniffer script that misidentifies
browsers, and then it incorrectly applies opacity using filters in Opera
(and IE), and the MozOpacity style instead of the standard opacity
(supported by Opera 9, Safari 1.2 and Mozilla/Firefox).

If you contact the author, I suggest you also ask them if they can fix these
issues.
FromRicky Elrod
ToMe
SubjectRe: Dragable layers question used with possibly another script??
Date9 May 2006 12:16
I'm willing to try new, you have a better script???

Thanks
FromMe
ToRicky Elrod
SubjectRe: Dragable layers question used with possibly another script??
Date9 May 2006 12:25
> I'm willing to try new, you have a better script???

I have my own script, but it is certainly not as functional or attractive as
that one. It is best to contact the author of the script, and ask them to
fix the sniffing problems, and opacity problems.
FromRicky Elrod
ToMe
SubjectRe: Dragable layers question used with possibly another script??
Date16 May 2006 02:03
Now I'm getting a weird result. It works (opens the popup on double click),
but then i click the title of the popup, it moves across the top of the
screen with the mouse........  no matter where I move the mouse.  but the
popup stays on the top. aligned with the mouse on the bottom, etc.

Interesting.. If you cant help, i will contact the script creator.

Thanks
FromMe
ToRicky Elrod
SubjectRe: Dragable layers question used with possibly another script??
Date16 May 2006 09:11
Ricky,

> Interesting.. If you cant help, i will contact the script creator.

heh, sounds like a fun bug, but yes, you will have to contact the script
author, since I do not know their script at all.
This site was created by Mark "Tarquin" Wilton-Jones.
Don't click this link unless you want to be banned from our site.