Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 315
  • Last Modified:

adding javascript URL to Flash button

Hello

I was given a URL that will popup a chat session window. I'm not sure exactly how to enter the code in the AS. I have created a button with UP/Over/Down/Hit

The URL is listed below:
<!-- Presence aware IM link for Contact Page placement. -->
<A onclick="javascript:window.open('http://dm2.contactatonce.com/CaoClientContainer.aspx?MerchantId=29199&ProviderId=2573&PlacementId=3&OriginationUrl='+encodeURIComponent(location.href),'','resizable=yes,toolbar=no,menubar=no,location=no,scrollbars=no,status=no,height=400,width=600');return false;"href="#"><img onerror="this.height=0;this.width=0" src="http://dm2.contactatonce.com/getagentstatusimage.aspx?MerchantId=29199&ProviderId=2573&PlacementId=3" border="0"></A>

Open in new window

0
Trevor Local
Asked:
Trevor Local
  • 6
  • 6
1 Solution
 
GawaiCommented:
in getURL() u can use that
or also in LoadVars()
ref
http://www.flash-db.com/PopUp/JavaScriptPopUp.php?page=4
0
 
Trevor LocalAuthor Commented:
so do I place the entire code in between the () in the getURL? including the comment section?
0
 
GawaiCommented:
no need of comment line :)


on (release) {
getURL ("javascript:NewWindow=window.open('http://www.yoursite.com/somepage.php?somequerystring=somevalue','newWin','width=400,height=300,left=0,top=0,
toolbar=No,location=No,scrollbars=No,status=No,resizable=No,fullscreen=No');  NewWindow.focus();
void(0);");
}

Open in new window

0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
Trevor LocalAuthor Commented:
ok I'm missing something. I tried this code:
left out the comments and the <A onclick=
on (release) {
getURL ("javascript:window.open('http://dm2.contactatonce.com/CaoClientContainer.aspx?MerchantId=29199&ProviderId=2573&PlacementId=3&OriginationUrl='+encodeURIComponent(location.href),'','resizable=yes,toolbar=no,menubar=no,location=no,scrollbars=no,status=no,height=400,width=600');return false;"href="#"><img onerror="this.height=0;this.width=0" src="http://dm2.contactatonce.com/getagentstatusimage.aspx?MerchantId=29199&ProviderId=2573&PlacementId=3" border="0">
}

Open in new window

0
 
GawaiCommented:
javascript:NewWindow=window.open
0
 
Trevor LocalAuthor Commented:
tried adding that - nothing pops up.
0
 
GawaiCommented:
u need to remove <img......>
and let me know. can i see that online ? let me know the site url
0
 
Trevor LocalAuthor Commented:
my site: http://cls63.brinkster.net/index.html
on the Financing page and the Contact page, there's a button to pop up a chat window function.

0
 
GawaiCommented:
try this one, either remove
&OriginationUrl='+encodeURIComponent(location.href)

or you can have :
&OriginationUrl=http://cls63.brinkster.net

 
on (release) {
getURL ("javascript:NewWindow=window.open('http://dm2.contactatonce.com/CaoClientContainer.aspx?MerchantId=29199&ProviderId=2573&PlacementId=3','newWin','width=600,height=400,left=0,top=0,toolbar=No,location=No,scrollbars=No,status=No,resizable=Yes,fullscreen=No');  NewWindow.focus(); void(0);");
}

Open in new window

0
 
Trevor LocalAuthor Commented:
I used the code you just gave- I think that's it! Will do some testing and let you know.
thanks!!
0
 
Trevor LocalAuthor Commented:
thanks for the help!!
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 6
  • 6
Tackle projects and never again get stuck behind a technical roadblock.
Join Now