4 tháng 10, 2008

Open window, Resize it after 1 second, then Close it after 6 seconds

on (release) {
getURL ("javascript:NewWindow=window.open('ShowPopup.php','newWin','width=400,height=300,left=0,top=0,
toolbar=No,location=No,scrollbars=No,status=No,resizable=No,fullscreen=No'); NewWindow.focus();
setTimeout('NewWindow.resizeTo(500,500)',1000); setTimeout('NewWindow.close()',6000); void(0);");
}
http://www.flash-db.com/PopUp/JavaScriptPopUp.php?page=1
http://www.flash-db.com/PopUp/JavaScriptPopUp.php?page=2
http://www.flash-db.com/PopUp/JavaScriptPopUp.php?page=3
http://www.flash-db.com/PopUp/JavaScriptPopUp.php?page=4
http://www.flash-db.com/PopUp/JavaScriptPopUp.php?page=5
-->đọc tiếp...

using popup in flash

on (release) {
getURL ("javascript:NewWindow=window.open('ShowPopup.php','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);");
}

The first part (Green) tells the browser that we will be sending it some JavaScript code. Then we define a new window object called 'NewWindow' This name is important because it will allow us to reference the popup window at later times. This does not have to have the name 'NewWindow' it can be anything as long as you keep it consistent. Then we use the window.open JavaScript command to open up a new window. This function contains a couple of options. The first is the target URL to the Page that you want to open inside the pop-up window. In this case that's 'ShowPopup.php'. The next option is to give the window a Name, the name of the window in this example will be 'newWin'. Then we have the option to include any of the following window parameters - shown by this part of the above code 'width=400,height=300,left=0,top=0,toolbar=No,location=No,scrollbars=No,status=No,resizable=No,fullscreen=No'. By changing around the numeric values and No to Yes you can control most of the features of the window. You can of course leave any or all of these properties out and they will then be set to their default values. Here is a description of each:

* width: A numeric value representing the width of the popup window
* height: A numeric value representing the height of the popup window
* left: A numeric value representing the left (X) position of the popup window
* top: A numeric value representing the top (Y) position of the popup window
* toolbar: A Yes / No value indicating whether to add a toolbar to the popup window
* location: A Yes / No value indicating whether to add the URL Location to the popup window
* scrollbars: A Yes / No / Auto value indicating whether or not to include scrollbars in the window
* status: A Yes / No value indicating whether to add the bottom Status/Loading part to your window
* resizeable: A Yes / No value indicating whether to allow the window to be resized once opened
* fullscreen: A Yes / No value indicating whether or not to open the window fullscreen. This will open a borderless full screen window in IE but will not work with Netscape.

Then we add the NewWindow.focus(); part, this ensures that the popup will be opened on top of all other windows. You can change this to NewWindow.blur(); (which is the opposite of focus except it pushes the window behind any other browser windows that are open. Then we close off the code by adding the void(0); portion.

As you can see that since we are able to add additional functions such as NewWindow.focus(); we will be able to add quite a few more functions and effects for this pop up window. The next part describes some of the more useful ones. Also their is no real need to place this script on a button - you can just as easily place it on a certain frame in your flash movie at a specific point you want your window to open. An example would be:

getURL ("javascript:NewWindow=window.open('ShowPopup.php','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);");

Just don't add the on (release) { portion. With this technique you can continue to open windows place at specific locations as your movie continues to play.
-->đọc tiếp...

1 tháng 10, 2008

change URL and Click Tracking with OpenX

change URL and Click Tracking with OpenX

In actionscript:
active_btn.onRelease = function(){
bannerid:Number = 6; // ma banner
zoneid:Number = 9; // ma zone
numRand = Math.floor(Math.random() * (999999999 - 999999)) + 999999;
// so ngau nhien tranh noi dung bi cache
_root.clickTAG = "http://222.255.237.117/Ads/www/delivery/ck.php?oaparams=2__bannerid="+bannerid+"__zoneid="+zoneid +"__cb="+numRand+"__maxdest=";
switch (mediaFile) {
case "http://222.255.237.118/ov_tn_vinatrack.flv":
_root.clickCus = "http://www.Vinatrack.com/";
break ;
case "http://222.255.237.118/ov_tn_acecook.flv":
_root.clickCus = "http://www.acecookvietnam.com/";
break ;
default:
//_root.clickTAG = null;
break;
}
getURL(_root.clickTAG+_root.clickCus,"_ovtech");
}
-->đọc tiếp...
BlogWeb: tạo từ Blog của Google
Nội dung: lấy từ nhiều Nguồn khác nhau.
Mục đích: note lại bài Hướng dẫn hay và Đáng đọc.
Kết quả: nghiện Internet Nặng.
Tương lại: xuống lỗ Vẫn Nghiện nếu không có ai giúp.
Blog Web của: Trí Dũng đến từ Việt Nam - Liên kết đến trang Blog Cá Nhân
Tôi biết (^_^)
Thông tin về Tác giả. Chi Tiết
Sử dụng (FireFox | Google Chrome on Ubuntu) để xem tốt nhất. Học Nhiều Hơn Tại Đây
©2009 Google Blogger - HuuNguyen's Home