WO2004070579A2 - Method for laying out multimedia advertisements - Google Patents

Method for laying out multimedia advertisements Download PDF

Info

Publication number
WO2004070579A2
WO2004070579A2 PCT/US2004/003103 US2004003103W WO2004070579A2 WO 2004070579 A2 WO2004070579 A2 WO 2004070579A2 US 2004003103 W US2004003103 W US 2004003103W WO 2004070579 A2 WO2004070579 A2 WO 2004070579A2
Authority
WO
WIPO (PCT)
Prior art keywords
var
document
window
function
style
Prior art date
Application number
PCT/US2004/003103
Other languages
French (fr)
Other versions
WO2004070579A3 (en
Inventor
Manuel Caballero
Alberto Nakayama
Ramiro Repetto
Maria Jimena Ilarregui
Patricia Alejandra Fernandez
Moises Swiczar
Nicholas Agnese
Original Assignee
Porto Ranelli, Sa
Pi Trust
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Porto Ranelli, Sa, Pi Trust filed Critical Porto Ranelli, Sa
Publication of WO2004070579A2 publication Critical patent/WO2004070579A2/en
Publication of WO2004070579A3 publication Critical patent/WO2004070579A3/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/02Marketing; Price estimation or determination; Fundraising
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/10Text processing
    • G06F40/103Formatting, i.e. changing of presentation of documents

Definitions

  • the present invention relates generally to a method for laying out online advertisements over content. It allows for the graphical layout of ads over specific web pages or templates, eliminating guesswork and simplifying previews.
  • the invention is a solution to the problem of arranging dynamic ads over dynamic pages.
  • the Internet includes servers (computers), which offer electrical communication to client computers (operated by users) and to other servers.
  • the computers involved may range from mainframes to cellular telephones, and they may operate over any conceivable communication medium.
  • GUI graphic user interface
  • Most users connect to the Internet (or "surf the net") through a personal computer running an operating system with a graphic user interface (GUI), such as one of the Windows® operating systems.
  • GUI graphic user interface
  • Most users communicate over the Internet using a program called a "browser” running on their computers, the two most popular ones being Internet Explorer and Netscape, although many other browsers are in common use.
  • the browser receives files in a format known as HTML, which is a mark-up language that permits multimedia to be embedded within formatted and stylized text, and it displays "pages", which may play sound and exhibit graphics and video. Narious programming languages, such as JavaScript, are also available which permit executable code to be embedded in an HTML file and to run, performing useful tasks when a browser presents the file to the user's computer.
  • the present invention permits untrained persons with little or no technical experience, while operating a special purpose, layout computer program, to overlay the ad on the background page(s), by simply dragging the ad into position.
  • this computer program is accessed in the form of executable code on a web page. This is a much simpler procedure than the old way, which entailed understanding display coordinates and a non-intuitive trial-and-error process of testing the ad and modifying coordinates, until the desired result was achieved.
  • a user connects with a layout application server through his browser and receives an HTML page containing content and executable code.
  • the user selects the HTML page or template (or any other multimedia content) over which the ad is to be previewed and laid out, as well as the ad itself.
  • a copy of the selected HTML page, and the ad are then loaded onto the layout application server, and through a proxy server, the host page (content) is modified to show the ad overlying the selected HTML page and by inserting executable code, which will result in the addition of a control toolbar and menu system.
  • the control toolbar is inserted on the page by way of an IFRAME, and the ad itself through an OBJECT.
  • the user is then presented with the modified HTML page, which includes the content, the ad overlying it, and a toolbar for controlling various features and parameters.
  • Each element —content, toolbar and ad- is placed in an independent layer within the same web page display. It should be noted that the toolbar is placed in an IFRAME so that it can float above all other elements and be accessible at all times. It should also be noted that prior to the present invention, overlaying
  • layer ads (as well as many other types of ads) required working in separate windows: first selecting features and modifying parameters, and later previewing the results in another window.
  • the code inserted by the proxy server application into the host or content page allows for the control of the ad and its interaction within the page.
  • the user can graphically and intuitively control several parameters including (but not limited to) ad size, location, positioning method, length, and even the order ofthe HTML layers.
  • the parameters are saved in a database and are used to generate JavaScript code that will control the ad when served to the end user.
  • the saved parameters could include: position and positioning method, size and length of, objects on the page. These are relevant and affect features -like drop down menus that may need to be hidden or flash objects that must be prioritized in the z (layer) coordinate.
  • Fig. 1 is a flow chart illustrating an embodiment of a process for laying out an ad on a web page
  • Fig. 2 illustrates the data flow among the various parties involved in the process
  • Fig. 3 is a screen shot showing the process in use.
  • Figure 1 is flowchart illustrating the method ofthe invention.
  • Logic flow begins at block 100, and at block 110, the user selects the page or template over which the ad will be laid out.
  • the ad itself is selected.
  • the proxy server downloads the selected HTML code representing the page on which the ad is to appear, and at block 140 executable code is inserted onto the page.
  • a documented listing of this executable code is provided in Appendix A.
  • the modified HTML is displayed on the user's computer, now including the selected ad and the toolbars and palettes in its window over the page that contains the ad.
  • Figure 3 is a screen shot showing the display on the user's computer, including the representation of the page to receive the ad 300, with the ad 310 superposed over it, and the toolbar 320 and the menu 320' on the top layer.
  • the ad is a character resembling a soccer player, the portions of the ad window outside the player, so that the player alone will appear on the page.
  • the framing rectangle ofthe ad represents the area occupied by entire ad being transparent
  • the toolbar exhibits a number of icons, any of which may be activated by clicking a mouse or other pointing device on them.
  • the menu includes a number of similar control elements, three of which have been represented by the characters a, b, and c, which may be clicked upon to achieve certain actions on the display. For example, clicking on element a brings up a sub-menu of menu 320' that permits the user to hide an object or portion ofthe content page 300, clicking on element b brings up a sub-menu that permits the user to position the ad 310, and clicking on element c brings up a submenu that permits the user to size the ad 320.
  • the element c has been clicked previously, and the submenu for resizing is being displayed. Resizing is achieved by clicking on and dragging the rectangular strip 330 at the bottom ofthe ad.
  • the ad may be positioned in the positioning menu in a similar fashion.
  • the user lays out the ad using the toolbar by dragging the ad into position by its handle (the bar across the bottom of the window).
  • the resulting parameters which have been stored, are used to generate JavaScript code that, when executed, will position and control the ad on the actual page, as defined by the user.
  • the code may be generated at the user's computer and uploaded to the application server, or the parameters may be uploaded to the server and the code generated there.
  • the process ends at block 180.
  • Figure 2 depicts the signal or data flow between the following:
  • Web browser W, - used by End User
  • Web server S, — communicates with web browser
  • Application Server A, - hosts proprietary ad layout application
  • Database server D, - parameters and code
  • File server, F, - holds media files; and Third party content server, C, - a publisher or content provider.
  • Data flow 1 indicates the data entered by the user being sent to the web server via his browser.
  • the data entered by the user is then sent to the application server by the web server (data flow 3).
  • Data flow 4 indicates the application server requesting the chosen background page (HTML document) from the content server. Then, the content server delivers the background page to the application server (data flow 5).
  • the application server requests the ad from the Database D and the File server F (data flow 6), and the database and file server deliver the ad to the application server (data flow 7).
  • the application server inserts the executable code that displays the selected ad and the toolbar onto the saved HTML, the new web page is sent to the web server (data flow 8), which sends the modified code to the web browser, for display.
  • the User sets up the ad and enters all parameters; the resulting data is sent to the web server (data flow 10) then on to the application server (data flow 11).
  • the application server generates Javascript code to control and position thread according to the parameters, which code is sent to the database (data flow 12). From there, it can be served in a number of standard ways. Commented code for the preferred embodiment is presented in
  • Module 1 creates the interface and features as seen in Figure 3. It is responsible for displaying and operating the ad, the background page and the toolbar during the lay out process. The operation and use of this module results in the generation of a string of characters such as the following:
  • This string represents the parameters generated as the user manipulates the ad.
  • Module 2 is a Code Generator. Using the data contained in the above string, this module assembles a Timeline code, which represents the time sequence of the operation ofthe ad as created by the user. The information contained in the suing mentioned above is codified using a JavaScript function named escape (). Once decoded, the following values are extracted and used by the code generating module as parameters for the timeline.
  • Type ⁇ POS_TYPE ⁇ fixed (values can be: centered, anchor) Top ⁇ POS_TOP ⁇ : -9 Left ⁇ POSJ.EFT ⁇ : 128
  • HIDE_1_TAG ⁇ IMG (IMG/IFRAME/OBJECT/A/SELECT/INPUT) Index ⁇ HIDE JNDEX ⁇ : 1
  • LS ⁇ LS_FLAG ⁇ : 1 Module 3 is a typical Timeline code to control the operation ofthe ad.
  • servers F, A, D and, although shown separate, need not run on separate computers. That is, two or more ofthe servers may reside on the same computer.
  • the application proxy retrieves the HTML code from the selected background page and adds 3 tags . 1 toolbar. asp
  • font 'verdana ; font-size: 75%; height : 18px; width: 60; ⁇
  • This iframe will be used later to assemble the code generating sub-module
  • parent .window. chescrollHeight parent .document .body. scrollHeight ; parent .window. theScrollWidth parent .document .body. scrollWidth;
  • Querystring use explanation window. qs is the variable containing info on the Shoshkele configuration. This info is sent from the previous module through the querystring (The querystring is behind the ? character in an URL)
  • the querystring includes only internal campaign info is sent to be saved again after editing.
  • buttonsPos ( ) are shown, allowing for different users to access different features.
  • PVFORM. swfSize.value + " kb" ;
  • PVFORM. fixtop.value qs.top
  • PVFORM. fixleft. alue newX
  • PVFORM. fixtop.value newY
  • IdMediaDet queryString_readVar (parentQS , "IdMediaDet” ) toReturn.
  • IdCreative queryString_readVar (parentQS, "IdCreative”); toReturn.
  • IdCreativeProps queryString_readVar (parentQS, "IdCreativeProps") ; toReturn.
  • IdAnimationFile queryString_readVar (parentQS,
  • IdAnimationFile queryString_readVar (parentQS, "IdBannerFile”); toReturn.
  • Flaco queryString_readVar (parentQS, "Flaco”); toReturn.
  • LS parselnt (queryString_readVar (parentQS, "LS")); toReturn.
  • fSize parselnt (queryString readVar (parentQS, "fSize”));
  • var paramsl unescape (queryString_readVar (parentQS , "paramsl” )) ;
  • var params2 unescape (queryString_readVar (parentQS, "params2” ) ) ;
  • queryString__toArray (toReturn, paramsl) ; queryString_toArray (toReturn, ⁇ arams2) ,-
  • ⁇ var resto url . substring ( index + qsVar. length + 1, url . length) ;
  • PERSONJREVERSE new Array ( ) ;
  • PERS0N_REVERSE[1] "CREATIVE”;
  • PERSON REVERSE [2] "EDITORIAL”;
  • PERSON REVERSE [3] "TECH” ;
  • buttons new Array ( "btnLANDING” , “btnRESET”, “btnSAVE”, “btnAPPLY”, “btnDONE”, “btnREJECT” , “btnAPPROVE” , “btnQUIT”);
  • buttonsTop new Array (193 + IsHeight, ' 219 + IsHeight,
  • buttonsTop new Array (193 + IsHeight, 219 + IsHeight, 243 + IsHeight, 268 + IsHeight, 302 + IsHeight, 336 + IsHeight) ;
  • buttonsTop new Array(193 + IsHeight, 219 + IsHeight, 243 + IsHeight, 268 + IsHeight, 293 + IsHeight, 318 + IsHeight)
  • var person new Array ( ) ;
  • EDITORIA [2] 362 + IsHeight; toolbarHeight.
  • TECH [4] 362 + IsHeight toolbarHeight.
  • TECH [5] 362 + IsHeight toolbarHeight.
  • TECH [6] 362 + IsHeight toolbarHeight .
  • CREATIVE new Array (); toolbarHeight.
  • CREATIVE [2] 362 + IsHeight,- toolbarHeight.
  • CREATIVE [3] 362 + IsHeight; toolbarHeight.
  • CREATIVE [4] 362 + IsHeight; toolbarHeight.
  • CREATIVE [5] 362 + IsHeight; toolbarHeight.
  • CREATIVE [6] 362 + IsHeight;
  • style.posTop buttonsTo [i] ; document . all [ person [ PERSON_REVERSE [qs . Flaco] ] [i] ].
  • style .visibility "visible";
  • buttons Functions belonging to events for buttons, this functions are assigned to onmouseover, onmouseout, onclick for each button in window.
  • bButtons (variable) defined inside tblnit().
  • buttonsUp buttons Up
  • tbShowPanel objecto. id
  • inserta el codigo fuente del flash correspondiente al shoshkele y lo reproduce . adem-s, inserta tambiEn el codigo fuente correspondiente a los layers para arrastrar, mostrar bordes, o resize.
  • var shTop parselnt (pos . sh_all_anim_shoshkelizer. top)
  • var shLeft parselnt (pos . sh_all_anim_shoshkelizer. left)
  • var shLeft parselnt (pos . sh_all_anim_shoshkelizer. left)
  • CODEBASE http: //download.macromedia . com/pub/Shockwave/cabs/flash/swflash
  • var str laBarraHTML + maskFlagLayerHTML + shAllAnim bordersHTML + shAllAnimHTML;
  • esta funcion recibe el tag y las propiedades de un objecto.
  • ⁇ var cant PVFORM. theHiddenObj . length
  • unaOpcion document .createElement ( "OPTION” )
  • unaOpcion.value listalndex; unaOpcion.
  • text tmpNewOptionText; PVFORM. theHiddenObj .options .add (unaOpcion) ;
  • parentShMove (parent .document .all . sh_all_anim_shoshkelizer, pos.sh all anim shoshkelizer .left, pos.sh all anim shoshkelizer . top) ; ⁇ ⁇ " parentShMove (parent . document .all . sh_all_anim_borders, pos.sh_all_anim_shoshkelizer.left, pos . sh_all_anim_shoshkelizer. top) ; parentShMove (parent .document .all . laBarra, pos . drag . left , pos . drag . top) ,-
  • Es llamado por db_traffic .asp (sendData (1) ) desde dentro del iframe.
  • tml_if theCode; openlnlframe ( " form. html” ) ;
  • tmpTop returnlnputVal ( "dockTop”)
  • tmpLeft returnlnputVal ( "dockLeft” )
  • tmpLeft returnlnputVal ( "dockLeft” )
  • devuelve el string correspondiente a las propiedades del objecto solicitado. este puede estar anclado, ocultado, o ambos .
  • esta funcion siaffir es Hamada intern though por returnDockHiddingObj ectProperties () ;
  • PVFORM. dockTop.value (top - objectTop) ;
  • ⁇ var index getlndexTagCollection (obj .tagName, obj. index, obj.propl, obj.prop2);
  • ⁇ var obj ectFound parent .document . all . tags (obj .tagName) .ite (index) ;
  • var index formGetlndexTagCollection (obj .tagName, obj. index, obj. name, obj. type)
  • ⁇ var index getlndexTagCollection (obj .tagName, obj. index, obj.propl, obj.prop2);
  • ⁇ var index getIndexTagCollectionA(obj .text) ;

Abstract

Untrained persons (users), with little or no technical experience, are able to position and size a representation of an advertisement (ad) superposed on a representation of a background web page by simply dragging the representation of the ad. In the process, parameters are generated that result in executable code that will position and size the actual advertisement when served to a web client viewing the background page. A user connects with a layout application server through his browser and receives an HTML page containing a representation of the advertisement superposed a representation of the background page, as well as executable code, which results in the addition of a special control toolbar and menu system to the user's page. As the user manipulates the ad using the toolbar and menu system, his actions are recorder as a string of parameters, which later used to generate executable code to control the actual ad.

Description

METHOD FOR LAYING OUT MULTIMEDIA ADVERTISEMENTS
Field of The Invention
The present invention relates generally to a method for laying out online advertisements over content. It allows for the graphical layout of ads over specific web pages or templates, eliminating guesswork and simplifying previews.
The invention is a solution to the problem of arranging dynamic ads over dynamic pages.
Background of The Invention
Just as computer networks have gained widespread use in business, the Internet (one example of a computer network) has gained widespread use in virtually every aspect of our lives. The Internet includes servers (computers), which offer electrical communication to client computers (operated by users) and to other servers. The computers involved may range from mainframes to cellular telephones, and they may operate over any conceivable communication medium.
Most users connect to the Internet (or "surf the net") through a personal computer running an operating system with a graphic user interface (GUI), such as one of the Windows® operating systems. Also, most users communicate over the Internet using a program called a "browser" running on their computers, the two most popular ones being Internet Explorer and Netscape, although many other browsers are in common use. The browser receives files in a format known as HTML, which is a mark-up language that permits multimedia to be embedded within formatted and stylized text, and it displays "pages", which may play sound and exhibit graphics and video. Narious programming languages, such as JavaScript, are also available which permit executable code to be embedded in an HTML file and to run, performing useful tasks when a browser presents the file to the user's computer. To support the many services that are offered via the Internet, most Internet sites rely on advertisements (ads). This has triggered the equivalent of an arms race for the most effective form of online advertisement, resulting in a variety of formats and technologies being developed by various companies. Some of the most successful of these share the feature that the ad is served on its own layer that can be controlled separately from the content. Examples of these are the floating ads sold by United Nirtualities of New York, New York under the mark SHOSHKELE.
These ads, as well as many others, interact visually with the background content, even though they are served independently ofthe content. Also, many ad formats and technologies are not of standard shape and size, which results in the need to overlay and preview each unit on several templates or pages in order to insure the intended user experience. The process of setting up these ads can be very tedious, time consuming and uneconomical to scale: running a single ad on multiple sites can entail the customization of the unit for each site or even for every page where it will play.
In order to simplify and streamline this process, the present invention permits untrained persons with little or no technical experience, while operating a special purpose, layout computer program, to overlay the ad on the background page(s), by simply dragging the ad into position. Preferably, this computer program is accessed in the form of executable code on a web page. This is a much simpler procedure than the old way, which entailed understanding display coordinates and a non-intuitive trial-and-error process of testing the ad and modifying coordinates, until the desired result was achieved.
Understanding this, it becomes clear that it would be useful and desirable to enable users to set up ads in a WYSIWYG ("what you see is what you get") manner, so that they can actually see the ad interacting with the background page. For illustrative purposes, SHOSHKELE floating ads will be described, although it will be appreciated that the invention can be used for many other technologies, formats and platforms.
The presently preferred embodiment of the invention, included for illustration purposes only, functions as described immediately below.
A user connects with a layout application server through his browser and receives an HTML page containing content and executable code. In the received HTML Page, the user selects the HTML page or template (or any other multimedia content) over which the ad is to be previewed and laid out, as well as the ad itself. A copy of the selected HTML page, and the ad are then loaded onto the layout application server, and through a proxy server, the host page (content) is modified to show the ad overlying the selected HTML page and by inserting executable code, which will result in the addition of a control toolbar and menu system. The control toolbar is inserted on the page by way of an IFRAME, and the ad itself through an OBJECT. The user is then presented with the modified HTML page, which includes the content, the ad overlying it, and a toolbar for controlling various features and parameters. Each element —content, toolbar and ad- is placed in an independent layer within the same web page display. It should be noted that the toolbar is placed in an IFRAME so that it can float above all other elements and be accessible at all times. It should also be noted that prior to the present invention, overlaying
"layer ads" (as well as many other types of ads) required working in separate windows: first selecting features and modifying parameters, and later previewing the results in another window. The code inserted by the proxy server application into the host or content page allows for the control of the ad and its interaction within the page.
The user can graphically and intuitively control several parameters including (but not limited to) ad size, location, positioning method, length, and even the order ofthe HTML layers. After the user has completed laying out and setting up the ad, the parameters are saved in a database and are used to generate JavaScript code that will control the ad when served to the end user. The saved parameters could include: position and positioning method, size and length of, objects on the page. These are relevant and affect features -like drop down menus that may need to be hidden or flash objects that must be prioritized in the z (layer) coordinate. Brief Description Of The Drawings
The foregoing description, as well as further objects, features, and advantages of the present invention will be understood more completely from the following detailed description of a presently. preferred embodiment, with reference being had to the accompanying drawings, in which:
Fig. 1 is a flow chart illustrating an embodiment of a process for laying out an ad on a web page;
Fig. 2 illustrates the data flow among the various parties involved in the process; and Fig. 3 is a screen shot showing the process in use.
Detailed Description Of The Preferred Embodiment
Figure 1 is flowchart illustrating the method ofthe invention.
Logic flow begins at block 100, and at block 110, the user selects the page or template over which the ad will be laid out. At block 120 the ad itself is selected. Then, at block 130, the proxy server downloads the selected HTML code representing the page on which the ad is to appear, and at block 140 executable code is inserted onto the page. A documented listing of this executable code is provided in Appendix A. At block 150 the modified HTML is displayed on the user's computer, now including the selected ad and the toolbars and palettes in its window over the page that contains the ad.
Figure 3 is a screen shot showing the display on the user's computer, including the representation of the page to receive the ad 300, with the ad 310 superposed over it, and the toolbar 320 and the menu 320' on the top layer. In this case the ad is a character resembling a soccer player, the portions of the ad window outside the player, so that the player alone will appear on the page. The framing rectangle ofthe ad represents the area occupied by entire ad being transparent
As is typical, the toolbar exhibits a number of icons, any of which may be activated by clicking a mouse or other pointing device on them. The menu includes a number of similar control elements, three of which have been represented by the characters a, b, and c, which may be clicked upon to achieve certain actions on the display. For example, clicking on element a brings up a sub-menu of menu 320' that permits the user to hide an object or portion ofthe content page 300, clicking on element b brings up a sub-menu that permits the user to position the ad 310, and clicking on element c brings up a submenu that permits the user to size the ad 320. In Fig. 3, the element c has been clicked previously, and the submenu for resizing is being displayed. Resizing is achieved by clicking on and dragging the rectangular strip 330 at the bottom ofthe ad. The ad may be positioned in the positioning menu in a similar fashion.
At block 160 the user lays out the ad using the toolbar by dragging the ad into position by its handle (the bar across the bottom of the window). After the user is finished laying out the ad, in block 170, the resulting parameters, which have been stored, are used to generate JavaScript code that, when executed, will position and control the ad on the actual page, as defined by the user. Those skilled in the art will appreciate that the code may be generated at the user's computer and uploaded to the application server, or the parameters may be uploaded to the server and the code generated there. The process ends at block 180.
The resulting code can be distributed in a number of ways. Figure 2 depicts the signal or data flow between the following:
End user, E;
Web browser, W, - used by End User; Web server, S, — communicates with web browser; Application Server, A, - hosts proprietary ad layout application; • Database server, D, - parameters and code;
File server, F, - holds media files; and Third party content server, C, - a publisher or content provider.
Initially, the user inputs the URL ofthe background page into his web browser and selects an ad to overlay on it (data flow 1). Data flow 2 indicates the data entered by the user being sent to the web server via his browser. The data entered by the user is then sent to the application server by the web server (data flow 3). Data flow 4 indicates the application server requesting the chosen background page (HTML document) from the content server. Then, the content server delivers the background page to the application server (data flow 5).
Next, the application server requests the ad from the Database D and the File server F (data flow 6), and the database and file server deliver the ad to the application server (data flow 7). After the application server inserts the executable code that displays the selected ad and the toolbar onto the saved HTML, the new web page is sent to the web server (data flow 8), which sends the modified code to the web browser, for display.
After that, the User sets up the ad and enters all parameters; the resulting data is sent to the web server (data flow 10) then on to the application server (data flow 11).
In the preferred embodiment, the application server generates Javascript code to control and position thread according to the parameters, which code is sent to the database (data flow 12). From there, it can be served in a number of standard ways. Commented code for the preferred embodiment is presented in
Appendix A. This code is organized as three modules.
Module 1 creates the interface and features as seen in Figure 3. It is responsible for displaying and operating the ad, the background page and the toolbar during the lay out process. The operation and use of this module results in the generation of a string of characters such as the following:
?params1 =shLocation%3Dhttp%3A//shoshkelizerdev.unitedsitθs.com .ar/upload/files/00000291/naka.swf%26shWidth%3D550%26shHeight %3D400&params2=posType%3Dfixed%26top%3D9%26left%3D128 %26dockHidding%3Dimg%211 %21158%2178%211 %211 %26iniLs%
3D0%26eas%3D0%26finLs%3D0%26finish%3D0%26posx%3D0%2 6posy%3D0%26Scroll%3D1 %26removeAds%3D1 &ldMediaDet=301 97&ldCreative=333&ldCreativeProps=30135&ldAnimationFile=1721 & ldBannerFile=0&ventana=0&Flaco=3&LS=1
This string represents the parameters generated as the user manipulates the ad.
Module 2 is a Code Generator. Using the data contained in the above string, this module assembles a Timeline code, which represents the time sequence of the operation ofthe ad as created by the user. The information contained in the suing mentioned above is codified using a JavaScript function named escape (). Once decoded, the following values are extracted and used by the code generating module as parameters for the timeline.
Description {VARIABLE_NAME}: value
Flash file
Name {FLASH_FlLE}: naka.swf Width {FLASH_WIDTH}: 550 Height {FLASH_HEIGHT}: 400 Ad positioning
Type {POS_TYPE}: fixed (values can be: centered, anchor) Top {POS_TOP}: -9 Left {POSJ.EFT}: 128
Objects on the page that will be hidden during adplay.
Objeto 1
Tag {HIDE_1_TAG}: IMG (IMG/IFRAME/OBJECT/A/SELECT/INPUT) Index {HIDE JNDEX}: 1
Width {HIDE_1_WIDTH}: 158
Height {HIDE_1_HEIGHT}: 78
Action {HIDE_1_ACTION}: hidden (centered, anchor)
Show again after playback {HIDE_1_SHOW_AT_THE_END}: Yes (Yes/No)
Landing Spot iniLs {LSJN1}: 0 eas {LS_EAS}: 0 finLs {LS_F1N}: 0 finish {LS_FINISH}: 0 posx {LS_X}: 0 posy {LS_Y}: 0
LS {LS_FLAG}: 1 Module 3 is a typical Timeline code to control the operation ofthe ad.
Those skilled in the art will appreciate that servers F, A, D and, although shown separate, need not run on separate computers. That is, two or more ofthe servers may reside on the same computer.
Although a preferred embodiment of the invention has been disclosed for illustrative purposes, those skilled in the art will appreciate that many addition, modifications and substitutions are possible without departing from the scope and spirit ofthe invention.
Appendix A
Code Section
Module 1 : Interface And Features Code Conventions:
Comments are included throughout the code xn the following maner:
comment html
//--> /* javascript comment
*/ ***
The application proxy retrieves the HTML code from the selected background page and adds 3 tags . 1 toolbar. asp
<IPRA E ιd="control" style="position. absolute; visibilitychidden; top.lOpx; left lOpx, wιdth:46px, height .345px; z-mdex: 100" NAME="theToolBar"
FRAMEBORDER="NO" SRC="http : //www. shoshkelizer com/trafflc/toolba .asp">
</IFRAME> 1.1: code_gen.asp
1.2: form.html
2- control. asp
<SCRIPT SRC="http://www.shoshkelizer.com/traffic/control asp" ></SCRIPT> 2.1. files used in Frame simulation tb_azul .html tb_mysrc .html b_ro o html tb verde.html
3 base href
<BASE HREF="http : //www . siteaddress . com/dir/ " :
****************************************************************************
*** l*****J- **-"'**
J ** 1. toolbar. asp
Initiate toolbar. asp //--:
<D0CTYPE HTML PUBLIC "-// 3C//DTD HTML 4.0 Transitional//EN">
<html>
<headxtitle>Toolbar</titleχ/head> <script>
variable containing location of module files
*/
var theSRC = "<%=ShoshPath%>/traf ic/" , </script>
< ! 1 _-
Definition of styles ======================
//-->
<style type="text/css">
.buttonUp {background-Color :#E77D5A;border: outset 1;} .buttonOver {background-Color :#E77D5A;border : outset 2;}
.buttonDown {background-Colo : #E77D5A;border: inset 1; } . buttonSelected
{ background-Color:#EEEEEE; border: inset 1; width:24px; height :20px;
} A: link { color: #cccccc; text-decoration: none } A:visited { color: #cccccc; text-decoration: none }
A:hover { color: #cccccc; text-decoration: none; font: bold;}
.textbox { font: verdana ; font-size: 75%; height: 18px; width: ;}
.Select
{ font : verdana ; font-size: 75%; height : 18px; width: 68;
}
.SellectTag
{ font: 'verdana ; font-size: 75%; height : 18px; width: 60; }
.Select2 { font: verdana ; font-size: 75%; height: 18px,- width: ; height: 20;} .Select3
{ font: verdana; font-size: 75%; width: 140; background: #EF9673; border: Opx;
.botones { font: verdana ; font-size: 75%; } .botonMarron { background : #C65942;
Cθlor:#000000; font:bold lOpx Verdana, Arial, sans-serif; border-bottom-width : thin; border : thin solid; border-bottom-style : solid; border-color : #CE7163 Black Black #CE7163;
</style>
HTML body start
//--> <body bgcolor="#E77D5A" topmargin="0" leftmargin="0" scroll="NO">
This iframe will be used later to assemble the code generating sub-module
II-
<iframe name="thelframe" style="visibility :hidden; " ></iframe>
Toolbar buttons start
//-
<div ιd="DragBar" ondblclick="tbMinMax() " style="position:absolute; top:0px; left:0px; width:46px; height : 13px; " align="left"χimg id="imgDragBar" src="img/drag_bar .gif " width="46" height="13" border=0x/div>
<div id="TitleBar" style="position:absolute; top:0px; left:46px; width:243px; height :21px; "ximg src="img/title_bar .gif " width="243" height="21" border="0"x/div> <div id="theTitle" style="position:absolute; top:2px; left:70px; width: 170px; height :21px"xfont face= "Verdana" size= "2 " > ! </f ontx/div>
<div id="botonera" class="buttonUp" style="position:absolute; top:13px; left:0px; width:46px; height : 385px" x/div>
<div id="ocultar" onclick="tbButtonPress (document. all [TBBUTTONDO N] ) ;" onmouseover= " this . style. cursor = 'hand'" style="position:absolute; top:0px; left:267; width:22px; height : 21px" ximg src="img/invisible .gif " width="22" height= " 21 " χ/div>
<!-- begin botones //--> <div id="btnhidding" class="buttonUp" style="position:absolute; cursor :hand; top:24px; left:7px; width:32px; height:28px" align="center"χimg id="imghidding" src="img/_hide.gif " alt="Object hidding"x/div> <div id="btnpos" class="buttonUp" style="position: absolute; curso :hand; top:63px; left:7px; width: 32px; height :28px" align="center"ximg id="imgpos" src="img/_move .gif " alt="Positioning" ></div>
<div id="btnresize" class="buttonUp" style="position:absolute ; cursor:hand; top:102px; left:7px; width:32px; height:17px" align="center"ximg id="imgresize" src="img/scale.gif " alt="Resize"χ/div>
<div id="btnPLAY" class="buttonUp" style= "position: absolute; cursor:hand; top:140px; left:7px; width:32px; height:17px" align= "center" ximg id="imgplay" src="img/_play .gif " alt="Play swf" onclick="changeFlash( ) "></div>
<div id="btnSEPl" style="position:absolute; cursor:hand; top:179px; left:5px; width:32px; height : 17px" align="center"ximg id="imgsepl" src="img/sepl .gif "></div>
<div id="btnLANDING" class="buttonUp" style="position:absolute; cursor:hand; top:193px; left:7px; width:32px; height:17px" align="center" ximg id="img landing" src="img/_ls .gif " alt="Edit landing spot" onclick= "paren . render () "χ/div>
<div id="btnRESET" class="buttonUp" style="position:absolute; cursor: hand; top:219px; left:7px; width: 32px; height :17px" align="center"ximg id="imgreset" src="img/_reset .gif " alt="Reset" onclick="resetPage () "x/div>
<div id="btnSAVE" class -"buttonUp" style="position:absolute; cursor:hand; top:243px; left:7px; width:32px; height : 17px" align=" center" ximg id="imgsave" src="img/_save .gif " alt="Save" onclick="sendData (0) "χ/div>
<div id="btnAPPLY" class= "buttonUp" style= "position: bsolute; cursor and; top:268px; left:7px; width:32px; height:17px" align= "center" ximg id="imgapply" src="img/_apply .gif " alt="Apply" onclick="sendData (1) "x/div>
<div id="btnDONE" class= "buttonUp" style= "position: absolute; cursor: hand; top:268px; left:7px; width:32px; height : 17px" align="center"ximg id="imgdone" src="img/done .gif " alt="DONE" onclick="doneButton() "x/div>
<div id="btnQUIT" class="buttonUp" style="position: absolute; cursor:hand; top:293ρx; left:7px; width:32px; height:17px" align="center"ximg id="imgquit" src="img/_quit .gif " alt="Quit" onclick="pvQuit () " x/div> <div id="btnREJECT" class= "buttonUp" style= "position: bsolute ; cursor:hand; top:318px; left:7px; width:32px; height:17px" align="center"ximg id="imgreject" src="img/down3.gif " alt="Reject" onclick="pvReject () "x/div> <div id="btnAPPROVE" class= "buttonUp" style= "position: absolute; cursor:hand; top:343px; left:7px; width:32px; height : 17px" align=" center "ximg id="imgapprove" src="img/up3.gif " alt="Approve" onclick="pvApprove () "x/div> <!--
Begining of definition of panels to be shown on pressing the above buttons
//--> <form method="GET" target="_top">
<!-- begin Obj hiding //-->
<div id="Divhidding" style="position:absolute; top:25px; left:55px; width :225px; visibility: hidden; background-color : #E77D5A; ">
<table border="0" cellpadding=" 0 " cellspacing="0" align="center" width="225"> <tr>
<td align=" center "ximg src=" img/click_an_obj ect_or_enter_data_manually_hiddin .gif " x/td> </tr>
</table>
<table border=" 0" cellPadding=0 cellSpacing=0 align="center" width="225" bgcolor="#EF9673 ">
<trxtd colspan="4"χimg src="img/ invisible.gif" height="5"x/tdχ/tr> <tr>
<td align=" left "ximg src="img/ tag_hidding.gif" x/td> <td align="lef f'xselect name="tagHide" style= " font : normal lOpx Tahoma,-" onchange="changeHideTable ( ) " class=" Select "xopt ion value="FORM">Form Element </optionxopt ion value="IMG">IMG</optionxoption value= " IFRAME " >IFRAME< /op ionxop ion value=" OBJECT ">FLASH</ opt ionx/ select x/td>
<td align="lef t" ximg src="img/index_hidding . gif "χ/td>
<td align="lef fxinput tyρe="text" name="hidelndex" class=" textbox" x/td>
</tr>
<tr id="tabHidImg" style="display:none ; "> <td align=" left "ximg src= " img/width_hidding . gif " x/td>
<td align=" lef f xinput type= " text " name="widthHide" class="textbox" x/td>
<td align=" left " ximg src= " img/height_hidding .gif " ></ td>
<td align= "lef f xinput type= "text " name="heightHide" class= " textbox" χ/td>
</tr> <tr> </tr> <tr id="tabHidForm">
<td align= "lef t " ximg src="img/type_hidding .gif "></td>
<td align="left">
<select name="formElementTag" class="Select">
<option value="SELEC - ONE">select</option>
<option value="TEXT">input text</option>
<option value= "RADIO">input radio</option>
<option value= "CHECKBOX" >input checkbox-;/option>
<option value=" IMAGE" >input image</option>
<option value= "BUTTON" >input button</option>
<option value="SUBMIT">input submit</option>
<option value=" PASSWORD" >input password</option>
</select> </td> <td align=" left "ximg src="img/name_hidding .gif" χ/td>
<td align="left"xinput type="text" name= "tagNameElemForm" class= "textbox" x/td>
</tr>
<trxtd colspan="4 " ximg src= " img/ invisible .gif " height="5 " x/tdx/tr> <trxtd align=" right" colspan="4"xinput type="button" value=" Add " onclick="pvForm_HideAdd( ) " class="botonMarron">&nbsp;&nbsp;</tdχ/tr>
<trxtd colspan="4"ximg src=" img/ invisible.gif" height="5"x/tdx/tr>
</table>
<table>
<trxtdximg src=" img/ separadorh.gif" height= " " width= " 217 " ></ tdx/tr>
<trxtdximg src="img/list_of_selected_objects .gif " /tdx/tr>
</table>
<table border="0" cellPadding=2 cellSpacing=2 align="center" width="225" bgcolor="#EF9673">
<tr>
<td rowspan="2">
<table bgcolor="#E77D5A"> <tr> <td>
<select name="theHiddenObj " class="Select3" size="3">
<option value="0">None selected</option>
</select> </td>
</tr> </table>
</td>
<td>--nbsp;</td> </tr>
<tr>
<tdxinput typβ="button" value= "Remove" onclick="parent .deleteHide (); " class="botonMarron"x/td>
</tr>
</table>
</div>
<!-- End Obj hiding //--> <!-- begin positioning //--> <div id="Divpos" style= "position: absolute ; to : 30 ; left : 60 ;visibility: hidden; " >
<!-- apply button //--> <input id="anchor_apply_button" type="button" value= "Apply" onclick="moveShoshToTheFixPos ( ) " style="position:absolute; visibility: hidden; top:175px; left:45px" class="botonMarron" >
<!-- /apply button //-->
<!-- vertical line //-->
<img src="img/separadorv.gif" width="2" height="195" style= "position: absolute; left:105px; top:5px,-">
<!-- /vertical line //-->
<!-- horizontal line //--> <img src="img/separadorh.gif " height="2" width="95" style= "position: absolute; top:80px; left:5px;">
<!-- /horizontal line //--> <table border=0 cellPadding=0 cellSpacing=0>
<trxtdxinput type="radio" name="typeOfPos" value="f ixed" onclick="changeTypeOf os (' fixed' ) " checkedx/tdxtdximg src="img/f ixed.gif "χ/tdx/tr>
<trxtdxinput type="radio" name="typeOf Pos" value= "center" onclick="changeTypeOf Pos ( ' center' ) "x/tdxtdximg src="img/centered.gif "x/tdx/tr>
<trxtdχinput tyρe="radio" name= " typeOf Pos " value= " docked" onclick="changeTypeOf Pos ( 'docked' ) "x/tdxtdximg src="img/anchored.gif " x/tdx/tr>
</table>
<!-- absolute --> <div id="typeOfPosFix" style= "position: absolute; top:90px; left:0px; visibility : inherit ;" >
<input id="fixed_apply_button" type="button" value="Apply" onclick="moveShoshToTheFixPos ( ) " style= "position: absolute; visibility: inherit ; top:60px; left:40px" class="botonMarron" >
<table border=0 cellPadding=0 cellSpacing= 0>
<trxtdxfont
Figure imgf000018_0001
<trχtdximg src="img/top.gif " width="30" height="12"x/tdxtdxinput type="text" name="f ixtop" class=" textbox" value="0" style="width:40px" onkeyup=" parent .removeMinus (this) ">&nbsp; &nbsp; </tdx/tr>
<trxtdximg src="img/lef t .gif" width="30" height="12"x/tdx/tdχtdxinput type="text" name="f ixlef t" class="textbox" value="0" style="width: 40px" onkeyup="parent .removeMinus (this) ">--nbsp;--nbsp;</tdx/tr>
<trxtdxf ont size="l">--nbsp;</fontx/tdx/tr>
</table>
</div> <div id="typeOf osCen" style= "position: absolute; top:90px; left:0px; visibility :hidden; " >
< input id="centered_apply__button" type="button" value="Apply" onclick="moveShoshToTheFixPos ( ) " style= "position: absolute; visibility: inherit ; top:60px; left:40px" class= "botonMarron" >
<table border=0 cellPadding=0 cellSpacing=0>
<trxtdxf ont size="l">&nbsp;</fon x/tdx/tr>
<trxtdximg src="img/top.gif "x/tdχtdxinput type="text" name="topCenter" class=" textbox" value="0" style="width: 40px" onkeyup= "parent .removeMinus (this) ">&nbsp;--nbsp;</tdx/tr>
<trxtdximg src="img/off set .gif "x/tdx/tdxtdxinput type="text" name="lef tCenter" class=" textbox" value="0" style="width:40px" onkeyup= "parent .removeMinus (this) ">&nbsp; &nbsp; </tdx/tr>
<trxtdxfont size="l">&nbsp;</fontx/tdx/tr>
</table>
</div>
<div id="f ixed_inf o" style= "position: absolute ; top:0px; left:112px; width:110px; visibility : hidden; " >
<table border="0">
< ! -xtrxtdxfont face="Verdana" size="2">A null offset value ("0") positions the Shoshkele on the center of page. Positive offset values position the Shoshkele? to the right of the center of the page. Negative offset values position the Shoshkele? to the left of the center of the page . </fontx/tdx/tr>//-->
<trxtdximg src="img/center_info.gif" width="105" height="230" ></tdx/tr> </table>
</div>
<!-- anclado //-->
<div id="typeθfPosAnchTopAndLeft" style="position: absolute; top:90px; left:0px; visibility:hidden; ">
<table border=0 cellPadding=0 cellSpacing=o> <trxtd colspan="2"ximg src= " img/relative_ osition_to_anchor . gif " ></ tdx/ tr>
<trχtd colspan="2"xf ont size="l">--nbsp;</fon x/tdχ/tr>
<trχtdχimg src="img/top. gif "x/tdxtdxinput type="text" name="dockTop" class="textbox" value="0" onkeyup= "parent .removeMinus (this) ">&nbsp; δ-nbsp;</tdχ/tr> <trxtdximg src="img/left .gif "x/tdxtdxinput type="text" name="dockLef t" class=" textbox" value="0" onkeyup=" parent .removeMinus (this) ">&nbsp; S-nbsp; </tdx/tr> <trxtd colspan="2"xf ont size="l">--nbsp;</fon x/tdx/tr>
</table> </div>
<div id="typeOfPosAnch" style="position:absolute; top:0px; left:10px; visibility :hidden; background-color : #C6715A; " > <!-- anchor button //-->
< input name="agregaanclado" value=" Anchor" class="botonMarron" type="button" onclick="dockAddManual ( ) " style="position:absolute; top:110px; lef t : 152px; ">
<!-- /anchor button //-->
<table border="0" cellpadding="0" cellspacing=" 0" style= "position: absolute; top:2px; lef t : 105px; ">
<trxtd colspan="2"ximg src=" img/ select_object_or_enter_data_manually.gif "x/tdx/tr>
<trxtd colspan="2"ximg src="img/invisible .gif " height="6"x/tdx/tr>
<tr>
<td align="lef t" ximg src="img/tag .gif "x/td>
) "
Figure imgf000020_0001
</tr> <tbody id="anchWIDTHandHEIGHT">
<trxtd align="lef t"ximg src= " img/width . gif " ></ tdx td align= "lef t " xinput type= " text " name="widthDock" size="4" class="textbox"x/tdx/tr>
<trxtd align= "le t "ximg src= " img/height . gif " ></ tdxtd align= " lef t " xinput tyρe= " text " name="heightDock" size="4" class="textbox"χ/tdχ/tr> </tbody; <!-- solo para anchors //-->
<tbody id="anchTEXTandHREF" style=" display: one "> <trxtd align="lef f'ximg src="img/text .gif "x/tdxtd align="lef fxinput type="text" name="textA" class=" textbox" ></ td /tr>
<trxtd colspan="2"ximg src="img/invisible.gif " height="12"x/tdx/tr>
</tbody>
<!-- /solo para anchors //-->
<tr id="AnchoringIndex"χtdximg src= " img/ inde .gif'x/tdxtdx input
Figure imgf000021_0001
class=" textbox" ></ tdx /tr> </table>
<table border="0" cellpadding="0" cellspacings "0" style="position:absolute; top:200px; lef t : -15px; " > <trxtd align="leff colspan="2"ximg src="img/invisible.gif " height="4" width="217" x/tdx/tr>
<trxtd align="left" colspan="2"ximg src=" img/ separadorh.gif" height="2" width="217" x/tdx/tr>
<trxtd align="left" colspan="2"ximg src=" img/ invisible .gif " height="6" width="217"x/tdχ/tr>
<trxtd align="left" colspan="2"ximg src="img/anchorto. gif "xinput type="hidden" value="" name="elancladoq"xinput type="text" value="" name="elanclado" size="12" style="font: verdana ; font-size: 75%; height: 18px;" onfocus="javascript : this .blur () ">&nbsp; <input name="borraranclado" value="Delete" class="botonMarron" type="button" onclick= "parent . filterDeleteDock (this . form. elancladoq. value) ; "></tdx/tr>
</table>
</div>
<!-- /anclado //-->
</div> <!-- end positioning //-->
< ! -- Resize //- ->
<div ID="Divresize" style="position: bsolute; top:25px; left:55px; width:225px; visibility:hidden; background-color : #E77D5A; ">
<table border="0" cellpadding="0" cellspacing="0" align= "center" width="225"> <tr>
<td align=" center "ximg src= " img/enter_or_drag . gif " ></ td> </tr> </table>
<table border="0" cellPadding=0 cellSpacing=0 align=" center" width="225" bgcolor="#EF9673"> <trxtd colspan="4"ximg src= " img/invisible . gif " height= " 5 " ></ tdx/tr>
<tr> <td align="lef fximg src= " img/width_hidding . gif " ></ td>
<td align=" lef fxinput type="text" name="resizeWidth" class=" textbox" onkeyup= "parent . resize_updateHeightFromWidth ( ) "></td>
<td align="lef fximg src="img/height_hidding.gif "x/td> <td align="lef xinput type="text" name= " resizeHeight " class= " textbox" onkeyup= "parent . resize_updateWidthFromHeight ( ) "x/td>
</tr>
<trxtd colspan="4"ximg src=" img/ invisible.gif" height="5"x/tdx/tr>
<trxtd align="right" colspan= "4 "xinput type="button" value=" Resize " onclick=" parent . resize_manualApply ( ) " class="botonMarron" >&nbsp; &nbsp; </tdχ/tr-»
<trχtd colspan="4"ximg src=" img/ invisible.gif" height="5"x/tdχ/tr>
</table>
</div> <!-- /Resize //-->
<!-- shoshkele data //-->
<div ID="Divdata" style="position: absolute; top:280px; left:55px; width:225px; visibility.visible; background- color : #E77D5A; ">
<table border="0" cellpadding="0" cellspacing="0" align="center" width="225"> <tr>
<td align="lef t" ximg src= " img/ shoshkele_data . gif " ></ td> </tr>
</table>
<table border="0" cellPadding=0 cellSpacing=0 align=" center", width="225" bgcolor="#EF9673">
<trxtd colspan="4"ximg src=" img/ invisible.gif" height="5"x/tdx/tr> <tr> <td align="lef fximg src= " img/width_hidding . gif " ></ td>
<td align="lef fxinput type="text" name="swf Width" class=" textbox" style="width:40px" readonlyx/td>
<td align= "lef fximg src= " img/height_hidding . gif " ></ td>
<td align=" left "xinput type="texf name="swf Height" class="textbox" style="width: 40px" readonlyx/td>
</tr> <tr>
<td align="leff ximg src="img/filesize . gif "x/td;
<td align="left" colspan="3 "xinput type="text" name="swfSize" class="textbox" style="width: 40px" readonlyχ/td>
</tr>
<trxtd colspan="4"ximg src="img/ invisible.gif" height="5"x/tdx/tr>
</table>
</div>
<div id="vidrio" style= "position: absolute; visibility:hidden; background- Color : #000000; top:13px; left:0px; width:46px; height : 385px"x/div> <!-- /shoshkele data //-->
</f orm>
Scripting start
//--,
<script language="JavaScript ">
function uvAlert(txt)
{ alert (txt) ;
} /* direcciϋn del ASP target */ var newLocation = theSRC + 'default .asp' ; var RO O = "FF1410"; var DOCKED = "docked"; var FIXED = "fixed"; var CENTERED = "center";
var HIDE = 1; var DOCK = 2; var BOTH = 3 ;
var ACTIONS = new Array ( ) ; ACTIONS [1] = "hide";
ACTIONS [2] = "dock"; ACTIONS [3] = "both";
7*
initial function
*/ window. onload = function ()
/* ====================== after completely reading control. asp main funtion starts.
*/
if (parent .document . readyState == "complete" --& parent . CONTROLJύOADED)
{
document .all .vidrio. style . filter="alpha (opacity=50, enabled=l) " ; /'
scroll variable start
X
parent .window. chescrollHeight = parent .document .body. scrollHeight ; parent .window. theScrollWidth parent .document .body. scrollWidth;
Querystring use explanation: window. qs is the variable containing info on the Shoshkele configuration. This info is sent from the previous module through the querystring (The querystring is behind the ? character in an URL)
When a Shoshkele is edited from scratch, the querystring includes only internal campaign info is sent to be saved again after editing.
After editing and saving or applying changes, all config data is sent back to the server.
When the Shoshkele is edited thereafter, the previous module sends all Shoshkele info as part of the querystring
/* /*
Save current config in a variable
*/ window. qs = queryString_returnParams ( }
I *
Features specific to each user are shown, allowing for different users to access different features. buttonsPos ( ) ;
show toolbar
parent .documen .all .control . style.visibility = "visible";
Initialize variable indicating whether Shoshkele content must be shown while dragging .
window.SHOW CONTENT ON DRAG FLASH = true;
Initialization of variables and events needed for toolbar functionality.
tblnit O
Write variable on control.asp indicating whether the toolbar is loaded.
parent . indow.TOOLBARLOADED = true; Initialization of shared variables on control. asp
parent .window. PVFORM = window. PVFORM = document . forms [0] ,- parent . indow. SELECTFOR = " " ; parent .window.manualObjectsAdd = false;
if (qs)
Initialization of variables used to resize swf file
*/ window. shWidth = parent .ORIGINAL_WIDTH = PVFORM. resizeWidth. alue = parselnt (qs . shWidth) ; window. shHeight = parent .ORIGINAL_HEIGHT = PVFORM. resizeHeight .value = parselnt (qs . shHeight) window. shLocation = (qs . shLocation. substring (0, 2) == "..")? ("http://" + parent . location. host + qs . shLocation. substring (2 , qs . shLocation. length) ) : qs . shLocation;
Initialization of variables used to edit swf file
qs. iniLs = (qs. iniLs)? parselnt (qs . iniLs) : 0; qs.eas = (qs.eas)? parselnt (qs . eas) qs.finLs = (qs.finLs)? parselnt (qs.finLs) : 0; qs. finish = (qs. finish)? parselnt (qs . finish) : 0; qs.posx = (qs.posx)? parselnt (qs.posx) : 0 ; qs.posy = (qs.posy) parselnt (qs .posy) : 0;
changeFlash ( ) ;
window.pvForm_posType = FIXED;
/*
restoration of previously hidden and anchored objects.
if (qs .dockHidding)
{ parseDockHiddingQS (qs . dockHidding)
}
initialize the variable containing the default positioning method.
*/ window.pvForm_posType = (qs.posType != "undefined" || ! qs .posType) ? qs.posType : FIXED;
reinstate the position and positioning method. */ if (qs.top &-- qs.left && qs.posType)
{ qs.top = parselnt (qs .top) ; qs.left = parselnt (qs.left) ;
if (qs.posType == DOCKED)
restoreDockedO ;
} else
{ restorePositionO ;
}
}
PVFORM. swfWidth.value = qs. shWidth; PVFORM. swfHeight .value = qs. shHeight;
PVFORM. swfSize.value = parselnt (parselnt (qs.fSize) / 1024); if ( PVFORM. swfSize.value == 0) PVFORM. swfSize. alue = 1;
PVFORM. swfSize.value += " kb" ;
window. lastPosType = false;
/*
True is the changes were saved. False if not.
*/ window. saveFlag = false;
window. saveParams = queryString_generator ( ) ;
} else
{ window. setTimeout ( "onload () " , 100) }
} /* window. onload = function () */
/*
loads positioning values and applies them
*/ function restorePosition ()
{ if (restorePosition. arguments .length == 1)
{ qs.posType = restorePosition. arguments [0]
if (qs.posType == FIXED)
PVFORM. fixtop.value = qs.top;
PVFORM. fixleft. alue = qs.left;
moveShoshToTheFixPos ( ) ;
/*
select the correct radio ====================== */ checkRadioByValue ( "typeOfPos" , qs.posType) ;
setUpAHPosO ;
changeTypeOfPos (qs .posType) ;
} else if (qs.posType == CENTERED)
{
PVFORM. topCenter.value = qs.top; PVFORM. leftCenter.value = qs.left;
checkRadioByValue ( " ypeOfPos" , qs .posType) ;
moveShoshToTheFixPos ( ) ;
setUpAHPos O ;
changeTypeOfPos (qs .posType) ; parent .onresizeFlag = true; }
} /* function restorePosition ( ) */
/*
Function used only when editing a previously saved and anchored shoshkele
*/ function restoreDocke ( )
{ if (!window.DOCKEDOBJECT)
{ setTimeout ( "restoreDocked ( ) " , 1000)
} else
x
obtain anchor position.
var objectX = get (DOCKEDOBJECT) ; var objectY = getY (DOCKEDOBJECT) ;
calculate media file absolute position
*/ var newX = objectX + qs.left; var newY = objectY + qs.top;
assign such position
*/
PVFORM. fixleft. alue = newX; PVFORM. fixtop.value = newY;
moveShoshToTheFixPos ( ) ;
select corresponding radio button */
CheckRadioByValue ( "typeOfPos" , qs .posType) ;
/*
calculate position values
setUpAHPos O ;
change positining method.
*/ changeTypeOfPos (qs.posType).
/* restoreDocked () */
read params received
function queryString__returnParams () { var toReturn = new Array () ;
var parentQS = paren . location. href ;
toReturn. IdMediaDet = queryString_readVar (parentQS , "IdMediaDet" ) toReturn. IdCreative = queryString_readVar (parentQS, "IdCreative"); toReturn. IdCreativeProps = queryString_readVar (parentQS, "IdCreativeProps") ; toReturn. IdAnimationFile = queryString_readVar (parentQS,
"IdAnimationFile") ; toReturn. IdBannerFile = queryString_readVar (parentQS, "IdBannerFile"); toReturn. Flaco = queryString_readVar (parentQS, "Flaco"); toReturn. LS = parselnt (queryString_readVar (parentQS, "LS")); toReturn. fSize = parselnt (queryString readVar (parentQS, "fSize"));
var paramsl = unescape (queryString_readVar (parentQS , "paramsl" )) ; var params2 = unescape (queryString_readVar (parentQS, "params2" ) ) ;
queryString__toArray (toReturn, paramsl) ; queryString_toArray (toReturn, ρarams2) ,-
return toReturn;
}
function queryString_readVar (url, qsVar)
{ var index = url . indexOf (qsVar + "=")
if ( index == -1 ) return false; else
{ var resto = url . substring ( index + qsVar. length + 1, url . length) ;
var nextAnd = resto. indexOf ("&" )
if (nextAnd == -1) return resto; else return resto. substring (0 , nextAnd);
} function queryString_toArray (arrToModify, qs)
' if ( qs.charAt(O) == "?" ) qs = qs . substring (1, qs. length) ;
var args = qs .split ("&") ; for (var i=0; i<args . length; i++)
if( args [i] .indexOf ("=") !=-l )
{ var tmpName = args [i] . substring (0 , args [i] . indexOf ("=")) var tmpVal = argsti] . substring (args [i] .indexOf ("=") +1, args [i] .length); arrToModify [tmpName] = tmpVal ;
} else
{ arrToModify [args [i] ] = " " ; }
}
'
/* ======================
Functions used by "done" button.
*/
function errorDoneButto ( )
alert ("Error!") ; function okDoneButton ( )
{ aler ("Done!") ;
}
function doneButtonO
{ var donelmg = new Image ( ) ; donelmg.onload = okDoneButton; donelmg .onerror = errorDoneButton; donelmg. src = "db -raffic.asp?J0B=W0RK_EDIT0RIAL 30NE--IdCreative=" + qs. IdCreative;
BUTTONS
*/
I*
Different users access different buttons ==============BS.=a==
*/ function buttonsPosO
{ var CREATIVE = 1; var EDITORIAL = 2; var TECH = 3 ;
var PERSONJREVERSE = new Array ( ) ; PERS0N_REVERSE[1] = "CREATIVE"; PERSON REVERSE [2] = "EDITORIAL"; PERSON REVERSE [3] = "TECH" ;
var IsHeight = (qs.LS)? 25 : 0 ;
var buttons = new Array ( "btnLANDING" , "btnRESET", "btnSAVE", "btnAPPLY", "btnDONE", "btnREJECT" , "btnAPPROVE" , "btnQUIT");
for (var i = 0; i < buttons .length; i++) { document .all [ buttons[i] ]. style. visibility = "hidden"; }
if( qs. Flaco == EDITORIAL || qs. Flaco == TECH)
{ if (qs. Flaco == EDITORIAL) { var buttonsTop = new Array (193 + IsHeight, ' 219 + IsHeight,
243 + IsHeight,
278 + IsHeight,
312 + IsHeight,
338 + IsHeight) ;
} else { var buttonsTop = new Array (193 + IsHeight, 219 + IsHeight, 243 + IsHeight, 268 + IsHeight, 302 + IsHeight, 336 + IsHeight) ;
else
{ var buttonsTop = new Array(193 + IsHeight, 219 + IsHeight, 243 + IsHeight, 268 + IsHeight, 293 + IsHeight, 318 + IsHeight) ,- var person = new Array ( ) ;
declaration of available buttons
*/ if (qs. IdMediaDet == 0)
{ person. CREATIVE = new Array ( "btnRESET" ,
"btnQUIT") ; person. TECH = new Array ( "btnRESET" , "btnQUIT") ; person. EDITORIAL = new Array( "btnRESET" , "btnQUIT") ;
} else
{ person. CREATIVE = new Array( "btnRESET" ,
"btnSAVE", "btnQUIT"); person.TECH = new Array ( "btnRESET" , "btnSAVE", "btnAPPLY", "btnAPPROVE" , "btnREJECT", "btnQUIT"); person. EDITORIAL = new Array( "btnRESET" , "btnSAVE", "btnAPPROVE", "btnREJECT", "btnDONE" , "btnQUIT");
/*
declaration of toolbar height according to number of buttons
*/ var toolbarHeight = new Array () ; toolbarHeight .EDITORIAL = new Array (); toolbarHeight. EDITORIA [2] = 362 + IsHeight; toolbarHeight. EDITORIAL [3] = 362 + IsHeight; toolbarHeight.EDITORIA [4] = 362 + IsHeight; toolbarHeight.EDITORIA [5] = 362 + IsHeight; toolbarHeight.EDITORIA [6] = 362 + IsHeight; toolbarHeight . TECH = new Arra (), toolbarHeight.TECH [2] = 362 + IsHeight; toolbarHeight. TECH [3] = 362 + IsHeight toolbarHeight. TECH [4] = 362 + IsHeight toolbarHeight. TECH [5] = 362 + IsHeight toolbarHeight.TECH [6] = 362 + IsHeight toolbarHeight .CREATIVE = new Array (); toolbarHeight. CREATIVE [2] = 362 + IsHeight,- toolbarHeight. CREATIVE [3] = 362 + IsHeight; toolbarHeight. CREATIVE [4] = 362 + IsHeight; toolbarHeight. CREATIVE [5] = 362 + IsHeight; toolbarHeight. CREATIVE [6] = 362 + IsHeight;
for (var i = 0 ,- i < person [ PERSON_REVERSE[qs. Flaco] ]. length; i++)
{ document .all [ person [ PERSON_REVERSE [qs . Flaco] ] [i] ]. style.posTop = buttonsTo [i] ; document . all [ person [ PERSON_REVERSE [qs . Flaco] ] [i] ]. style .visibility = "visible";
}
if (qs.LS) document .all.btnLANDING. style .visibility
"visible" ;
var tmpPersonButtons = person [PERSON_REVERSE [qs. Flaco] ] .length; var tmpPersonType = PERSON_REVERSE [ qs . Flaco ]
window. bHeight = parent . document . all . control . style .posHeight = toolbarHeight [tmpPersonType] [tmpPersonButtons] ;
} /* buttonsPosO */ /* ====================== initialize variables and assign functions to each button
*/ function tblnitO { window.TBINITFLAG = true;
/*
Variable indicating toolbar title size
window.TBSIZE = "normal";
Variable containing the string of the pressed button. False if none
window. TBBUTTONDOWN = false;
/*
List of buttons
/ window. tbButtons
Array( "btnpos" , "btnhidding" , "btnresize") ;
/* ================-.===== assign events to declared buttons.
*/ for (var i=0; i<tbButtons . length; i++) { var tmp = document .all [ tbButtons [i] ];
t p . onmouseover = tbButtonMouseOver; tm . onmouseout = tbButtonMouseOut ; tmp.onclick = tbButtonMouseClick;
}
/*
assign functions corresponding to each event so as to drag iframe from top bar.
*/
document .onmousedown = mouseDown; document .onmousemove = mouseMove; document .onmouseup = mouseUp; document .onselectstart = selectStart;
} /* fin de tblnitO */
EVENTS
*/
X == Functions belonging to events for buttons, this functions are assigned to onmouseover, onmouseout, onclick for each button in window. bButtons (variable) defined inside tblnit().
/
/*
onmouseover
function tbButtonMouseOver ( ) { if(
(event. srcElement. id. substring (0, 3) =="btn" ) --& TBBUTTONDOWN != event . srcElement. id) event . srcElement .className = "buttonOver"; }
X
onmouseout ======================
*/
function tbButtonMouseOut ( ) { if (
(event. srcElement. id. substring (0, 3 )=="btn") ---- TBBUTTONDOWN ! = event . srcElement .id) event . srcElement .className = "buttonUp"; }
X
onclick ======================
*/ function tbButtonMouseClick ( )
{ var tmpld = event . srcElement . id; if (t pld. substring (0,3)=="img") var tmpObjeto = document .all ["btn" + tmpld. substring (3 , tmpld.length) ] ; else tmpObjeto = event . srcElement;
tbButtonPress (tmpObjeto) ;
1
/* ====================== muestra el panel correspondiente al boton presionado en el toolbar, previamente oculta el panel anterior de ser necesario.
*/ function tbButtonPress (objeto)
{ /*
si no hay ning'n botUn presionado, lo presiono y lo grabo. ======================
*/ if ( !TBBUTTONDOWN)
{ tbShowPanel (objeto . id) ; }
/*
si ya hay un botUn presionado y Este no es el que recibiϋ el click, lo levanto, y presiono el clickeado.
*/ else if (TBBUTTONDOWN --& TBBUTTONDOWN != objeto. id)
{ document. all [TBBUTTONDOWN] .className =
"buttonUp" ; tbShowPanel (objeto. id) ;
si se hizo click en el botUn ya presionado, se lo levanta.
*/ else if (TBBUTTONDOWN == objeto. id)
1 objeto. className = "buttonUp"; document . all [ tbBtnToDiv (TBBUTTONDOWN) ]. style.visibility = "hidden";
TBBUTTONDOWN = false;
tbChangeSize (46, tbHeight) ;
X
actualizaciUn de la variable que contiene el valor que indica si el objeto buscando sera ocultado o anclado.
esta variable sϋlo puede contener un estado siempre que se encuentre en el panel de posicionamiento o ocultamiento de objetos. =-.-.======-.==-.-.====-.===
*/ if (TBBUTTONDOWN == "btnhidding" )
{ changeMode ( "hide" ) ; } else if (TBBUTTONDOWN == "btnpos")
! changeMode ( "dock" ) ; } else
changeMode ( "none" ) ;
if (TBBUTTONDOWN == "btnpos") { var type = returnRadioVal ("typeOfPos") ;
document .all . typeOfPosFix. style .visibility (type == FIXED)? "inherit" : "hidden"; document .all . typeOfPosAnch. style .visibility = (type == DOCKED)? "inherit" : "hidden";
document . all . typeOfPosAnchTopAndLe t .style.visibility = (type == DOCKED)? "inherit" : "hidden"; document .all . typeOfPosCen. style .visibility = (type == CENTERED) ? "inherit" : "hidden"; document .all . fixed_info. style .visibility (type == CENTERED) ? "inherit" : "hidden";
document .all .anchor_apply__button. style.visibility = (type == DOCKED) "visible" : "hidden";
} else { document .all . ypeOfPosFix. style .visibility
= "hidden"; document . all . typeOfPosAnch. style .visibility
= "hidden";
document .all . typeOfPosAnchTopAndLeft . style .visibility = "hidden" ; document .all . typeOfPosCen. style .visibility = "hidden" ; document .all . fixed_info. style.visibility = "hidden";
document .all . nchor_apply_button . style.visibility = "hidden" ; } } /* tbButtonPress (objeto) */
/* ====================== muestro el panel correspondiente al botϋn btnName.
*/ function tbShowPanel (btnName) { var divName = tbBtnToDiv (btnName) ;
/*
si ya hay alg'n panel visible, lo oculto.
*/ if (TBBUTTONDOWN) {
document . all [tbBtnToDiv (TBBUTTONDOWN) ] . style . display = "none " ;
} /*
de lo contrario significa que no estaba maximizada.
else
tbChangeSize (289, tbHeight)
/* muestro el panel y declaro al boton correspondiente como el activo.
document .all [divName] . style. display = "inline"; document .all [divName] . style.visibility =
"visible" ,- document .all [btnName] .className = "buttonDown"; TBBUTTONDOWN = btnName;
if (divName == "Divhidding" ) {
document .all .anchor_apply_button. style .visibility == "hidden" ;
document .all .anchor_apply_button. style.display == "none";
}
cuando el panel se visualiza le asigno el texto del tϊtulo, Este se encuentra definido en el ALT del botϋn.
*/ document .all . theTitle. children [0] . innerHTML "<centerxb>" + documen . all [btnName] . children [0] .alt . toUpperCase ( ) + "</bx/center>" ;
} /* tbShowPanel (btnName) */
*
El formato de los nombres de los DIVs correspondiente a los botones es btnNOMBRE. Cada botϋn tiene su 'panel', que a la vez tambiEn es un DIV, Estos tienen el formato de nombre DivNOMBRE . Esto significa que al botϋn "bntselects" le corresponde el 'panel' cuyo id es 'Divselects'. function tbBtnToDiv (btnName)
{ return "Div" + btnName . substring (3 ,btnName. length) ;
i*
Cambia el tamaOo del toolbar en el parent (iframe) , y la barra de titulo (dentro del iframe) .
*/ function tbChangeSize (theWidth, theHeight)
{ document .all .DragBar. style .width = theWidth; parent .document .all .theToolBar. style .width = theWidth; parent .document .all .theToolBar. style.height = theHeight; parent . restoreToolBarPosition( ) ; } /* tbChangeSize (theWidth, theHeight) */
esta funcion es ejecutada en cada click a los botones de los paneles del toolbar (tbButtonPress () ) y tambiEn cuando se cambia el tipo de posiciUn (changeTypeOfPos 0 ) ;
*/ function changeMode (type)
{ if (type == "dock")
{ /<
SI estamos intentando cambiar el odo a anclar
if (PVFORM. typeOfPos [2] .checked == true &-- parent . SELECTFOR != "dock") {
/* ======================
Pregunto si la solapa ya esta en anclar
*/ parent . SELECTFOR = "dock" ; } else if (PVFORM. typeOfPos [2] .checked == false) { parent .SELECTFOR = " " ;
1
} else if (type == "hide") parent . SELECTFOR = "hide"; else if (type == "none") parent . SELECTFOR = "";
} /* changeMode (type) - */
*************************************************************************** *** /
/* FLASH ********************************************************************** *************************************************************************** ***/
/*
inserta el codigo fuente del flash correspondiente al shoshkele y lo reproduce . adem-s, inserta tambiEn el codigo fuente correspondiente a los layers para arrastrar, mostrar bordes, o resize.
*/ function changeFlashO { var pos = returnPositions 0 ;
var shTop = parselnt (pos . sh_all_anim_shoshkelizer. top) ; var shLeft = parselnt (pos . sh_all_anim_shoshkelizer. left) ;
var barraWidth = shWidth; var barraHeight = 20; var barraTop = parselnt (shTop) + parselnt (shHeight) ; var barraLeft = shLeft;
/*
html de la barra de draggin .
/ var laBarraHTML = ' <div id="laBarra" style="position:absolute; z-index:99; height:' + barraHeight + 'px; width:' + barraWidth + 'px; top:' + barraTop + 'px; left:' + barraLeft + 'px; background-Color :#C07358; " noselect="l"> ' +
' <div i id="resize_button" style="position: absolute; visibility:visible; width: 20px; height :20px; top:0px; left : '+ (barraWidth-20) +'px" noselect="l" img id="laBarra_resize_img" src=" ' + theSRC + ' img/resize_manual .gif" width="20" height="20" noselect="l" ondragstart="return false" alt="Resize swf"x/div>' + ' <font size= " 2 " color= "#000000 " ace="Verdana" noselect= " l " xb noselect= " l " xcenter noselect=" l " id=" laBarra_center" >Drag</ center x/bx/f ont > ' +
'</div>\n';
html del botϋn/opciϋn de mostrar contenido del flash when dragging .
*/ var maskFlagLayerHTML = ' <div id="maskFlagLayer" style="position: bsolute; z-index:99; height : 20px; width:62px; top:' + barraTop + 'px; left:' + barraLeft + 'px;">' + ' <img id="maskFlagImg" src="' + ( (SHOW_CONTENT_ON_DRAG_FLASH) ? theSRC + 'img/outlinel.gif ' : theSRC + ' img/outline2.gif ' ) + '" width="62" height="20" onclick="control . changeShowContentOnDrag () " alt="View swf outline">' +
1 </div>\n'
html del layer que contiene los bordes.
*/ var shAllAnim_bordersHTML = ' <div id="sh_all_anim_borders" style="visibility: hidden; border: #000000 1 ridge; position: absolute; z-index:99; top:' + shTop + 'px; left:' + shLeft + 'px; width:' + shWidth + ' ; height:' + shHeight + '"χ/div>\n';
HTML DEL FLASH
J var shAllAnimHTML = '<object id="sh_all_anim_shoshkelizer" style="width: ' + shWidth + 'px; height: ' + shHeight + 'px; display one; position: absolute; z-index:99; top:' + shTop + 'px; left:' + shLeft + 'px; " CLASSID="clsid:D27CDB6E-AE6D-llcf-96B8- 444553540000"
CODEBASE="http: //download.macromedia . com/pub/Shockwave/cabs/flash/swflash
Figure imgf000051_0001
var str = laBarraHTML + maskFlagLayerHTML + shAllAnim bordersHTML + shAllAnimHTML;
re-asigno las variables de ancho y alto en control. asp parent . shWidth = shWidth; parent . shHeight = shHeight ;
/*
~ si ya se habϊa escrito el flash alguna vez, debemos eliminar esa informaciϋn antes de volver a escribir el cϋdigo. ======================
*/
if (window.previewFlag) {
parent .document .all . sh_all_anim_borders . outerHTML = ' ' ;
parent .document .all .sh all anim shoshkelizer.outerHTML = ' ' ,- parent .document .all . laBarra. outerHTML = ''; parent .document .all .maskFlagLayer .outerHTML
}
/ *
insertamos el cϋdigo antes del final del BODY.
*/
parent .document .body. insertAdjacentHTML ( "beforeEnd" , str) ;
/*
inicio la reproduccion del landing spot
*l setTi eout ("parent -flashSetVariablesAndShow(l) ",2000) ,-
window.previewFlag = true;
} /* changeFlash ( ) */
X
devuelve un array con las propiedades de sh_all_anim_shoshkelizer y su barra de drag .
*/ function returnPositions ( ) { var toReturn = new Array ( ) ; toReturn. sh_all_anim_shoshkelizer = new Array(); toReturn.drag = new Array(); var currentPosType = returnRadioVal ( " ypeOfPos" ) ; if (currentPosType == FIXED) {
/* top y left del sh_all_anim_shoshkelizer */ toReturn. sh_all_anim_shoshkelizer . left = parselnt (PVFORM. fixleft.value) ; toReturn. sh__all_anim_shoshkelizer. top = parselnt (PVFORM. fixtop.value) ,-
/* top y left de la barra de drag. */ toReturn.drag. left = parseln (PVFORM. fixleft .value) ; toReturn . drag . top = parselnt (PVFORM. fixtop .value) + parselnt (shHeight) ;
/* centered flag. */ toReturn. centerFlag = false;
} else if (currentPosType == DOCKED) { var dockedObject = parent . lista [PVFOR . elancladoq. alue] ; dockedObj ectLeft = getX (dockedObject) ; dockedObjectTop = getY(dockedObject) ;
/* top y left del sh_all_anim_shoshkelizer */ toReturn. sh_all_anim_shoshkelizer . left = dockedObjectLeft + parselnt (PVFOR .'dockLeft .value) ; toReturn. sh_all_anim_shoshkelizer. top = dockedObjectTop + parselnt (PVFORM. ockTop. alue) ;
/* top y left de la barra de drag. */ toReturn. rag. left = toReturn. sh_all_anim_shoshkelizer. left ; toReturn.drag. top = toReturn. sh_all_anim_shoshkelizer. top + shHeight ;
/* centered flag. */ toReturn. centerFlag = false; } else
{ /* si en el formulario no hay valores, los seteo con valor cero. */ if ( !parselnt (PVFORM. leftCenter. value) ) PVFORM. leftCenter.value = 0; if (!parselnt (PVFORM. topCenter.value) ) PVFORM. topCenter.value = 0;
/* posiciUn centrada de para sh_all_anim_shoshkelizer */ var newCenter = (shGetWindowWidth ( ) - shWidth) / 2 ; var newTop = parselnt (PVFORM. topCenter .value) ; var newLeft = newCenter + parselnt (PVFORM. leftCenter .value) ;
/* top y left de sh_all_anim_shoshkelizer */ toReturn. sh_all_anim_shoshkelizer. left = newLeft; toReturn. sh_all_anim_shoshkelizer. top = newTop;
/* top y left de la barra de drag. */ toReturn. drag .lef = newLeft; toReturn.drag. top = newTop + parselnt (shHeight) ;
/* centered flag. */ toReturn. centerFlag = true;
/* new centered pos. */ toReturn.newCenter = newCenter; parent .newCenter = newCenter;
} return toReturn; } /* returnPositions ( )
*
oculto todos los botones y paneles.
*/ function tbHideAll ( )
{ for (var i=0; i<tbButtons . length; i++) { document . all [ tbButtons [i] ] .style. isibility = "hidden"; document .all [ tbBtnToDiv (tbButtons [i] ) ]. style .visibility = "hidden";
} }
esta funciUn se ejecuta en el ondblclick de DragBar,
*/ function tbMinMaxO
{ if ( ! indow. TBINITFLAG) tblnit () ;
/* si el estado era normal, oculto todo, y cambio el estado. */ if (TBSIZE=="normal") { tbHideAll ( ) ; tbChangeSize (46, 13) ; TBSIZE = "compact";
} /* si estaba minimizada vuelvo todo a la normalidad */ /* si habϊan totones presionados muestro el panel */ /* correspondiente a ese boton . */ /* seteo el nuevo estado . */ else if (TBSIZE=="compacf) if ( !TBBUTTONDOWN)
{ tbChangeSize (46, tbHeight) ; } else tbChangeSize (289, bHeight) ; tbShowPanel (TBBUTTONDOWN) ; }
/* habilito la visibilidad de cada uno de los botones. */ for(var i=0; i<tbButtons . length; i++) document .all [ tbButtons[i] ]. style.visibility = "visible"; TBSIZE = "normal"; } }
/'
EVENTS
/*
para que el iframe pueda arrastrarse por el parent es necesario capturar los eventos mousedown, mousemove, y mouseup para que envϊen la informaciϋn al parent . ======================
V function mouseDown(e) {
/* si el elemento en el que se est- presionando es */ /* DragBar (div) o imgDragBar (img) entonces debo setear */
/* true la variable mouseDownFlag para que el prϋximo */ /* evento (unmousemove) sepa que debe mover la barra. */
/* adem-s, le envϊo al parent el evento y la posiciUn */
/* para que pueda mover el iframe en el que estamos . */ tmpld = event . srcElement .id; if ( tmpld
== "DragBar" | | tmpld == "imgDragBar" )
{ window.mouseDownFlag = true; parent .mouseDown (event .offsetX, event. offsetY) ,- } esta funcion se ejcuta solamente despues de haber pasado por mousedown, y se ocupa de enviar la posicion actual interna del iframe en donde esta el mouse, paren .movelf calcula la diferencia y mueve el iframe entero.
*/ function mouseMoveO { if (window.mouseDownFlag)
{ /* le mando al parent la posiciUn y la orden. */ parent .movelf (event . clientX, event .clientY) ; return false; }
}
le envio la senial al parent (control .asp)
*/ function mouseUpO { if (window.mouseDownFlag) parent .mouseup ( ) ; { window.mouseDownFlag = null;
} }
/*
esto es para evitar la selecciϋn de texto.
*/ function selectStart ( )
{ if ( event . srcElement . tagName != "INPUT" ) return false; } TOOLBAR FORM
*/
function validateForm (theField, theError)
{ lastField = theField; , if (PVFOR [theField] .value
{ PVFORM [theField] . focus ( ) ; uvAlert (theError) ; return false; return true ; } /* function validateForm (theField, theError) */
anclar un objeto especificando sus propiedades.
*/ function dockAddManual ( )
{ var theSelect = PVFORM. agDock; var theSelectlndex PVFORM. tagDoc . options . selectedlndex; if (theSelectlndex == -1) return false; var theTag = theSelect .options [theSelectlndex] .value;
if (theTag == "A")
{ if ( ! validateFor ( "textA" , "completar campo")) return false;
else if (theTag == "IMG" || theTag == "IFRAME" theTag == "OBJECT") if ( !validateForm( "widthDock" , "completar campo!")) return false; if ( !validateForm( "heightDock" , "completar campo ! " ) ) return false; if ( !validateForm("anchindex" , "completar campo!")) return false;
if (theTag == "A") manualAnchor ( "A" , PVFORM. textA.value, "",
" " ) ,- else manualAnchor(theTa ,
PVFORM. anchindex.value, PVFORM.widthDock. alue, PVFORM. heightDock.value) ;
} /* dockAddManual ( ) */
function manualAnchor (objTag, objPropl, objProp2, obj Prop3 )
{ if (objTag == "A" ) var index = getlndexTagCollectionA (obj Propl) else var index = getlndexTagCollection (objTag, objPropl, objProp2, objProp3);
if (index != -1)
{ var objectFound parent .documen .all .tags (objTag) .item(index) ;
if (objTag != "A")
{ objectFound. theWidth = (objTag = "IMG")? objectFound.width : objectFound. offsetWidth; objectFound. theHeight = (objTag "IMG")? objectFound.height : objectFound. offsetHeight ;
} if (objTag == "IMG") parent .adObjManager (objectFound,
"dock") else if (objTag == "OBJECT") parent .declareObjectTo (index,
"capture", "dock") else if (objTag == "IFRAME") parent . iframeClicked(index, "hide" ) else if (objTag == "A")
parent . adObjManager (parent .document .all .tags (objTag) . item(index) , "dock") ;
} else uvAlert ( "There is no object with the selected properties in the current page.");
} /* function manualAnchor (objTag, objPropl, objProp2, objProp3) */
esta funcion recibe el tag y las propiedades de un objeto. si encuentra el objeto con esas caracteristicas, devuelve su referenda.
function returnObject (tag, propl, prop2 , index)
{ var toReturn = false; var obj Index = 0 ; docTags = document . all . tags (tag) ; for (var i=0; i<docTags . length,- i++)
{ if (tag == "SELECT" || tag == "INPUT")
{ prop2 = prop2. toLowerCase ( ) ; var condition = (propl != null)? (it. name == propl && it. type == prop2) : (it. type == prop2); else if (tag == " IFRAME" | | tag == "IMG" | tag == "OBJECT" )
{ var width = propl, height = prop2 ; if (width) var condWidth = (it.width == width || parselnt (it. offset idth) == width || it . style.posWidth == width);
if (height) var condHeight = (it.height height || parselnt (i .offsetHeight) == height || it . style.posHeight == height) ;
if ( (!width) && (height) ) var condition = condHeight;
else if ( (Iheight) --& (width) ) var condition = condWidth;
else if( (Iwidth) &-- (Iheight) ) var condition = true;
else if ( (width) --& (height) ) var condition = ( condWidth &-- condHeight )
if ( condition -.& (! index || (++objIndex index) ) )
if (action == "return")
window. shFlag = toReturn = it; break;
} else
{ it . style .visibility = action,- if (width && height && index) break,-
} if (action=="return" && shFlag) return toReturn; } /* function returnObject (tag, propl, prop , index) */
/ *
ocultar objetos manualmente especificando las propiedades
*/ function pvForm_HideAdd ( )
{ - /*
si no hay ningun tag seleccionado, detengo. ======================
*/ if ( PVFORM. tagHide. options. selectedlndex == -1) return false;
var pvFormTagHideValue = PVFORM. tagHide. options [PVFORM. agHide. options . selectedlndex] .value;
if (pvFormTagHideValue == "FORM")
{ var pvFormFormElementType = PVFORM. formElementTag .options [PVFORM. formElementTag . options . selectedlndex] . alue,- var pvFormTagHide = (pvFormFormElementType == "SELECT-ONE")? "SELECT" : "INPUT"; var pvFormTagName =
PVFOR . tagNameElemForm.value ; } else
{ var pvFormTagHide = pvFormTagHideValue ; var pvFormWidthHide = PVFORM. widthHide.value; var pvFormHeightHide =
PVFORM. heightHide . alue;
var pvFormHidelndex = PVFORM. hidelndex. alue;
var listalndex = parent .lista . lengths-
parent . lista [listalndex] = new Array (); parent .lista [listalndex] .tagName = pvFormTagHide;
parent .lista [listalndex] .manual = true;
if (pvFormTagHideValue != "FORM")
{ , parent . lista [listalndex] . theWidth pvFormWidthHide ; parent . lista [listalndex] . theHeight pvFormHeightHide;
parent .lista [listalndex] .index = pvFormHidelndex; parent . lista [listalndex] .name = (pvFormTagName)? pvFormTagName : null; parent . lista [listalndex] .hide = true;
parent . lista [listalndex] . type =
( PVFORM . tagHide . value " FORM" ) ? pvFormFormElementType : " " ,-
var pvFormSelect = PVFORM. theHiddenObj ; var tmpNewOptionlndex = ( IpvFormSelect. options. length) ? 0 : pvFormSelect .options .length;
if (pvFormTagHideValue == "FORM") { var tmpPropertyl = (pvFormFormElementType != "SELECT-ONE")? ("type=" + pvFormFormElementType) : ""; var tmpProperty2 = (pvFormTagName)? ("name=" + pvFormTagName) : ((pvFormHidelndex)? + pvFormHidelndex + "J" : ("ALL") ) ;
} else
var tmpPropertyl = ( ( (pvFormWidthHide) ? pvFormWidthHide ; "*") + "/" + ((pvFormHeightHide)? pvFormHeightHide : "*")); var tmpProperty2 = ( (pvFormHidelndex) ? + pvFormHidelndex + "f" : ("ALL"));
}
var tmpNewOptionText = "[" + pvFormTagHide + "]
+ tmpPropertyl + " " + tmpProperty2 ;
if (PVFORM. heHiddenObj .options [0] .text == "None selected" )
{ PVFORM. theHiddenObj .length = 0; var cant = 0 ; } else
{ var cant = PVFORM. theHiddenObj . length;
unaOpcion = document .createElement ( "OPTION" ) unaOpcion.value = listalndex; unaOpcion. text = tmpNewOptionText; PVFORM. theHiddenObj .options .add (unaOpcion) ;
PVFORM. theHiddenObj .options [cant] .selected = true;
} /* pvForm_HideAdd ( ) */
X
esta funcion le quita el estado de "oculto" a un objeto.
*/
function pvForm HideDelO {
/*parent .myDebug ( "parent .pvForm_HideDel" ) */ var pvFormSelect = PVFORM. theHiddenObj ; var sOptions = pvFormSelect .options ; if (sOptions . length) pvFormSelect .options [pvFormSelect .options . selectedlndex] = null ,-
} /* pvForm_HideDel ( ) */
/*
muestra u oculta los sub paneles de la solapa de posicionamiento dependiendo del tipo de posicion elegido.
*/ function changeAnchTable ()
{ if (PVFORM. tagDock. options [PVFORM. tagDock. selectedlndex] .value == "A") { document . all . anchWIDTHandHEIGHT . style . display = "none" ; document .all . anchTEXTandHREF . style. display = "inline"; document .all .Anchoringlndex. style .display = "none";
} else { document .all. anchWIDTHandHEIGHT. style. display = "inline"; document .all. anchTEXTandHREF. style. display = "none" ; document .all .Anchoringlndex. style. display = "inline"; }
} /* changeAnchTable () */ muestra u oculta los sub paneles de la solapa de posicionamiento dependiendo del tipo de posicion elegido.
*/ function ChangeTypeOfPos (type)
1 if (previewFlag) {
lastPosType = pvForm_posType; pvForrr_posType = type;
setUpAllPos (parent .document .all . sh_all_anim_shoshkelizer . style .posLeft , paren .documen .all . sh_all_anim_shoshkelizer. style .posTop) ;
if (type==FIXED) { if (lastPosType==CENTERED &-- window.previewFlag)
parent .onresizeFlag = false;
}
changeMode ( ' none ' ) ; borrarAncla ( ) ,- } else if (type==DOCKED)
( changeMode ( ' dock' ) ;
} else if (type==CENTERED) if (lastPosType==FIXED && window. previewFlag)
parent .onresizeFlag = true;
changeMode ( ' none ' ) ; borrarAncla () ;
if (TBBUTTONDOWN == "btnpos")
documen .all . typeOfPosFix. style .visibility = (type == FIXED)? "inherit" : "hidden"; document .all . typeOfPosAnch. style .visibility = (type == DOCKED)? "inherit" : "hidden";
document .all .typeOfPosAnchTopAndLeft . style.visibility = (type == DOCKED)? "inherit" : "hidden"; document . all . typeOfPosCen . style .visibility = (type == CENTERED) ? "inherit" : "hidden"; document .all . fixed_info. style .visibility = (type == CENTERED) ? "inherit" : "hidden";
document .all . anchor__apply_button . style .visibility = (type == DOCKED)? "visible" : "hidden";
} /* changeTypeOfPos (type) */
function showHidePosDiv (posType) {}
mueve el shoshkele y su barra a una posicion absoluta. function moveShoshToTheFixPos ( )
{ var pos = returnPositions ()
parentShMove (parent .document .all . sh_all_anim_shoshkelizer, pos.sh all anim shoshkelizer .left, pos.sh all anim shoshkelizer . top) ; ~ ~ " parentShMove (parent . document .all . sh_all_anim_borders, pos.sh_all_anim_shoshkelizer.left, pos . sh_all_anim_shoshkelizer. top) ; parentShMove (parent .document .all . laBarra, pos . drag . left , pos . drag . top) ,-
parentShMove (parent .document .all .maskFlagLayer, pos . drag . left , pos . drag . top) ,-
if (pos .centerFlag) parent .window. newCenter = pos . newCenter ; else parent .window. newCenter = false; }
/*
elimina el estado de "anclado" a un objeto. ======================
*/ function borrarAncla ( )
{ if (PVFORM. elancladoq. alue != 0) { parent . SELECTFOR = ' dock ' ; parent .deleteDock (PVFORM. elancladoq. value) ;
PVFORM. elanclado.value = ' ' ; PVFORM. elancladoq.value = ' ' ; } /*
muestra el subpanel correspondiente al objeto elegido que sera ocultado ======================
*/ function changeHideTable ( )
{ var COND = (PVFORM. tagHide. options [PVFORM. agHide. selectedlndex] .value != "FORM");
document. all. tabHidlmg. style. display = (COND)? "inline" : "none"; document .all .tabHidForm. style.display = (COND)? "none" : "inline";
} /* function changeHideTable ( ) */
/* ======================
INICIO SAVE & Apply (generacion del codigo)
*/
/*
devuelve un numero random
function randNumber( ) { return parselnt (Math. random() *1000)+1; }
Esta es la funcion que se ejecuta al presionar los botones SAVE o APPLY. */ function sendData (saveFlag)
{ if( returnRadioVal ( "typeOfPos") == DOCKED &-- !PVFORM. elancladoq. alue )
{ var theError = "You have selected to dynamically position the Shoshkele based on another\n" +
"objects location. You must choose an object to anchor the Shoshkele to or\n" + "change the positioning method.";
uvAlert (theError) ; return false; }
string = queryString_generator ( ) ;
window. saveParams = string;
/*
saveFlag solamente tiene valor cuando se presiona APPLY
*/
/* apply */ if (saveFlag)
{ /*
db_traffic.asp sera llamado desde dentro de un iframe. luego de ejecutarse llamara a parent . applyOnload ( )
*/ openlnlframe ( "db_traffic.asp" + string + "&apply=" + saveFlag + "--JOB=SAVES-RAND=" + randNumber ( ) ) ;
}
/* save */ else { openlnlframe ("db_traffie .asp" + string + "&apply=" + saveFlag + "&JOB=SAVE&RAND=" + randNumber ()) ;
} /* function sendData (saveFlag) */
/* ====================== abre una ubicacion dentro de un iframe
*/ function openlnlframe (addr) thelframe. location. replace (addr) ;
function setQSVariable (variableName, variableValue) { qs [variableName] = variableValue; }
Es llamado por db_traffic .asp (sendData (1) ) desde dentro del iframe.
Abrira dentro del mismo iframe desde el cual fue llamado al sub-modulo que generara el codigo fuente del timeline. Luego de generar el codigo fuente llamara a saveJS enviandole como argumento al codigo fuente.
*/ function applyOnload ( ) { openlnlframe ( "code_gen. asp" + string + "--pvTipo=standard&RAND=" + randNumber ()) ; }
genera y guarda el codigo de un shoshkele
una vez que tiene el codigo generado abre form.html dentro del mismo iframe.
form.html ejecuta formOnLoad en su onload
*/ function saveJS (theCode) { if ( ! indow. tml_j s )
{ window. tml_j s = theCode; openlnlframe ( "code_gen. sp" + window. saveParams + "&pvTipo=iframe--RAND=" + randNumber ()) ;
} else { window. tml_if = theCode; openlnlframe ( " form. html" ) ;
}
}
/*
envia al servidor el codigo fuente generado. function formOnloadO
thelframe. document .forms [0] .action = "db_traffic.asp" + window. saveParams + "&JOB=WRITE TML&RAND=" + randNumber () ;
thelframe .document . forms [0] .TML JS.value = window . tml_j s ; thelf ame. document .forms [0] .TML IF. alue = window. tml_if; thelframe . document . forms [0] . submit ( ) ;
window . tml_j s = window. tml_if = ' ' ;
/*
confirmaciones .
function saveOk() uvAlert ( "Changes have been saved successful ! ") ; }
function saveAndApplyOk ( ) uvAlert ( "Changes have been saved and applied successfully");
function saveError (msg) uvAlert (msg) ;
}
function save error (desc) if (! desc) var desc = "save error!!!!!»; uvAlert (desc) } I*
FIN SAVE & Apply (generacion del codigo)
*/
I*
QUERYSTRING
*/
/*
genera una cadena del tipo querystring que contiene toda la configuracion del shoshkele actual
*/ function queryString_generator( )
{ var paramsl = "shLocation=" + shLocation
+ "&shWidth=" + shWidth
+ "&shHeight=" + shHeight;
var currentPos = returnRadioVal ( "typeOfPos" ) ;
var tmpTop, tmpLeft; if (currentPos == FIXED)
tmpTop = returnlnputVal ( "fixtop" ) ; tmpLeft = returnlnputVal ("fixleft") ; } else if (currentPos == DOCKED)
{ tmpTop = returnlnputVal ( "dockTop") ; tmpLeft = returnlnputVal ( "dockLeft" ) ;
} else if (currentPos == CENTERED)
{ tmpTop = returnlnputVal ("topCenter" ) ,- tmpLeft = returnlnputVal ( "leftCenter") ,-
var params2 = "posType=" + returnRadioVal ( "typeOfPos " )
+ "&top=" + tmpTop + "&left=" + tmpLeft + "&dockHidding=" + queryStringDockHidding ( )
+ "&iniLs=" + (( (qs . iniLs) ? (parseln (qs . iniLs) ) : ( (parent . iniLs) ? parent . iniLs : 0)))
+ "--eas=" + ( ( (qs.eas)? qs.eas : ( (parselnt (parent . eas) ) ? parent. eas : 0) )
+ "S-finLs=" + (((qs.finLs)? qs.finLs : ( (parselnt (parent . finLs) ) ? parent. finLs : 0))
+ "s-finish=" + (( (qs . finish) ? qs. finish : ( (parselnt (parent . finish) ) ? parent . finish : 0)))
+ "5-posx=" + (((qs.posx)? qs.posx : ( (parselnt (parent .posx) ) ? parent. posx : 0)))
+ "δ-posy=" + (((qs.posy)? qs.posy : ( (parselnt (parent .posy) ) ? parent. osy : 0) ) ) ;
string = "?paramsl=" + escape (paramsl)
+ "--params2= " + escape (params2) + "&IdMediaDet=" + qs . IdMediaDet + "&IdCreative=" + qs . IdCreative + "&IdCreativeProps=" + s . IdCreativeProps + "&ldAnimationFile=" + qs . IdAnimationFile
+ "&IdBannerFile=" + qs . IdBannerFile + "&Flaco=" + qs. Flaco + "&LS=" + qs.LS;
return string; } /* queryString_generator () */
function queryStringDockHidding ( )
{ var toReturn = ' ' ; var ii = 0; for (var i=0; i<parent . lista. length; i++)
{ var objeto = parent .lista [i] ;
if( returnRadioVal ("typeOfPos") != DOCKED ) {
objeto.dock = false;
if (objeto. selected)
{
objeto. selected = false; objeto.hide = true;
/* es necesario verificar que el objeto se encuentre oculto o anclado. */ if( objeto.hide || objeto. dock objeto. selected ) if(ii > 0) toReturn += "|"; toReturn += returnDockHiddingObjectProperties (objeto) ;
11++;
return toReturn;
} /* queryStringDockHiddingO */
/*
devuelve el string correspondiente a las propiedades del objeto solicitado. este puede estar anclado, ocultado, o ambos .
esta funcion siempre es Hamada internamente por queryStringDockHiddingO
*/ function returnDockHiddingObjectProperties (objeto)
( var tag = objeto. tagName . toLowerCase () ,-
var objectlndex = (objeto.manual ) ? objeto. index :
0; var theAction = (objeto . selected) ? 3 : ( (objeto.dock) ? 2 : 1) ,-
if (tag == "a") { return ("a!" + escape (objeto. text) ) ,-
1 else if (tag == "select" || tag == "input")
{ return (objeto. tagName + "!" + ( (objeto. type
== "radio")? "null" : ( (obj eto.manual) ? 0 : returnDockHiddinglndexForm(objeto) ) ) + "!" + objeto.name + "!" + objeto. type) ;
else if (tag == "iframe" || tag == "img" || tag
"object")
{ var tmpReturn = tag + "!" +
( (objectlndex) ? objectlndex : returnDockHiddinglndex(objeto) ) + "!" +
objeto. theWidth + "!" +
objeto. theHeight + "!" + theAction;
return tmpReturn;
} else
{ return false; }
} /* returnDockHiddingObjectProperties (objeto) */
function returnObjectPropertiesIndex(obj )
{ if ( !obj . item) obj . item = returnCollectionIndex(obj ) ; if( obj. agName == "IMG" || obj. tagName == "OBJECT" || obj. tagName == "IFRAME" )
{ return returnDockHiddingIndex(obj ) ;
} else if ( obj. tagName == "SELECT" || obj . tagName == "INPUT" ) { return returnDockHiddingIndexForm(obj ) ,-
} } /* function returnObjectPropertiesIndex(obj ) */
function returnCollectionIndex(obj ) { var theColl = parent . document .all . tags (obj . tagName) ; for (var i=0; i<theColl . length; i++)
{ if (obj == theColl. item (i) ) return i ; return 0 ,- } /* function returnCollectionIndex(obj ) */ function returhDockHiddinglndexForm(objeto) { var coll = parent . document . ll . tags (objeto . tagName) ;
var theNa e = objeto.name; var theType = objeto . type ,-
var matches = 0 ,- for (var i=0; i<coll . length; i++)
{ var objetoActual = coll. item (i)
var cond = (( 'objeto.name | | objetoActual .name == theName) && objetoActual .type == theType);
if (cond)
{ matches++ ,-
if (objeto == objetoActual)
{ return matches;
}
} }
}
/*
devuelve el index del objeto dentro de la colecciϋn de acuerdo a las propiedades del mismo. esto significa que si el objeto tiene width=200 y height=200, buscar- saber si hay otros objetos con estas propiedades, y entonces sabr- si este es el lro, 2do, etc...
esta funcion siempre es Hamada internamente por returnDockHiddingObj ectProperties () ;
*/ function returnDockHiddinglndex(objeto)
{ var coll = parent .document .all . tags (objeto. tagName) ; var ii = 0; for(var i=0; i<parselnt (coll . length) ; i++)
{ var objetoActual = coll . item(i) ,-
/* a los OBJECT & IFRAMES se los puede identificar por width/offsetWidth, height/offsetHeight */ var obj ectOrlframe = (objeto. tagName == "IFRAME" || obj eto . tagName == "OBJECT"); var widthVar = (objectOrlframe) ? "offsetWidth" : "width"; var heightVar = (objectOrlframe) ? "offsetHeight" : "height"; if ( parselnt (objeto. item) == i )
{ return ++ii; break;
} else if ( (i < parselnt (obj eto. item) ) && (objetoActual [widthVar] == objeto. theWidth) && (objetoActual [heightVar] == objeto . theHeight) ) { ii++;
} /* for */ return 0; } X returnDockHiddinglndex(objeto) */
X
end SAVE
*/
/*
end QUERYSTRING
*/ esta funcion lee la posicion actual del layer sh_all_anim_shoshkelizer calcula los valores correspondientes a cada posicion los asigna
*/ function setUpAllPos ( ) { /* posicion actual del flash. */ var left = parent .document .all . sh_all_anim_shoshkelizer . style .posLeft; var top = parent .document .all . sh all anim shoshkelizer . style .posTop; " ~ /* fixed */ PVFORM. fixleft.value = left; PVFORM. fixtop.value = top;
/* centered */ /*newCenter = ( (shGetWindowWidthO - shWidth) / 2); */ newCenter = ( (shGetWindowWidthO - parent .document .all. sh_all_anim_shoshkelizer. style .posWidth) / 2) ;
PVFORM. leftCenter.value = parselnt (left - newCenter); PVFORM. topCenter. alue = top;
/* ANCLADO */ /* si el shoshkele est- anclado a algun objeto, entonces */ /* obtengo la posiciUn del flash en relaciϋn a tal objeto. */ if (PVFORM. elancladoq.value)
{ objectLeft = get (parent . lista [PVFORM. elancladoq. alue] ) ; objectTop = getY (parent .lista [PVFORM. elancladoq.value] ) ; PVFORM. dockLeft. value = (left - objectLeft) ;
PVFORM. dockTop.value = (top - objectTop) ;
} }
function changeShowContentOnDrag ( )
{
SHOW_CONTENT_ON_DRAG_FLASH = (SHOW_CONTENT_ON_DRAG_FLASH) ? false : true; parent . document . all .maskFlaglmg . src = (SHOW_CONTENT_ON_DRAG_FLASH) ? theSRC + "img/outlinel .gif " : theSRC + "img/outline2.gif " ;
} /* function changeShowContentOnDrag ( ) */
QUIT
si no hizo ning'n cambio, si no grabϋ, o si hizo cambios luego de haber grabado, entonces se le preguntar- si guiere grabar o no.
function pvQuitO
if ( qs. IdMediaDet == 0 | | window. saveParams == queryString_generator () ) window. saveFlag = true;
if ( !window. saveFlag && parent . iniLs initial && (paren . iniLs_initial == parent. iniLs && parent . eas_initial == parent. eas && parent .finLs_initial == parent. finLs && parent . finish_initial == parent .finish && parent .posx_initial == parent.posx && parent .posy_initial == parent.posy) )
{ var iniLs_tmp = parent . iniLs ; var finLs_tmp = parent . finLs; var finish_tmρ = parent . finish; var eas_tmp = parent . eas,- var posx_tmp = parent. osx; var posy_tmp = parent.posy;
parent .save (0, 0, 0, 0, 0, 0) var tmp_saveParams = queryString_generator ( ) ,-
if( qs . IdMediaDet == 0 window. saveParams == tmp_saveParams ) window. saveFlag = true;
parent . save (iniLs_tmp, finLs_tmp, finish_tmp, eas_tmp, posx_tmp, posy_tmp) ;
}
if ( window. saveFlag )
{ top. close () ; else
if (confirm ( "Any changes will be lost . Proceed? " ) )
top. close () ;
}
} /* function pvQuitO */
/'
Funciones para restaurar los objetos ocultados y anclados
function parseDockHiddingQS (str)
{ var toReturn = new Array ( ) ,- var strSplited = str. split (' | ') ,-
for(var i=0; i<strSplited. length; i++)
{ var properties = strSplited [i] .split ('!') ; var tag = properties [0] . toLowerCase () ,-
toReturn [i] = new Array (); toReturn [i] = properties; toReturn [i] .tagName = tag;
if (tag == "a")
{ toReturn [i] .text = toReturn [i] .propl unescape (properties [1] ) ; toReturn [i] .action = DOCK; toReturn [i] .prop2 = "null"; toRetur [i] .index = "null";
} else if (tag == "select" || tag == "input")
toReturn [i] .index parseln (properties [1] ) ; toReturn [i] .name = toReturn [i] .propl = properties [2] ; toReturn [i] .type = toReturn [i] .prop2 = properties [3] ; toReturn[i] .action = HIDE;
} else if (tag == "iframe" || tag tag == "object")
{ toReturn [i] .index = parselnt (properties [1] ) ; toReturn [i] .width = toReturn [i] .propl = parselnt (properties [2] ) ; toReturn [i] .height toReturn [i] .prop2 = parselnt (properties [3] ) ; toReturn [i] .action parselnt (properties [4] ) ;
if ( ( window.pvHideFlag != true --& window.pvHideFlag != false ) £-& (tag == "select" || tag == "input" | toReturn[i] .action == HIDE || toReturn[i] .action == BOTH ) )
{ window.pvHideFlag = true;
/*return toReturn;*/
restoreDH(toReturn) ; } /* function parseDockHiddingQS (str) */ function setDockedObj ect (object) { window.DOCKEDOBJECT = o ject ,- }
se ocupa de restaurar los objetos que anteriormente fueron ocultados o anclados. se ejecuta solamente cuando se vuelve a editar un shoshkele antes grabado.
el array que recibo tiene el siguiente formato pero las propiedades cambian segun el tipo de objeto que sea.
*/ function restoreDH(objArray)
for (var i=0; i<objArray. length; i++)
{ var obj = objArray [i] ,-
if (obj .tagName == "img")
{ var index = getlndexTagCollection (obj .tagName, obj. index, obj.propl, obj.prop2);
var action = ACTIONS [obj .action] ;
if (index != -1)
{ var obj ectFound = parent .document . all . tags (obj .tagName) .ite (index) ;
objectFound. theWidth = objectFound.width,- objectFound. theHeight = objectFound.height; if ( obj. action == BOTH || obj. action == HIDE)
parent .adObjManager (parent .document .all .tags (obj .tagName) .item(index) , "hide"),-
if( obj. action == BOTH obj. action == DOCK)
setDockedObj ect (parent . documen . all . ags (obj . tagName ) . item ( index) ) ;
parent .adObjManager (objectFound, "dock");
} }
if (qs.posType == DOCKED --& (obj. action == DOCK || obj. action == BOTH) && index == -1 )
{ qs . top = 0 ,- qs.left = 0;
restorePosition (FIXED)
alert ("The object previously selected for dynamically positioning the Shoshkele is missing. The creative is now in a fixed coordinate. You may select a new object for anchoring."),-
else if (obj . tagName == "input" || obj. tagName == "select")
var index = formGetlndexTagCollection (obj .tagName, obj. index, obj. name, obj. type)
var action = "hide";
if (index != -1) { var objectFound = parent . document . all . tags (obj . tagName) . item (index) ,- • objectFound. objName = objectFound.name,-
parent .adObjManager(parent .document .all . tags (obj .tagName) .item(index) , "hide") ,-
' '
} else if (obj . tagName == "object") { var index = getlndexTagCollection (obj .tagName, obj .index, obj .propl, ' obj .prop2) ;
if (index != -1)
1 var action = ACTIONS [obj". action] ;
var obj ectFound = parent .document .all . tags (obj .tagName) .item(index) ; objectFound. theWidth = objectFound. offsetWidth; objectFound. theHeight = objectFound. offsetHeight ;
if ( obj .action == DOCK || obj. action == BOTH ) {
parent .declareObjectTo (index, "capture", "dock");
setDockedObject (objectFound) ;
}
if ( obj .action == HIDE || obj. ction == BOTH ) { parent .declareObjectTo (index, "capture", "hide");
}
else if (obj .tagName == "iframe")
{ var index = getlndexTagCollection (obj .tagName, obj. index, obj.propl, obj.prop2);
if (index != -1)
{ var action
ACTIONS [obj .action] ;
var objectFound parent .document .all . tags (obj .tagName) .item(index) ,- objectFound. theWidth = obj ectFound . offsetWidth; objectFound. theHeight objectFound . offsetHeight ,-
if (obj .action == BOTH obj. action == DOCK)
setDockedObj ect (objectFound) ,-
parent . iframeClicked(index, "dock") ,-
}
if (obj .action == BOTH obj. action == HIDE) {
parent . iframeClicked(index, "hide") ,- else if (ob .tagName == "a")
{ var index = getIndexTagCollectionA(obj .text) ;
if (index != -1)
setDockedObject (parent .document .all .tags (obj .tagName) . item (index) ) ;
parent .adObjManager (parent .document .all .tags (obj .tagName) .item (index) , "dock") ;
} /* restoreDH (objArray) */
function getlndexTagCollectionA(text) var coll parent .document . all . tags ( "A") ; for(var i=0; i<coll . length; i++) { obj = coll. item (i) if (obj . innerText == text) return i return -1; } /* function getlndexTagCollectionA(text) */ function getlndexTagCollection (tag, index, width, height) { var coll = parent .document . all . tags (tag) ; ar matchs = 0 ; for(var i=0; i<coll -length; i++)
{ var obj = coll . item (i) ; var condWidth = (width)? (obj .width == width || parselnt (obj .offsetWidth) == width || obj . style .posWidth == width) : false;' var condHeight = (height)? (obj .height == height || parselnt (obj .offsetHeight) == height || obj . style.posHeight == height) : false; if ( condWidth && condHeight && ( ! index | | ++matchs == index) ) { return i;
} } return -1; } /* getlndexTagCollection (tag, index, width, height) */ function formGetlndexTagCollection (tag, index, name, type) { var coll = parent . document .all . tags (tag) ; var matchs = 0 ; for (var i=0; i<coll .length; i++) { var obj = coll . item (i) ,- var condl = (type == obj. type); var cond2 = (iname | | obj .name == name) ,- if ( condl && cond2 && (! index ||
++matchs == index) ) { return i ;
} } return -1; } /* formGetlndexTagCollection (tag, index, name, type) */
/*************************************************************************** *************/
/** ( END RESTORE
\ *********************************************************************** *************************************************************************** *************
/*************************************************************************** *************
/**( GENERIC FUNCTIONS )*****************************************************************/
/*************************************************************************** *************/
/*
devuelve el x/y de un obj eto
J function getX(obj){ var shX=0; while (obj ){ shX += obj .offsetLeft ; obj = obj .offsetParent; } return shX; } function getY(obj){ var shY=0 ;while (obj ) {shY+=obj .offsetTop,-obj=obj .offsetParent ; }return shY;
/"
devuelve el valor del grupo de RADIOS especificado.
*/ function returnRadioVal (radioObj )
{ var obj =
PVFORM[radioObj] ,- for(var i=0; i<obj .length; i++) { if (obj [i] .checked)
{ return obj [i] .value;
} }
1
/* ====================== devuelve el valor de la opciϋn selecoionada en un SELECT.
*/ function returnSelectVal (obj ) return
PVFORM [obj] .options [PVFORM [obj] .options . selectedlndex] .value;
}
/*
devuelve el valor de un input .
*/ function returnlnputVal (inputName)
{ return PVFORM [inputName] .value; }
====================== recorre el select objString y devuelve el Indice del option con valor = val .
function getSelectedlndexByValue (objString,val)
{ tmpObj = PVFORM [objString] ,- for(var i=0; i<tmpObj . length; i++) { if (tmpObj .options [i] .value == val) return i ;
checkea el radio del grupo objString que contenga valor igual a val.
function CheckRadioByValue (objString,val)
var tmpObj = PVFORM [objString]
for(var i=0; i<tmpObj . length; i++)
{ if (tmpObj [i] .value == val)
{ tmpObj [i] .checked = true; }
}
1
function ShGetWindowWidthO /*parent .myDebug ("parent . shGetWindowWidth" ) ; */ return parent .document .body.clientWidth-16 ; }
/*
mueve un layer
*/ function parentShMove (layer, left, top) { layer. style .posTop=top,- layer . style .posLeft=left ;
} function inputKeyPress ( )
{ if ( ! (event .keyCode == 45 || (event .keyCode > 47 δ-& event . eyCode < 5- )) ) return false; } /* function inputKeyPress 0 */
var validaNumbahFields = new Array ( ' fixtop' , ' fixleft ' , ' topCenter' , ' leftCenter' , 'dockTop' , ' dockLeft ' , ' widt hDock' , 'heightDock' , 'anchindex' , 'hidelndex' , 'widthHide' , 'heightHide' , 'resize Width' , ' resizeHeight ' ) ;
for(var i=0; i<validaNumbahFields . length; i++) { document .forms [0] [ validaNumbahFields [i] ] .onkeypress = inputKeyPress; }
function resetPage
{ if (window. saveParams)
{ window. oldSaveParams = saveParams; window. saveParams = "default .asp" + window. saveParams + "&fSize=" + queryString_readVar (parent . location.href , "fSzie") + "&url=" + queryString_readVar (parent .location.href , "url"); top. location. href = saveParams;
} else { var currentAddr = top. location.href; var numeral = currentAddr . indexOf ( "#" ) ; if (numeral != -1) currentAddr = currentAddr. substring (0 , numeral) ,- top. location. ref = currentAddr;
} } /* function resetPageO */
function returnObjectStatus (objeto) { return parent . returnObjectStatus (objeto) ,- } function setValue (objElement , objValue)
{
PVFORM [objElement] .value = objValue;
I*
end GENERIC FUNCTIONS */
/*
begin reject and approve
function pvRejectO
{ window. open ("wnd_reject .asp?IdAnimationFile=" + qs . IdAnimationFile + "&IdBannerFile=" + qs . IdBannerFile, "RejectFile" , "width=300 , height=200" ) ;
}
function approvedOkO uvAlert ( "approved! " ) ;
}
function approveError 0
{ uvAlert ( "Approve error ! " ) ;
function pvApprove ( ) { if (confirm ("The
Shoshkele will be approved")) { var approvelmg = new Image ( ) ,- approvelmg. onload = approvedOk; approvelmg . onerror = approveError; approvelmg. src = "db_traffic . asp?IdAnimationFile=" + qs . IdAnimationFile + "&IdBannerFile=" + qs . IdBannerFile + "&JOB=APPROVE" ;
} else
{ return false; }
}
end rej ect and approve
</script>
</body> </html>
FIN de toolbar . asp
//-->
**************************************************************************** ***
**************************************************************************** ***
**************************************************************************** ***
**************************************************************************** ***
Module 2: "Code Generator" Code
// TEMPLATE //////////////////////////////////////////////////////// if (window. startView) shView ( ) ; var flashWidth={FLASH_WIDTH} , flashHeight={FLASH_HEIGHT} , shTop= {P0S_T0P} , shLeft={
POS_LEFT},flashName=' {FLASH_FILE} ' , landingFlag = true;
// This line is included only if {LS_FLAG} is 1 var iniLs = {LS_INI}, eas = {LS_EAS}, finLs = {LS_FIN}, finish =
{LS_FINISH}, posx = {LS_X} , posy = {LS_Y} , url = 'undefined'; var shPosType = ' {POS_TYPE} ' ; function shFlashObj ( ) { return ' <OBJECT ID="sh_all_anim"
STYLE="position: absolute; op: '+shTop+ 'px;left : '+shLeft+ 'px; z- index:1000;display:none,-" CLASSID="clsid:D27CDB6E~AE6D-llcf-96B8-
444553540000"
CODEBASE="http://download.macromedia.eom/pub/shockwave/cabs/flash/swflash. ca b#version=4, 0,2,0" width=" ' +flashWidth+ ' " height=" ' +flashHeight+ ' "xPARAM
NAME=movie VALUE=" ' +theSRC+flashName+ ' "xPARAM NAME=quality
VALUE=highxPARAM NAME="L00P" VALUE="false" xPARAM NAME="wmode"
VALUE="transparent"xPARAM NAME=SALIGN VALUE=TxPARAM NAME=MENU
VALUE=FALSEx/OBJECT>' ; } function shClose 0 { shFinishO; if (shFrameObject .document . all . sh_all_anim) shFrameObject .document .all . sh_all_anim. style .display= 'none' ; } function shReplay(){ sh_all_anim. style .display = "none"; sh_all_anim.movie =
"http://a619.g.akamai.net/7/619/2021/v001/64.42.219.1/web/mmf/pagain.swf " ; if (window. shGoHide) shGoHideO; if (window. landingFlag) { setTimeout ("sh_all_anim.movie = '" + theSRC + flashName + "';", 100); setTimeout ( "shLandingSpot () ; " , 00) ; }else{ setTimeout ( "sh_all_anim.movie =
'" + theSRC + flashName + "';", 100); setTimeout ( "sh_all_anim. style .display
= 'inline' ", 200) ; } }
// This line is included only if {LS_FLAG} is 1 function shLandingSpot () { if ( ! sh_all_anim.wmode ){ setTimeout ("shLandingSpot () ; ", 100); }else{ sh_all_anim.SetVariable ShkLandingMode ' , ' play ' ) ,- sh_all_anim.SetVariable ShkConectado ' , ' 1 ' ) ; sh_all_anim.SetVariable ShkLandinglnicio' , parselnt (iniLs) ) ; sh_all_anim. SetVariable ShkLandingEasing' , parselnt (eas) ) ; sh_all_anim. SetVariable ShkLandingLargo ' , parselnt (finLs) ) ,- sh_all_anim. SetVariable ShkTimeFinish' , parselnt (finish) ) ; sh_all_anim. SetVariable ShkLandingPosX' , parselnt (posx) ) ,- sh_all_anim. SetVariable ShkLandingPosY' , parselnt (posy) ) ; sh_all_anim. SetVariable ShkPlayAncho ' , parselnt (flashWidth) ) ; sh_all_anim. SetVariable ShkPlayAlto' , parselnt (flashHeight) ) ; sh all anim. SetVariable ShkRandomPing ' , url) ; setTimeout ("sh_all_anim. style. display = 'inline'", 100); } }
// This line is included only if: // * It is necessary to hide an object. // * An object is used as anchor. function returnOrHide (tag, propl,prop2 , index, action) { var toReturn = false; var objIndex = 0; docTags = shFrameObject .document .all . tags (tag) ,- for (var i=0; i<docTags .length; i++) { var it = docTags.item(i) ; if (tag=="A" ) { var condition = it . innerText . indexOf (propl) != -1; }else if (tag == "SELECT" || tag == "INPUT") { prop2 = prop2. toLowerCase () ; var condition = (propl != null)? (it.name == propl && it. type == prop2) : (it. type == prop2); }else if (tag == "IFRAME" || tag == "IMG" || (tag == "OBJECT" && ( ! it . id || it . id != "sh_all_anim") ) ){ var width = propl, height = prop2 ; if (width) var condWidth = (it.width == width || parselnt (it . offsetWidth) == width || it . style.posWidth == width); if (height) var condHeight = (it.height == height || parselnt (it .offsetHeight) == height || it . style.posHeight == height); if ( (Iwidth) &-- (height) ) var condition = condHeight; else if ( (Iheight) &£- (width) ) var condition = condWidth; else if ( (Iwidth) && (Iheight) ) var condition = true; else if ( (width) --& (height) ) var condition = ( condWidth --& condHeight ) ; } if ( condition --& ( ! index | | (++obj Index == index)) ){ var debug = "condition = " + condition + ";\n" + "! index = " + ! index + ";\n" + "obj Index = " + obj Index + ";\n"; if (action=="return") { toReturn = it; break; }else{ it . style .visibility = action; if (width && height --& index) break; } } var condition = false; } if (action=="return" && toReturn) return toReturn; } function sh_finish ( ) { shFinishO ; }
// This is included always: function shCreate () {if ( (shFrameObject .document . readyState=="complete" ) &--! shFrameObjec t . shFramePointer) {shFrameObject . shFrameObject=window; shFrameObj ect .shFramePo inter=window;var shScriptString=window. shReposition? 'window. siteResize=window.onresize;window
. onresize=shFramePointer . shReposition; ' : ' ' ;shScriptString+=window. shScroll? ' window. onscroll=shFramePointer.shScroll; ' : ' ' ; if (window. thelndex) {if (shPosTyp e!="fixed") shScriptString+=overwriteEvents+ ' overwriteEvents ( ) ; ' ; shFrameObj ect .document . body. insertAdjacentHTM ( ' afterBegin ' , shFlashObj ( ) + ' <SPAN
STYLE="display:none">OLAF<SCRIPT
DEFER>'+shScriptString+'<\/SCRIPTx\/SPAN>' ) ; }else{eval (shScriptString) ; }win dow. setTimeout ( "window. sh_all_anim=shFrameObj ect .document . all . sh_all_anim; " ,
100) ;window. setTimeout ( "if (window. shDisableOtherAds) window. shDisableOtherAds () ;shCommand() ; shPlayShoshkele ( ) ;",500) ; }else setTimeout ( ' shCreate () ' , 100) ; } function shCommand(){ var shResult = false; if ( (shResult=flashGetVar( ' SH_JS_CLICK' ) ) ) shClickO ; if ( (shResult=flashGetVar( ' SH_JS_CLOSE ' ) ) ) { sh_all_anim. style .display= 'none ' ; shFinishO; } if ( (shResult=flashGetVar ( ' SH_JS_INTER' ) ) ) shReport (shResult) ; if ( (shResult=flashGetVar( ' SH_JS_FINISH' ) ) ) { shFinishO; } if ( (shResult=flashGetVar ( ' SH_JS_REPLAY ' ))) { shViewO; shReplayO; /* El cϋdigo para restartear el Shoshkele. */ } setTimeout ( "shCommand( )", 200) ; }
// This function hides objects, function shGoHide ()
{ returnOrHide ( " {HIDE_1_TAG} " , {HIDE_1_WIDTH} , {HIDE_1_HEIGHT} , {HIDE_1_IND EX}, "hidden") ; }
// This funtion unhides objects.
//
// function shFinishO
{ returnOrHide ( " {HIDE_1_TAG} " , {HIDE_1_WIDTH} , {HIDE_1_HEIGHT} , {HIDE_1_IND EX}, "visible") ; } function shPlayShoshkele ()
{ if (!window. start iew) window . setTimeout (' shView () ',100); /-jsOnloadTemp*/
// This line is included only if objects need to be hidden: shGoHide ( ) ;
// This line is included only if {LS_FLAG} is 1 shLandingSpot ( ) ;
// Otherwise, this is used: setTimeout ("sh_all_anim. style. display = 'inline'", 200); document .write (shFlashObj () + ' <SCRIPT LANGUAGE="VBScript ">Function flashGetVar (ByVal shFlashVarName) \nOn Error Resume
Next\nflashGetVar=shFrameObject .document .all . sh_all_anim.GetVariable (shFlash
VarName) \nlf flashGetVar Then shFrameObj ect . document . all . sh_all_anim. SetVariable shFlashVarName , " "\nEnd
Function<\/SCRIPT>' ) ;
// End Template 11111111111111111111111111111111111111111111111111111111111
Code Generator code *
INICIO de code_gen.asp
;html>
<head>
<script>
window.HIDE = 1 window.DOCK = 2 window.BOTH = 3
window.DOCKED = "docked"; window. FIXED = "fixed"; window. CENTERED = "center";
inicio funciones de lectura de querystring
function queryString ()
{ if ( (location. ref .indexOf ("paramsl=") != -1) && (location.href . indexOf ( "params2=" ) != -1)) { ifQueryString = true;
} else
{ ifQueryString = false;
}
if (ifQueryString)
{ var t pO = location. href . substring (location. href . indexOf ( "paramsl=" ) +8 , location. href . le ngth) ,- var args = unescape (tmpO) . split ("&") ,-
var toReturn = new Array ( ) ; for (var i=0; i<args .length; i++)
{ if( args [i] .indexOf ("= ") !=-l )
{ var tmpName = args[i] . substring (0 , args [i] . indexOf ("=")) ; var tmpVal = unescape (args [i] . substring (args [i] . indexOf ("= ") +1, args [i] .length)) toReturn [tmpName] = tmpVal;
} else
{ toReturn [args [i] ] = " " ;
var tmpO = location. href . substring (location. href . indexOf ("params2=") +8 , location. href .le ngth) ; var args = unescape (tmpO) . split ( " &" ) ,- for (var i=0; i<args . length; i++)
{ if( args[i] .indexOf ("=") !=-l )
{ var tmpName = args[i] . substring (0 , args [i] . indexOf ("=")) ; var tmpVal = unescape (args [i] . substring (args [i] . indexOf ( "= ") +l,args [i] .length) ) ,- toReturn [tmpName] = tmpVal;
else
{ toReturn [args [i] ] = "";
return toReturn;
} } // queryString ( )
function parseDockHiddingQS (str)
{ var toReturn = new Array ( ) ; var strSplited = str . split (' | ') ,-
for(var i=0; i<strSplited. length; i++)
{ var properties = strSplited [i] . split ('!' ) var tag = properties [0] . toLowerCase () ;
toReturn [i] = new Array (); toReturn [i] = properties; toReturn [i] .tag = tag; if (tag == "a" )
{ toReturn [i] . text = toReturn [i] .propl = unescape (properties [1] ) ; toReturn [i] .action = DOCK; toReturn [i] .prop2 = "null"; toReturn [i] .index = "null";
} else if (tag == "select" || tag == "input")
{ toReturn [i] .index = properties [1] ; toReturn[i] .name = toReturn[i] .propl = properties [2] ,- toReturn [i] . type = toReturn [i] .prop2 = properties [3] ; toReturn [i] .action = HIDE;
} else if (tag == "iframe" | | tag == "img" | | tag == "object")
{ toReturn [i] .index = properties [1] ,- toReturn[i] .width = toReturn[i] .propl = properties [2] ; toReturn [i] .height = toReturn [i] .prop2 = properties [3] ,- toReturn[i] .action = properties [4] ,-
/* si todavia pvHideFlag no existe */ var condicionl = ( window.pvHideFlag != true && window. vHideFlag != false );
/* (el tag es SELECT) o */
/* (el tag es INPUT) o */
/* (el objeto actual fue elegido para que se oculte) o */
/* (el objeto actual fue elegido para ocultarse y anclarse) */ var condicion2 = (tag == "select" | | tag == "input" | | toReturn [i] .action == HIDE | | toReturn [i] .action == BOTH ) ,-
if ( condicionl && condicion2) { window.pvHideFlag = true;
} } return toReturn; } // function parseDockHiddingQS (str)
fin funciones de lectura de querystring
/*
inicio funciones finales para Shoshkeles
*/
function shClose(){ shFinishO; if ( shFrameObj ect .document .all . sh_all_anim) shFrameObjec .document .all . sh_all_anim. style .display= ' none ' ; } function shReplayO { sh_all_anim. style. display = "none"; sh_all_anim.movie = "http://a619.g.akamai.net/7/619/2021/v001/ww3.shoshkeles.com/web/mmf/pagain. swf"; if (window. shGoHide) shGoHide (); if (window. landingFlag) { setTimeout ("sh_all_anim.movie = '" + theSRC + flashName + "';", 100); setTimeout ( "shLandingSpot ( ) ; " , 200) ; } else { setTimeout ( "sh_all_anim.movie = '" + theSRC + flashName + "';", 100); setTimeout ( "sh_all_anim. style .display = 'inline'", 200) ; } } function hideTags (tagName) { var shTemp = hideTags .arguments ; for (var i=0,-i<shTemp.length,-i++) { tagName = shFrameObj ect .document .all . tags (shTemp [i] ) ,- for(var ii=0; ii<tagName. length; ii++) if (tagName . item (ii) . id != "sh_all_anim" ) tagName . item(ii) . style.visibility="hidden" ; } } function showTags (tagName) {var shTemp=showTags .arguments ; for (var shAI=0 ,- shAI<shTemp . length; shAI++)
{tagName=shFrameObject .document .all . ags (shTemp [shAI] ) ;for (var shl=0 ,- shI<tagName . length; shl++) tagName . item(shl) . style. visibility="visible" ; } } function shMove (layer, left, top) {layer. style . posTop=top,- layer. style .posLeft=left ; } function shGetWindowWidthO { return shFrameObject .body. clientWidth-16 ; } function returnOrHide (tag, ropl, prop2 , index, action) { var toReturn = false; var obj Index = 0; docTags = shFrameObj ect .document .all .tags (tag) ; for (var i=0; i<docTags . length; i++) { var it = docTags . item(i) ,- if(tag=="A") { var condition = it .innerTex . indexOf (propl) != -1;
} else if (tag == "SELECT" || tag == "INPUT")
{ prop2 = prop2. toLowerCase () ,- var condition = (propl
!= null)? (it. name == propl && it. type == prop2) : (it. type == prop2 || (prop2 == "select-one" && it. type == "select-multiple") ),-
} else if (tag == "IFRAME" || tag == "IMG" ||
(tag == "OBJECT" £-& (ϋt.id || it. id != "sh_all_anim" ) ) )
{ var width = propl, height = prop2 ; if (width) var condWidth = (it. width == width || parselnt (it . offsetWidth) == width || it . style. posWidth == width); if (height) var condHeight = (it. height == height || parselnt (it .offsetHeight) == height || it . style.posHeight == height); if( (iwidth) &-- (height) ) var condition = condHeight; else if ( (iheight) && (width) ) var condition = condWidth; else if ( (iwidth) &-- (Iheight) ) var condition = true; else if ( (width) && (height) ) var condition = ( condWidth && condHeight ) ; } if ( condition && (! index || (++obj Index == index)) ) { if (action==" return" )
{ toReturn = it; break;
} . else
{ it . style .visibility = action; if (width --& height && index) break; } } var condition = false; } if (action=="return" &-- toReturn) return toReturn; } function shReturnObject (displayValue) { return ' <OBJECT ID="sh_all_anim" STYLE= "position: absolute;: top: ' +shTop+ ' x;left : ' +shLeft+ 'px; z- index:100;display: ' +displayValue+ ' ; " CLASSID="clsid:D27CDB6E-AE6D-llcf-96B8- 444553540000"
CODEBASE="http://download.macromedia.eom/pub/shockwave/cabs/flash/swflash. ca b#version=4,0,2, 0" width=" ' +flashWidth+ ' " height=" ' +flashHeight÷ ' "xparam name=menu value=falsexPARAM NAME=movie VALUE=" ' +theSRC+flashName+ '" xPARAM NAME=quality VALUE=highxPARAM NAME="L00P" VALUE="false" xPARAM NAME="wmode" VALUE="transparent" ></OBJECT>' ,- } function shRepositionWidthCenteredO { /*UV.0R*/ if (! indow. shRepositionCount) window. shRepositionCount = 1; else shRepositionCount++; if (shFrameObj ect . siteResize && shRepositionCount > 1) shFrameObj ect . siteResize ( ) ,- sh_all_anim. style. left = (shFrameObj ect .document .body .clientWidth- 16- flashWidth) /2 + shLeft; } function shRepositionAnchoredO { /*UV.OR*/ var obj = shObjeto, shY = 0, shX = 0 ; while (obj) { shY += obj .offsetTop; shX += obj .offsetLeft ; obj = obj .offsetParent; } if ( !window. shRepositionCount) window. shRepositionCount = 1; else shRepositionCount++; if (shFrameObject . siteResize && shRepositionCount > 1) shFrameObject .siteResize () ; setTimeout ( "sh_all_anim. style. top = "+ (shY + shTop) + "; sh_all_anim. style. left = " + (shX + shLeft) + ";", 100); } function overwriteEvents ( ) { function contains (str, containsStr) { var str = str + " " ; return ( str. indexOf (containsStr) != -1 )? true : false; } if ( (shFramePointer. shPosType == "center" || shFramePointer . shPosType == "docked") && ! contains (window. onresize, "UV.OR") ) { window. siteResize = onresize; shFrameObject .onresize = shFramePointer. shReposition,-
} setTimeout ("overwriteEvents () ;",200) ; } function shLandingSpot ( ) { if ( ! sh_all_anim. mode
) { setTimeout ( "shLandingSpot ( ) ; " ,
100) ,- } else { sh_all_anim. SetVariable ( ' ShkLandingMode ' , 'play' ) ; sh_all_anim. SetVariable ( ' ShkConectado' , ' 1 ' ) ; sh_all_anim. SetVariable ( ' ShkLandinglnicio ' , parselnt (iniLs) ) ,- sh_all_anim. SetVariable ( ' ShkLandingEasing ' , parselnt (eas) ) ; sh_all_anim. SetVariable ( ' ShkLandingLargo ' , parselnt (finLs) ) ,- sh_all_anim.SetVariable ( ' ShkTimeFinish' , parselnt (finish) ) ; sh_all_anim.SetVariable ( ' ShkLandingPosX ' , parselnt (posx) ) ,- sh_all_anim. SetVariable ( ' ShkLandingPosY ' , parselnt (posy) ) ; sh_all_anim.SetVariable ( ' ShkPlayAncho ' , parselnt (flashWidth) ) ; sh_all_anim. SetVariable ( ' ShkPlayAlto' , parselnt (flashHeight) ) ; sh_all_anim. SetVariable ( ' ShkRandomPing ' , url) ; setTimeout ("sh_all_anim. style. display = 'inline'", 100); } } function sh_finish(){ shFinishO;} function shFlashObj () { return ' <OBJECT
ID="sh_all_anim"
STYLE="position: absolute; top: ' +shTop+ 'px,-lef : ' +shLeft+ 'px,-z- index: 1000;display:none; " CLASSID="clsid:D27CDB6E-AE6D-llcf-96B8-
444553540000"
CODEBASE="http: //download.macromedia . com/pub/shockwave/cabs/flash/swflash. ca b#version=4 ,0,2,0" width=" ' +flashWidth+ ' " height=" ' +flashHeight+ ' " xPARAM
NAME=movie VALUE=" ' +theSRC+flashName+ ' "xPARAM NAME=quality
VALUE=highxPARAM NAME="LOOP" VALUE="false"xPARAM NAME="wmode"
VALUE="transparent"xPARAM NAME=SALIGN VALUE=TxPARAM NAME=MENU
VALUE=FALSEx/OBJECT>' ; } function shCommandO { var shResult = false; if ( (shResult=flashGetVar ( ' SH_JS_CLICK' ) ) ) { shClick ; shFinishO ; } if ( (shResult=flashGetVar ( ' SH_JS_CLOSE ' ) ) ) { sh_all_anim. style . display= ' none ' ; shFinishO ,- } if ( ( shResult=flashGetVar ( ' SH_JS_INTER' ) ) ) shReport (shResult) ; if ( (shResult=flashGetVar ( ' SH_JS_FINISH ' ) ) ) { shFinishO ; } if ( (shResult=flashGetVar ( ' SH_JS_REPLA ' ) ) ) { shView ( ) ; shReplay ( ) ;
} setTimeout ("shComman O ",200) ,- } function shCreate 0 { if (
(shFrameObject .document . readyState=="complete" ) && ! shFrameObject . shFramePointer) { shFrameObject . shFrameObject=window,- shFrameObject . shFramePointer=window,- var shScriptString = window. shReposition? 'window. siteResize=window. onresize; window. onresize = shFramePointer. shReposition; ' : ''; shScriptString
+= window. shScroll? 'window. onscroll=shFramePointer. shScroll; ' : '',- if (window. thelndex) { if (shPosType ! =
"fixed") shScriptString += overwriteEvents + OverwriteEvents 0 ; ' shFrameObject .document .body. insertAdjacentHTM ( ' afterBegin ' , shFlashObj ()+'<SPAN STYLE="display:none">OLAF<SCRIPT
DEFER> ' +shScriptString+ ' <\/SCRIPTx\/SPAN> ' ) ; } else { eval (shScriptString) ,- } window. setTimeout ( "window. sh_all_anim=shFrameObj ect .document .all . sh_al l_anim; ",100) ; window. setTimeout ( "shCommandO ,-shPlayShoshkele () ,-",500) ;
} else setTimeout (' shCreate 0 ' ,100) ,- }
fin funciones finales para Shoshkeles
/*
funciones para generar el cϋdigo.
function returnCode (arg)
{ switch (arg)
{ case "ancla":
for (var i=0; i<dockAndHideObjects . length; i++) var currentObject = dockAndHideObjects [i] ,- iff currentObject .action == DOCK || currentObject .action == BOTH ) var tmpObj ect = currentObject;
var conditionl = (typeof (tmpObj ect .propl) == "string") S &L ! (tmpObj ect . propl > 0) ,-
var condition2 = (tmpObject .propl != null) && (tmpOb ect .propl != ' ' ) ; var condition3 = (tmpObj ec .propl != "null")
var comillas = (conditionl && condition2 && condition3) ? ' " ' : ' ' ,-
return 'shObjeto = returnOrHide (" ' + tmpObject. tag. toUpperCase () + '", ' + comillas + tmpObj ect .propl + comillas + ', ' + tmpObject .prop2 + ', ' + tmpObj ect . index + ', "return" ); \n' ,-
brea ; case "shosh_inline" :
if (landingFlag)
{ return " shLandingSpot ( ) ,- \n" ;
} else
{ return "sh_all_anim. style, display = 'inline';",-
}
break;
} /* returnCodeO */ function j sMainAdd(j sCode)
{ window. j sMainTemp += "\t" + jsCode; window . j sMain = "function shMain () \n{\t" + jsMainTemp + "\n}\n";
function jsIframeMainAdd(jsCode)
{ window. j slframeMainTemp += "\t" + jsCode; window. jsIframeMain = "function shMain () \n{\n\t" + j SlframeMainTemp + "\n}\n";
}
function j sFunctionAdd (functionObj , renameFunctionTo)
{ var tmpVar = functionObj + ' ' ;
if (renameFunctionTo)
window. jsFunctions += "function " + renameFunctionTo + tmpVar. substring (tmpVar.indexOf ("(") , tmpVar . length) + "\n";
else
window. j sFunctions += tmpVar + "\n";
function j sAloneAdd(jsCode) { window.3 sAlone += jsCode;
function jsOnloadAdd(j sCode)
{ window. j sOnloadTemp += "\t" + jsCode; windo . jsOnload = "function shPlayShoshkele () \n" +
"{\n" + ( (pvPosType != DOCKED)? "\f +
VIEWCALL :
"\t" + jsOnloadTemp + "\n" + "}\n"
function gen_j sHeader ( )
window. j sHeader =
" ** [-j sHeader] **************************************************************
***** \nll .
j SHeader += "/* (" +location.href . substring (location. href .indexOf ("?") +1, location. href .length) + ") */\n";
/* encabezado con variables de Landing Spot */ if (landingFlag)
{ var j sLandingHeader = "var iniLs = " + qs . iniLs + ", eas = " + qs.eas + ", finLs = " + qs.finLs + ", finish = " + qs. finish + ", posx = " + qs.posx + ", posy = " + qs.posy + ", url = '" + qs.url + "τ;\n";
j sHeader += "var flashwidth=" + pvFlashWidth + " , lashHeight=" + pvFlashHeight + ",shTop=" + pvTop + ",shLeft=" + pvLeft + " , flashName= ' " + pvFlashFile + "', landingFlag = " + landingFlag + ";\n"; if (landingFlag) jsHeader += j sLandingHeader,-
/* si es anchored */ if(pvPosType == DOCKED) jsHeader += "var shObjeto=false; \n" ;
jsHeader -r= "var shPosType = '" + pvPosType + "';\n\n", window. jsHeader += π/**************************************************************************
*****/\n" •
} /* function gen_j sHeader () */
function gen_dockAndHide 0
{
// OCULTAR //////////////////////////////////// if (window.pvHideFlag)
{ window. j sHide = ' \n ' ; window, j sShow = '\n',-
if (pvPosType == DOCKED)
{ returnOrHide_flag = true;
} else
{
// el primer ciclo se utiliza solo para saber si alguna vez fue especificado un objeto
// con las propiedades width, height, o index, segun los resultados de esta busqueda
// el prOximo ciclo crear- el string con el codigo llamando a returnOrHide o hideTags & showTags for(var i=0; i<dockAndHideObjects . length; i++)
{ var valores = dockAndHideObj ects [i] ,-
if ( ! returnOrHide_f lag && ( (valores [1] && valores [l] ! = 0 ) | | valores [2] | | valores [3 ] ) )
{ returnOrHide_flag = true; break; } } forfvar i=0; i<dockAndHideObjects .length; i++)
{ var valores = dockAndHideObjects [i] ,-
if ( valores. action == HIDE || valores . action == BOTH
{ if ( returnOrHide_flag )
var comillasl = ( (typeof (valores. propl)==" string") && ! (valores .propl > 0) && (-(valores .propl != null) && valores. propl != '') && valores .propl != "null" )? '"' : '',- var comillas2 = ( (typeof (valores .prop2) ==" string" ) && ! (valores .prop2 > 0) && ( (valores .prop2 != null) && valores. prop2 != '') && valores .prop2 != "null" )? '"' : '',-
if (valores .propl == "") valores .propl = null ; if (valores.prop2 == "") valores .prop2 = null;
jsHide += ' \treturnOrHide ( " ' + valores . tag. toUpperCase () + '",' + comillasl + valores .propl + comillasl + ',' + comillas2 + valores .prop2 + comillas2 + ',' + valores . index + ' , "hidden") ;\n' ; jsShow += ' \treturnOrHide(" ' + valores .tag. toUpperCase () + '",' + comillasl + valores .propl + comillasl + ',' + comillas2 + valores .prop2 + comillas2 + ',' + valores . index + ' , "visible" ) ; \n' ,-
} else
{ jsHide += ' \thideTags ( " ' + valores. tag +
;\n' jsShow += ' \tshowTags (" ' + valores. tag
") ;\n'; window. shGoHide = "function shGoHide 0 { " + jsHide + " }",- jsHide = "ShGoHide () ;\n";
window.shFinish = "function shFinishO \n{ " + jsShow + "}\n";
} else
{ window. shFinish = "function shFinish 0 {}" ,-
// fin OCULTAR ////////////////////////////////
}
function gen_j sFunctions ( )
{ *********************
Figure imgf000110_0001
jsFunctionAdd(shCommand) ; j sFunctionAdd ( shFlashObj ) ; jsFunctionAddl shClose) ,- j sFunctionAdd (shReplay) ;
/* LANDING SPOT */ if (landingFlag) j sFunctionAdd (shLandingSpot) ;
if (pvPosType == CENTERED | | pvPosType == DOCKED) j sFunctionAdd(overwriteEvents) ;
/* reposition */ if (pvPosType == CENTERED)
{
3 sFunctionAdd (shRepositionWidthCentered, "shReposition") ,- else if (pvPosType == DOCKED)
{ sFunctionAdd(shRepositionAnchored, "shReposition") ; j sFunctionAdd (returnOrHide) ,- }
if ( window.pvHideFlag && returnOrHιde_flag )
{ if (pvPosType != DOCKED) sFunctionAdd(returnOrHide) ;
} else
{ sFunctionAdd(showTags) , sFunctionAdd(hideTags) , }
if ( window.pvHideFlag )
{ sFunctionAdd(shGoHide) ;
}
3 sFunctionAdd(sh_fmιsh) ,- 3 sFunctionAdd(shFinish) ,
window 3 sFunctions +=
* * j/\n" ,
} /* function gen_3 sFunctions 0 */
window onload = function genJS 0 { window.VIEWCALL = "window. setTimeout ( ' shView ( ) ' , 100 ) ; " ;
/* guardo el querystring que contiene la configuracion */ window.qs = queryString () ,-
/* qsDockHidding es un string que contiene la informacion */
/* acerca de los objetos que se deben ocultar y/o anclar */
/* el formato del string es el siguiente: */
/* TAGlpropiedadl !propiedad2 !propiedad3 *
/* A: tag!texto_del_link *
*/
/* SELECT o INPUT: tag ! index! name ! type ! action */
/* IFRAME, IMG, FLASH: tag ! index!width Iheight ! action */
window. dockAndHideObjects = parseDockHiddingQS (qs .dockHidding) ;
var tmpFlashFile = unescape (qs . shLocation) ; window. pvFlashFile = tmpFlashFile . substring (tmpFlashFile . lastIndexOf ( "/" ) +1, tmpFlashFile . length) ; window. vFlashWidth = qs. shWidth; window.pvFlashHeight = qs . shHeight ; window.pvPosType = qs.posType,- window.pvLeft = qs.left; window. vTop = qs.top; window. vTipo = qs.pvTipo;
if (qs.LS)
{ window. landingFlag = true;
} else
{ ill
window landingFlag = false, }
********************************************************** /* partes del timeline ************************************/ /**********************************************************/
window 3sOnloadTemp = ' //j sOnloadTemp\n' , window 3sOnload = ' //3Sθnload\n' , window sAlone = ' //3sAlone\n' , window 3sMam = '//]sMam\n', window 3sMamTemp = l//]sMaιnTemp\nl ,
window returnOrHιde_flag = false, window pvlframe = false, window pvBackupFunctionsFlag = false,
/********************************************************************* ************************
/* 3 sHeader **************************************************************************** ****** ********************************************************************* ************************
gen_3 sHeader ( ) ,
-^**-' -' *^ -) **ι Λ-' -' - -, J--' -' i j
*-- * 1- * **-' -'.*-'--' * * * •• -1- * * * * -> ****^*****κ*J •'-' * * * *J--^***J-y **j * * * * * j * * ********
*** **/
/********************** ********************* ************************ ************************
gen_dockAndHide ( ) , /********* ******* *** ********************** ****** * *** * ** * * ***** * * * * **** ** * * * ** ****** ** ***** * * **
/* j sFunctions **************************************************************************** ***
/********************************************************************* ************************
gen_j sFunctions ( ) ;
/********************************************************************* ************************/
/* jsAlone **************************************************************************** ******* ********************************************************************* ************************
jsAloneAdd( ' document .write (shFlashObj () +\'<SCRIPT LANGUAGE= "VBScript ">Function flashGetVar (ByVal shFlashVarName) \\nOn Error Resume
Next\\nflashGetVar=shFrameObj ect .document .all . sh_all_anim.GetVariable (shFlas hVarName) \\nlf flashGetVar Then shFrameObject .document .all . sh_all_anim. SetVariable ShFlashVarName, ""\\nEnd Function<\\/SCRIPT>\' ) ;\n\n' + shCreate);
// ONLOAD /////////////////////////////////////
if (pvPosType == DOCKED)
{ var shAnchoredObject = returnCode ( "ancla" ) ; var shFlagTmp = "if (shObjeto) \n" +
//"\t {\n\t\tshReposition ( ) ; \noverwriteEvents ( ) \n" +
"\t{\n\t\tshReposition() ;\n" + "\t\t" + VIEWCALL + "\n";
jsOnloadAdd( shAnchoredObject) ,- jsOnloadAdd( shFlagTmp) ,- } else if (pvPosType == CENTERED)
{ j sOnloadAdd( "shReposition() ;\n") ;
}
if (window.pvHideFlag) jsOnloadAdd(jsHide + "\n"); sOnloadAdd (returnCode ( "shosh_inline" ) ) ;
if (pvPosType == DOCKED) jsOnloadAdd("}\n")
mostrarCodigo (jsHeader + jsFunctions + jsOnload + jsAlone);
}
function mostrarCodigo (timelineCode)
{ document . forms [0] . textareal .value = timelineCode;
if (parent !=top) parent .saveJS (timelineCode) ;
</script> </head> <body>
<form>
■-centerxtextarea name="textareal" id="laData" style="width: 850px; height : 500px; font:normal llpx Courier New; background: #E8E8E8; "></textareax/center>
</form>
</body>
</html> FIN de code_gen.asp
**************************************************************************** ********************
**************************************************************************** ********************
**************************************************************************** ********************
**************************************************************************** ********************
1.2 form.html (recibe el codigo fuente generado y se lo envia al servidor)
INICIO de form.html
<html>
<body onload="parent . formOnload ( ) ">
<form method= "post " action= "db_traf f ic . asp" > <textarea name= "TML_JS " x/textarea> <textarea name= "TML_IF" x/textarea> </f orm> </body> </html>
FIN de form.html **************************************************************************** ********************
**************************************************************************** ********************
**************************************************************************** ********************
**************************************************************************** ********************
2 . control . asp :
INICIO de control. sp
var theSRC = "http://www.shoshkelizer.com/traffic/",
function uvAlert (txt) { alert (txt); }
documen .write ( ' <object style="position: absolute; display : none; " CLASSID="clsid:D27CDB6E-AE6D-llcf-96B8-444553540000"
C0DEBASE="http: //download.macromedia . com/pub/shockwave/cabs/flash/swflash. ca b#version=4, 0,2,0"xPARAM NAME=movie VALUE=" ' + theSRC + 'img/myflash. swf" xPARAM NAME=quality VALUE=highxPARAM NAME="L00P" VALUE="false"xPARAM NAME="wmode" VALUE="transparent"></0BJECT> ' ) ;
ONLOAD Esta funcion es recursiva y se ejecuta hasta que el toolbar termina de cargar, en ese momento habilita los eventos y prepara a los Iframes y Objects, a los que les cambia el SRC por uno local, y que de esa forma podamos tener control total en ellos.
function preStart 0 {
si la pagina termino de cargar, continuo
*/ if (document .readyState == "complete")
{ /*
REEMPLAZO DE IFRAMES Y OBJECTS
*/
window.OB ECT_COUNT = 0; for(i=0; i<document .all .tags ("OBJECT") .length; i++) if (document. all. tags ("OBJECT") .item(ι) .id != "sh_all_anim_shoshkelizer" && document .all .tags ("OBJECT") . item(i) . style .position != "absolute"
OBJECT COUNT++;
for(i=0; i<document. all. tags ("OBJECT") .length; i++) if (document. all. tags ("OBJECT") .item(i) .id != "sh_all_anim_shoshkelizer" --& document .all. ags ("OBJECT") .item(i) .style.position != "absolute" ) {
preChangeSrcFlash (document. all. tags ("OBJECT") .ιtem(ι) ) ; window.OBJECT_COUNT-- ; }
for(ι=0; Kdocument.all. tags ("IFRAME") .length; ι++) if (document .all. tags ("IFRAME") .item(ι) .name ' = "theToolBar") document .all .tags ("IFRAME") .ιtem(ι) .src = theSRC + "tb_mysrc.html?" + i,
Inhabilito los image MAP
for(ι=0; Kdocumen .all. tags ( "MAP" ) .length; ι++) document .all .tags ( "MAP") ιtem( ) .areas . length = 0;
se micia el proceso en el que se verifica si alguien selecciono un ob3eto flash
X window setTimeout ( "checkClickAndOverOnFlashO ",500)
document . onmouseover = fllterLocateAndSendlnfo; document .oncl ck = fιlterAdOb3Manager,
window CONTROL_LOADED = true;
} else lf ( !TOOLBARLOADED) { setTimeout ("preStart 0 ",500) ;
} } /* function preStart 0 */
begin OBJECT HIDDING & DOCKING
Esta funcion le cambia el SRC a los OBJECT que se le pasen como parametro por el flash que controlamos .
*/ function preChangeSrcFlash (tmpFlashObj ) I if (tmpFlashObj != null)
{ tmpFlashObj .style.backgroundColor = "#AAAAAA"; newObjectSrc = theSRC + "img/myflash. swf" ;
objectSourceCode = tmpFlashObj .outerHTML;
objectSourceCode = objectSourceCode. toLowerCase () ;
srcPosition = objectSourceCode . indexOf (' "src" ') ;
moviePosition = obj ectSourceCode . indexOf ( ' "movie" ' ) ,- codeEnd = objectSourceCode. substring (srcPosition + objectSourceCode. length) ;
paramPosition = codeEnd. indexOf ( "param" ) ,-
wmodePosition = codeEnd. indexOf ( "wmode" ) ,-
playPosition = codeEnd. indexOf ( 'param name="play' ) ,-
newFlashCode = objectSourceCode . substring (0 , moviePosition +
15 ) newObjectSrc +
objectSourceCode . substring (srcPosition - 14, srcPosition + 6) +
' value=" ' + newObjectSrc + '"' +
codeEnd. substring (paramPosition - 1, playPosition - 1) +
"<PARAM NAME=\"wmode\" VALUE=\"transparent\">" + codeEnd. substring (playPosition - 1, codeEnd. length) ,- /*#FF9933 */
tmpFlashObj .outerHTML = newFlashCode;
} } /* preChangeSrcFlash (tmpFlashObj ) */
FLASH: ONMOUSEOVER & ONCLICK
esta funcion pregunta constantemente si algun objeto Flash fue presionado hace un for cada segundo por todos los OBJECT para ver si a alguno se le seteo la variable presionado esa veriable se setea internamente en el flash cuando se clickea dentro de el.
*/ function checkClickAndOverOnFlash () { if (OBJECT_COUNT == 0 && TOOLBARLOADED) { for(var i = 0; i < document .all . tags ( "OBJECT" ). length; i++)
{ if (document. all. tags ("OBJECT") .item(i) .id != "sh_all_anim_shoshkelizer" && document .all. ags ("OBJECT") .item(i) . style .position != "absolute")
{ var pressed = document .all. tags ("OBJECT") .item(i) .GetVariable ( "presionado" ) ,- var overed = document, all. tags ("OBJECT") .item(i) .GetVariable ( "over" ) ,- if (pressed == 1) { declareObjectTo (i, 'capture') ,- pressed = 0 ; overed = 0; } if (overed == 1) declareObjectTo (i, 'send') ; overed = 0 ; }
} } window. setTimeout ( "checkClickAndOverOnFlash () " , 1000) /* CheckClickAndOverOnFlash () */
Esta funcion recibe el OBJECT que fue clickeado y la accion a realizar.
Si debe llama a la funcion pertinente para realizar la accion que haga f lta.
*/ function declareObjectTo (ob ectltem, toDo, manualAction) {
SELECTEDOBJECT = document .all .tags ("OBJECT" ) . item(parselnt (objectltem) ) ; objWidth = SELECTEDOBJECT. offsetWidth; objHeight = SELECTEDOBJECT. offsetHeight ;
/* esto indica que la solapa de [object hidding] o la de [docking] se encuentra visible o que */ /* un objeto fue agregado (restore) */ if (manualAction ==
"hide" I I manualAction == "dock" | | window. SELECTFOR == "hide" | | window. SELECTFOR == "dock") {
/* dependiendo de cu-1 sea la acciύh. onmouseover->send, onclick->caρture */ if(toDo == "send")
{ sendObjectlnfo (objectltem, objWidth, objHeight);
} else if(toDo == "capture")
{ addObj ectToArray (obj ectltem, objWidth, objHeight, manualAction) ;
} } }
/* declareObj ectTo (objectltem, toDo, manualAction) */ esta funcion se encarga de mandar la informacion del OBJECT sobre el que se paso el mouse a TOOLBAR
*/ function sendObjectlnfo (objectltem, objWidth, objHeight) {
/* recibo la informacion de quE Item es en la colecciϋn de OBJECTS */ /* de la pagina, en esta linea asigno a selectedObject el objeto que me llamo, gracias <-- (?) */
SELECTEDOBJECT = ' document. all .tags ("OBJECT") . item (parseln (objectltem) ) ; if ( lchecklnputs ) return false,- /* borro el contenido de los inputs. */ clearlnputs () ,- /* empieza el paso de las variables del IFRAME al formulario */ /* Si el User esta ANCLANDO (SELECTFOR, contiene la accion y es variado desde el toolbar cuando */ /* presionan los botones) */ if (window.SELECTFOR == "dock")
{
PVFORM. tagDock.options [ formGetSelectlndexByValue ("tagDock" , "OBJECT") ] .selected = true; SELECTEDOBJECT. theWidth = objWidth; SELECTEDOB ECT. theHeight = objHeight; setValue ( "widthDock" , objWidth) ; setValue ("heightDock" , objHeight) ,- setValue ("anchindex", returnObjectPropertiesIndex(SELECTEDOBJECT) ) ;
TOOLBAR. changeAnchTable () ,- }
/* Si el User esta OCULTANDO (SELECTFOR, contiene la accion y es variado desde el toolbar cuando */
/* presionan los botones) */ else if (window. SELECTFOR=="hide") {
PVFORM. tagHide. options [3] . selected = true,- SELECTEDOBJECT . theWidth = objWidth; SELECTEDOBJEC . theHeight = objHeight; setValue ( "widthDock" , objWidth) ; setValue ( "heightDock" , objHeight) ; setValue ("hidelndex" , returnObjectPropertiesIndex(SELECTEDOBJECT) ) ;
TOOLBAR. changeHideTable ( ) ; }
/* termina el paso de variables del IFRAME al formulario */ } /* function sendObjectlnfo (objectltem, objWidth, objHeight) */
/*
Esta funcion se encarga de cambiar el color del OBJECT y de agregarlo al "array global de objetos seleccionados"
Cuando se cambia el color de un OBJECT forzosamente se genera un objeto nuevo, asi que cuando se selecciona un
OBJECT se genera en un array paralelo a lista, que se llama objetos [] una referenda directa al nuevo objeto. */ function addObjectToArray (obj ectltem, objWidth, objHeight, manualAction)
{ var hideSeleσt =
PVFORM . theHiddenObj ; /*
Estas variables son flasgs para saber si el OBJECT que se clickeo hay que agregarlo al Array global lista [] */ var addToHideList = false; var addToDockList = false,-
/* esta variable es un flag para saber si hay un item para borrar */ var deleteltem = false; tmpObject
= document, all. tags ("OBJECT") . item (parselnt (obj ectltem) ) ,- tmpObject . item = objectltem; tmpObject .theWidth = objWidth; tmpObject . theHeight = objHeight; tmpObject .hide = (tmpObject .hide == true || tmpObject .hide == "true")? true : false; tmpObj ect . dock = (tmpObject .dock == true || tmpObj ect . dock == "true")? true : false; tmpObject . selected = (tmpObject . selected == true || tmpObject == "true")? true : false; *********************************************************************
LASTPOSITION = lista . length;
/* si el objeto que se selecciono ya habia sido selecoionado se usa la misma casilla en la lista global */ for(i=0; i<= (lista. length-1) ,- i++) { if ( (lista [i] .item == tmpObject . item) && (lista [i] . tagName == tmpObject . tagName) ) { tmpObject = lista [i]; LASTPOSITION = i; }
} /* si el objeto no est- oculto, y fue selecoionado para ocultarse. */ if ( tmpObject. hide == false && (manualAction == "hide" | | window . SELECTFOR == "hide") ) { var isNone
= (returnObjectStatus (tmpObject) == "none"); tmpObject . src = theSRC + (isNone)? "rojo.swf" : "verde . swf" ; tmpObject .hide = true; tmpObject . selected = (isNone)? false : true; tmpObject. style. backgroundColor = (isNone)? ROJO : VERDE; addToHideList = true; lista [LASTPOSITION] = tmpObject; var theSelectText = tmpObj ect . tagName + " item(" + (tmpObject . item + 1) + ")";
/*Agrega el text y el value al option de Hidding. */ if (hideSelect .options [0] .text == "None selected")
{ hideSelect . length = 0 ; var cant = 0 ; } else
{ var cant = hideSelec . length;
} var selectlndex = cant + 1; unaOpcion = TOOLBAR, document . createElement ( "OPTION" ) ,- unaOpcion.value = LASTPOSITION; unaOpcion. text = theSelectText ,- PVFORM. heHiddenObj .options .add (unaOpcion) ; PVFORM. theHiddenObj .options [cant] . selected = true,- } else if ( tmpObj ect . dock == false &&
(manualAction == "dock" | | window . SELECTFOR == "dock") )
{ for(i=0; i<lista. length; i++)
{ if (lista [i] .dock == true) {
ITEMTODELETE = i; deleteltem = true; } } var isNone = (returnObjectStatus (tmpObject) == "none"); tmpObject . src = theSRC + (isNone)? "img/azul. swf" : "img/verde . swf" ,- tmpObject .dock = true; tmpObject . selected = (isNone)? false : true; tmpObject. style.backgroundColor = (isNone)? AZUL : VERDE; addToDockList = true; lista [LASTPOSITION] = tmpObject; var theSelectText = tmpObject .tagName + " item(" + tmpObject . item + " ) " ; setValue ("elanclado" , theSelectText) ; setValue ("elancladoq", LASTPOSITION) ; if (deleteltem) { deleteDock(ITEMTODELETE) ;
} TOOLBAR. SetUpAl1Pos () ; }
} /* function addObjectToArray (objectltem, objWidth, objHeight) */
IFRAME: ONMOUSEOVER & ONCLICK
function iframeOver (itemPos) { if (TOOLBARLOADED) { var tmplframeWidth = document. all. tags ( 'IFRAME' ) . item(parselnt (itemPos) ) .offsetWidth; var tmplframeHeight = document .all .tags ( ' IFRAME' ) . item(parselnt (itemPos) ) .offsetHeight; sendlframelnfo (itemPos, tmplframeWidth, tmplframeHeight) ;
} } /* function iframeOver (itemPos) */ function iframeClicked(itemPos, manualAction) { var tmplframeWidth = document .all .tags ( ' IFRAME' ) . item(parselnt (itemPos) ) .offsetWidth; var tmplframeHeight = document .all .tags ( ' IFRAME' ) . item (parselnt (itemPos) ) .offsetHeight ,- addlframeToArray (itemPos, tmplframeWidth, tmplframeHeight , manualAction); } /* function iframeClicked(itemPos, manualAction) */ function sendlf amelnfo (itemPos , iframeWidth, iframeHeight) {
SELECTEDOBJECT = document .all .tags ("IFRAME" ) . item(parselnt (itemPos) ) ; checklnputs ( ) ; /* Limpieza de residuos */ clearlnputs ( ) ;
/* Si el User esta ANCLANDO (SELECTFOR, contiene la accion y es variado desde el toolbar cuando presionan los botones) */ if (window.SELECTFOR == "dock")
{ PVFORM. tagDock. options [2] . selected = true; SELECTEDOBJECT . theWidth = SELECTEDOBJECT . offsetWidth;
SELECTEDOBJECT. theHeight = SELECTEDOBJECT. offsetHeight; setValue ( "widthDock" , SELECTEDOBJECT. theWidth) ; setValue ( "heightDock" , SELECTEDOBJECT. theHeight) ,- setValue ( "anchindex" , returnObjectPropertiesIndex(SELECTEDOBJECT) ) ;
TOOLBAR. changeAnchTable () ; }
/* Si el User esta OCULTANDO (SELECTFOR, contiene la accion y es variado desde el toolbar cuando presionan los botones) */ else if (window. SELECTFOR ==
"hide") {
PVFORM. tagHide. options [2] .selected = true; SELECTEDOBJECT . theWidth = SELECTEDOBJECT. offsetWidth; SELECTEDOBJECT. theHeight = SELECTEDOBJEC .offsetHeight ; setValue ("widthHide", SELECTEDOBJECT.theWidth) ; setValue ( "heightHide" , SELECTEDOBJECT . theHeight) ; setValue ("hidelndex" , , returnObjectPropertiesIndex(SELECTEDOBJECT) ) ; TOOLBAR. changeHideTable ( ) ;
} /* termina el paso de variables del IFRAME al formulario */ }
/* sendlframelnfo(itemPos, ifra eWidth, iframeHeight) */ function addlframeToArray ( itemPos, tmplframeWidth, tmplframeHeight , manualAction) { /* Estas variables son flags para saber si el IFRAME que se clickeo hay que agregarlo al Array global lista [] */ var addToHideList = false; var addToDockList = false,-
/* Esta variable es un flag para saber si hay un item para borrar */ var deleteltem = false;
SELECTEDOBJECT = document .all. tags ("IFRAME" ) . item(parselnt (itemPos) ) ; SELECTEDOBJECT . item = itemPos; SELECTEDOBJECT. theWidth = tmplframeWidth; SELECTEDOBJECT. theHeight = tmplframeHeight ; LASTPOSITION = lista.length;
/* busco si el objeto ya se encuentra en la lista. */ for(i=0; i<= (lista. length - 1); i++) { /* si lo encuentro, entonces no tengo que volver a ingresarlo en la lista. */ if( (lista [i] .item == SELECTEDOBJECT. item) && (lista [i] .tagName == SELECTEDOBJECT. tagName) ) {
SELECTEDOBJECT = lista [i] ; LASTPOSITION = i; }
} if (manualAction
== "hide" I I window. SELECTFOR == "hide") { if (returnObjectStatus () == "none")
{ SELECTEDOBJEC . src = theSRC + "tb_rojo.html?" + itemPos ;
SELECTEDOBJECT.hide = true; addToHideList = true; } else if (returnObjectStatus () == "dock") {
SELECTEDOBJECT. src = theSRC÷"tb_verde.html?" + itemPos; SELECTEDOBJECT.hide = true; SELECTEDOBJECT. selected = true; addToHideList = true; } if (addToHideList)
{ lista [LASTPOSITION] = SELECTEDOBJECT; var theSelectText = SELECTEDOBJECT. tagName + " item(" + SELECTEDOBJECT . item + " ) " ; if (PVFORM. theHiddenObj .options [0] .text == "None selected")
{ PVFORM. theHiddenObj .length = 0 ; var cant = 0 ,- } else { var cant = PVFORM. theHiddenObj . length; . } /*Agrega el text y el value al option de Hiding. */ unaOpcion
= TOOLBAR. document. createElement ("OPTION") ; unaOpcion.value = LASTPOSITION; unaOpcion . text = theSelectText; PVFORM. theHiddenObj . options . add(unaOpcion) ,-
PVFORM. theHiddenObj .options [cant] .selected = true; } } else if (manualAction == "dock" || window. SELECTFOR == "dock") { t for(i=0; i<lista. length; i++) { if (lista [i] .dock == true) { ITEMTODELETE = i ; deleteltem = true;
} } if (returnObjectStatus () == "none")
{ SELECTEDOB ECT . src = theSRC+"tb_azul .html?" + itemPos; SELECTEDOBJECT. ock = true; addToDockList = true; } else if (returnObjectStatus 0 == "hide")
{ SELECTEDOBJECT. src = theSRC+"tb_verde .html? " + itemPos;
SELECTEDOBJECT . dock = true; SELECTEDOBJECT. selected = true; addToDockList = true; } if (addToDockList)
{ lista [LASTPOSITION] = SELECTEDOBJECT; var theSelectText = SELECTEDOBJECT . tagName + " item(" + SELECTEDOBJECT . item + " ) " ; setValue ( "elancladoq" , LASTPOSITION) ; setValue ("elanclado", theSelectText) ; if (deleteltem)
{ deleteDoc (ITEMTODELETE) ; }
TOOLBAR. setUpAllPos ( ) ; } } } /* function addlframeToArray (itemPos, tmplframeWidth, tmplframeHeight) */
ONMOUSEOVER (excepto iframes y objects)
*/
function fHterLocateAndSendlnfo 0 { if ( iTOOLBARLOADED) return; var conditionl = (event . srcElement .id != "laBarra"); var condition2 = (event . srcElement . id != "sh_all_anim_shoshkelizer" ) ; var condition3 = (event . srcElement .name != "theToolBar"); var condition4 = (event .srcElement .id = "maskFlaglmg" ) ; var conditions = (event . srcElement .id = "maskFlagLayer" ) ; var conditionδ = (event . srcElement . id = "resize_button" ) ,- var condition? = (event . srcElement . id = "laBarra_resize_img" ) ,- if (conditionl && condition2 && conditions && condition4 && conditions && condition6 && condition?) {
SELECTEDOBJECT = event . srcElement ; objectDeleteEvents (SELECTEDOBJECT) ; locateAndSendlnfo ( ) ; if (SELECTEDOBJECT . type) { var formElementTag = SELECTEDOBJECT. type . toUpperCase ( ) ; var formElementNewIndex = getSelectedlndexByValue (PVFORM. formElementTag, formElementTag) ;
PVFORM. ormElementTag. selectedlndex = formElementNewIndex;
} } return false;
} /* function filterLocateAndSendlnfo 0 */ function objectDeleteEvents (daObject) { daObject .onmouseover = null; daObject .onclick = null; daObject .onmouseout = null; daObject .ondblclick = null; daObject . onchange = null; } /* function objectDeleteEvents (daObject) */ function locateAndSendlnfo 0 { SELECTEDOBJECT = identifyObject () ,- if ( lchecklnputs ) return false; clearlnputs () ,- if (window. SELECTFOR == "dock") { if (SELECTEDOBJECT. tagName == "IMG") { PVFORM. tagDock. options [0] .selected = true; SELECTEDOBJECT. theWidth =
SELECTEDOB ECT . idth;
SELECTEDOBJECT. theHeight = SELECTEDOBJECT. height; setValue ( "widthDock" , SELECTEDOBJECT . theWidth) ,- setValue ( "heightDock" , SELECTEDOBJECT. theHeight) ; setValue ( "anchindex" , returnObjectPropertiesIndex (SELECTEDOBJECT) ) ;
ObjectDeleteEvents (SELECTEDOBJECT) ;
TOOLBAR. changeAnchTable 0 ; } else if (SELECTEDOBJECT. tagName == "A") { PVFORM. tagDock. options [1] . selected = true; SELECTEDOBJECT . text =
SELECTEDOBJECT. innerText; setValue ( "textA" , SELECTEDOBJEC . innerText) ,- objectDeleteEvents (SELECTEDOBJECT) ; TOOLBAR. changeAnchTable () ,- } } else if (window. SELECTFOR ==
"hide") { if (SELECTEDOBJECT. tagName == "INPUT" || SELECTEDOBJEC . tagName == "SELECT") {
PVFORM. tagHide. options [0] .selected = true;
SELECTEDOBJECT. obj ame = SELECTEDOBJECT .name; PVFORM. tagNameElemForm. alue = SELECTEDOB ECT. objName; setValue ( "tagNameElemForm" , SELECTEDOBJECT. objName) ;
TOOLBAR. changeHideTable ( ) ; objectDeleteEvents (SELECTEDOBJECT) ; var formElementTag = ( (SELECTEDOBJECT. tagName == "SELECT")? "SELECT" : SELECTEDOBJECT . type . toUpperCase () ) ; var formElementNewIndex = getSelectedlndexByValue (PVFORM. formElementTag, formElementTag) ;
PVFORM. formElementTag . selectedlndex = formElementNewIndex; } else if (SELECTEDOBJECT. tagName == "IMG") {
PVFORM. tagHide.options [1] .selected = true; SELECTEDOBJECT . theWidth = SELECTEDOBJECT.width;
SELECTEDOBJECT. theHeight = SELECTEDOBJECT. height ; setValue ( "widthHide" , SELECTEDOBJECT . theWidth) ,- setValue ( "heightHide" ,
SELECTEDOBJECT. theHeight) ; setValue ( "hidelndex" , returnObjectPropertiesInde (SELECTEDOBJECT) ) ; objectDeleteEvents (SELECTEDOBJECT) ; TOOLBAR. changeHideTable () ; }
} /* termina el paso de variable al formulario */ } /* locateAndSendlnfo ( ) */
/*
ONCLICK
function filterAdObjManager () { if ( iTOOLBARLOADED) return; var conditionl = (event . srcElement . id != "laBarra"); var condition2 = (event . srcElement . id != "sh_all_anim_shoshkelizer" ) ,- var condition3 = (event . srcElement .name != "theToolBar"); var condition4 = (event . srcElement . id != "maskFlaglmg" ) ; var conditions = (event .srcElement . id != "maskFlagLayer" ) ; var conditionδ = (event . srcElement . id != "resize_button") ,- var condition? = (event . srcElement . id != "laBarra_resize_img" ) ,- if (conditionl && condition2 && condition3 && condition4 && conditions && condition6 && condition?) var itsOK = true; if( itsOK && (window. SELECTFOR == "dock" | window. SELECTFOR == "hide") ) {
SELECTEDOBJECT = identifyObject () ,- adObjManager () ,- " } return false;
} /* filterAdObjManager () */ function identifyObject 0 { originaltmpObj = event . srcElement ; tmpObj = originaltmpObj ; while (tmpObj )
{ if (tmpObj .tagName == "APPLET" || tmpObj . tagName == "IMG" || tmpObj . tagName == "A" || tmpObj . tagName == "INPUT" || tmpObj .tagName == "SELECT") { parentElementRemoveEvent (tmpObj ) ; return tmpObj ;
} tmpObj = tmpObj .parentElement; } return originaltmpObj ; } /* identifyObject () */ function parentElementRemoveEvent (originalObject) { var bigTags = {BODY:l, HEAD:1, HTML:l},- if ( originalObject .parentElement && !bigTags [ originalObject .parentElement . tagName ] ) { objectDeleteEvents (originalObj ect .parentElement) ; } else { return; } } /*/ function parentElementRemoveEvent (originalObject) */ function adObjManager (objec , theAction) { if i
SELECTEDOBJECT && (SELECTEDOBJECT . id == "sh_all_anim_shoshkelizer" | | SELECTEDOBJECT. id == "laBarra") ) return false; if (object) SELECTEDOBJECT = object; if (! theAction) var theAction = ''; EXISTE = false; for(i=0; i<document. all. tags (SELECTEDOBJECT. tagName) .length; i++) { if ( document. all. tags (SELECTEDOBJECT. tagName) .item(i) == SELECTEDOBJECT ) { SELECTEDOBJECT. item = i; } } if (SELECTEDOBJECT.hide != true) SELECTEDOBJECT.hide = false; if (SELECTEDOBJECT. dock != true) SELECTEDOBJECT . dock = false; if (SELECTEDOBJECT. selected != true) SELECTEDOBJECT. selected = false; if (theAction ==
"dock" || window. SELECTFOR == "dock") { findAndMarkDockO ; } else if (theAction == "hide" || window. SELECTFOR == "hide") { if ( ! SELECTEDOBJECT .hide) findAndMarkHide ( ) ; } } /* function adObjManager (object , theAction) */
DOCKING
function findAndMarkDockO { var LASTPOSITION
= lista. length; for(i=0; i<= (lista . length-1) ; i++) { if ( (lista[i] .item ==
SELECTEDOBJECT . item) && (lista [i] . tagName == SELECTEDOBJECT. tagName) )
{ SELECTEDOBJECT = lista [i]; /*Si el objeto que se selecciono ya habia sido selecoionado se usa la misma casilla en la lista global */
LASTPOSITION = i; }
} /* Esta variable es un flag para saber si hay un item para borrar */ var deleteltem = false; if (SELECTEDOBJECT. agName == "IMG"
I I SELECTEDOBJECT . tagName == "A") { if ( SELECTEDOBJECT . tagName != "BODY" && EXISTE == false)
{ for(i=0; i<lista. length; i++)
{ if (lista [i] .dock == true) {
ITEMTODELETE = i; deleteltem = true;
} }
/* le coloca color */ if (SELECTEDOBJECT. tagName == "IMG") { if (returnObjectStatus ( ) == "none")
{
SELECTEDOBJECT . oldSrc = SELECTEDOBJECT. src;
SELECTEDOBJECT. src = theSRC + "img/azul .gif " ; SELECTEDOBJECT . dock = true; SELECTEDOBJECT.width = SELECTEDOBJECT . theWidth;
SELECTEDOBJECT. height = SELECTEDOBJECT. theHeight ;
} else if (returnObj ectStatusO == "hide")
{ SELECTEDOBJECT. src = theSRC + "img/verde .gif" ; SELECTEDOBJECT . dock = true; SELECTEDOBJECT. selected = true;
} } else {
SELECTEDOBJECT. oldStyle = SELECTEDOBJECT. style .backgroundColor; if (returnObjectStatus () == "none")
{ SELECTEDOBJECT. style.backgroundColor = AZUL; SELECTEDOBJECT. ock = true; SELECTEDOBJECT. selected = true;
} } lista [LASTPOSITION] = SELECTEDOBJECT; var theSelectText = SELECTEDOBJECT. tagName + " item(" + SELECTEDOBJECT. item + ")";
PVFORM. elancladoq.value = LASTPOSITION; PVFORM. elanclado.value = theSelectText; if (deleteltem)
{ deleteDock (ITEMTODELETE) ; }
TOOLBAR. setUpAllPos 0 ; }
} else - { if (SELECTEDOBJECT . tagName ! ="BODY" ) {
/*TOOLBAR. document . all .mensaj e . innerHTML="No se puede anclar sobre un "+SELECTEDOBJECT. tagName,- */
} /' findAndMarkDock ( ) */
DOCKING (manual)
function manualDockHide (tag, propl, rop2, index, action) { var toReturn = false; var obj Index = 0; docTags = document .all .tags (tag) ,- for (var i=0; i<docTags . length; i++) { var it = docTags . item (i) ;
/* A tiene sOlo el par-metro TEXT y unicamente es anclable. */ if(tag=="A")
{ var condition = i . innerText . indexOf (propl) != -1; } else if (tag == "SELECT" || tag == "INPUT")
{ prop2 = prop2. toLowerCase () ,- var condition =
(propl != null)? (it. ame == propl && it. type == prop2) : (it. type == prop2) ; } else if (tag == "IFRAME" || tag == "IMG" || tag == "OBJECT") { var width = propl, height = prop2 ; if (width) var condWidth = (it.width == width | | parselnt (it .offsetWidth) == width || it . style .posWidth == width); if (height) var condHeight = (it. height == height || parselnt (it .offsetHeight) == height || it . style.posHeight == height);
/* si no fue especificado width */ if (
(Iwidth) && (height) ) var condition = condHeight; /* si no fue especificado height */ else if ( (Iheight) && (width) ) var condition = condWidth;
/* si no fue especificado ninguno */ else if( (Iwidth) && (Iheight) ) var condition = true; /* si fueron especificados ambos */ else if ( (width)
&& (height) ) var condition = ( condWidth && condHeight ) ,-
} if ( condition && (! index || (++obj Index == index)) ) window . shFlag = toReturn = it ; break ,-
} } /* for */
/* manualDockHide ( ) */
DOCKING (delete)
function filterDeleteDock (itemlnList) {
PVFORM. elanclado .value= " " ; si el objeto fue anclado manualmente entonces no tengo la necesidad de cambiarle el color. if ( lista [itemlnList] .manual ) { lista [itemlnList] .hide = false; else { deleteDock (itemlnList) PVFOR . elancladoq . value } /* function filterDeleteDoc (itemlnList)
*/ function deleteDock(itemlnList) { var currentstate
= returnObjectStatus (lista [parselnt (itemlnList) ]) ,- var tmpObjectDD = lista [parselnt (itemlnList) ] ; if (tmpObj ectDD. tagName == "A") { tmpObjectDD. style.backgroundColor = tmpObj ectDD. oldStyle,- tmpObj ectDD. dock = false; tmpObjectDD. selected = false; } else if (tmpObjectDD. tagName == "IMG") { if (currentstate == "selected") { tmpObjectDD. src = theSRC+ ' img/rojo.gif ' ; tmpObj ectDD . dock = false; tmpObjectDD. selected = false; } else if (currentstate == "dock") { tmpObjectDD. src = tmpObj ectDD. oldSrc ; tmpObjectDD. dock = false; }
} else if (tmpObj ectDD. tagName == "IFRAME")
{ if (currentstate == "selected")
{ tmpObjectDD. src
= theSRC+ ' tb_rojo.html? ' +tmpObj ectDD . item; tmpObj ectDD. dock = false; tmpObjectDD. selected = false; } else if (currentstate == "dock") { tmpObjectDD. src = theSRC+ ' tb_mysrc.html? ' +tmpObj ectDD. item tmpObj ectDD . dock = false; } } else if (tmpObjectDD. tagName == "OBJECT") { currentstate = returnObjectStatus (lista [itemlnList] ) ,- if (currentstate
== "selected") { tmpObjectDD. dock = false; tmpObjectDD. selected = false; tmpObjectDD. style.backgroundColor = ROJO; } else if (currentstate == "dock") { tmpObj ectDD . dock = false; tmpObjectDD. selected = false; t tmpObj ectDD. style. backgroundColor = GRIS; , }
} } /* function deleteDock (itemlnList) */ HIDDING
function fmdAndMarkHide () { LASTPOSITION = lista. length; for(i=0; ι<= (lista . length-1) ; ι++) { if ( (lιsta[ι] .item ==
SELECTEDOBJECT. item) && (lista [1] . tagName == SELECTEDOBJECT. tagName) )
{ SELECTEDOBJECT = lista [1] ; /* si el ob3eto que se selecciono ya habia sido seleccionado se usa la misma casilla en la lista global */
LASTPOSITION = 1; }
} ιf( SELECTEDOBJECT. tagName ==
"INPUT" || SELECTEDOBJECT . tagName == "SELECT" || SELECTEDOBJECT . tagName == "IMG") { if (SELECTEDOBJECT. tagName != "BODY") {
/* le coloca color */ /* Si es una imagen le cambiamos el SRC y guardamos el anterior para restaurar... */ if (SELECTEDOBJECT. tagName ==
"IMG" ] I (SELECTEDOB ECT. tagName == "INPUT" && SELECTEDOBJECT . type == "image") ) { if (returnOb3ectStatus () == "none")
{ SELECTEDOBJECT. oldSrc =
SELECTEDOBJECT . src ;
SELECTEDOBJECT . src = theSRC + "ιmg/ro3θ.gιf " ; SELECTEDOBJECT . hide = true; if (SELECTEDOBJECT. tagName == "IMG")
{ SELECTEDOB ECT. width = SELECTEDOBJECT. theWidth,
SELECTEDOBJECT. height = SELECTEDOBJECT. theHeight; } lista [LASTPOSITION] = SELECTEDOBJECT ; } else if (returnObjectStatus () == "dock")
{ SELECTEDOBJECT. src = theSRC + "img/verde .gif " ;
SELECTEDOBJECT. hide = true; SELECTEDOBJECT. selected = true;
SELECTEDOBJECT. idth = SELECTEDOBJECT . theWidth;
SELECTEDOBJECT height = SELECTEDOBJECT . theHeight ; lista [LASTPOSITION] = SELECTEDOBJECT, }
} /* Si es un INPUT o un SELECT le cambiamos el STYLE y guardamos el ιe3θ para restaurar J / else {
X si NO FUE ocultado todavia. */ if (returnObjectStatus () == "none" && ! SELECTEDOBJECT. alreadyHidden) {
SELECTEDOBJECT . oldStyle = SELECTEDOBJECT . style .backgroundColor ;
SELECTEDOBJECT. style.backgroundColor = ROJO;
/* Los select e inputs no se pueden usar para anclar asi que le ponemos SELECTED=TRUE */
SELECTEDOBJECT. hide = true;
SELECTEDOB ECT . selected = true ; lista [LASTPOSITION] = SELECTEDOBJECT;
/* si el objeto es del tipo radio, entonces selecciono todos los objetos */ /* con ese nombre . */ if( SELECTEDOBJECT . type == "radio" --& SELECTEDOBJECT.name ) { changeBG (SELECTEDOBJECT. tagName, SELECTEDOBJECT .name, ROJO) ;
SELECTEDOBJECT. alreadyHidden = false;
} }
} \ if ( ! SELECTEDOBJECT. alreadyHidden) { var theSelectText = SELECTEDOBJECT . tagName + " item(" + SELECTEDOBJECT. item + " ) " ; if (PVFORM. theHiddenObj .options [0] .text == "None selected")
{ PVFORM. theHiddenObj . length = 0 ; var cant = 0 ; } else { var cant = PVFORM. theHiddenObj . length; }
/*Agrega el text y el value al option. */ unaOpcion = TOOLBAR.document . createElement ( "OPTION" ) ; unaOpcion. alue = LASTPOSITION; unaOpcion. text = theSelectText; PVFORM. theHiddenObj .options .add(unaOpcion) ;
PVFORM. theHiddenObj .options [cant] .selected = true;
} } ' } }
/* function findAndMarkHide () */
H1DDING (delete)
function deleteHideO { /* Levanta el objeto hide seleccionado */ itemlnSelect =
PVFORM. theHiddenObj . selectedlndex; if (PVFORM. theHiddenObj .options [PVFORM. theHiddenObj . options . selectedlnd ex]. text == "None selected") { return false; }
/* Le resto uno porque la casilla 0 en el select esta reservada para el texto SELECCIONE UN OBJETO, */
/* pero la de la lista es utilizable asi que hay que empatarlas */ itemlnLista = PVFORM. theHiddenObj .options [PVFORM. theHiddenObj .selectedlndex] .value; var currentstate = returnObjectStatus ( lista [parselnt (itemlnLista) ] ) ; var tmpObjectDH = lista [parseln (itemlnLista) ] ; if( (tmpObjectDH. tagName == "INPUT" || tmpObjectDH. tagName == "SELECT") && tmpObjectDH. type != "image")
{ if ( ! tmpObjectDH.manual) tmpObjectDH. style.backgroundColor = tmpObj ectDH.oldStyle; tmpObj ectDH . hide = false; tmpObjectDH. selected = false; if (tmpObjectDH. type == "radio") changeBG ( " input" , tmpObj ectDH. name, tmpObjectDH.oldStyle) ,- } else if (tmpObjectDH. tagName == "IMG" || (tmpObjectDH. tagName == "INPUT" --& tmpObjectDH. type == "image")) { if (currentstate == "selected") { tmpObjectDH. src = theSRC+ ' img/azul .gif ; tmpObjectDH.hide
= false; tmpObjectDH. selected = false;
} else if (currentstate == "hide") { tmpObjectDH. src = tmpObjectDH. oldSrc ; tmpObjectDH.hide = false;
} } else if (tmpObjectDH. tagName == "IFRAME") { if (currentstate == "selected") { tmpObjectDH. src
= theSRC÷ ' tb_azul .html? ' +tmpObjectDH. item; tmpObjectDH.hide = false; tmpObjectDH. selected = false; } else if (currentstate == "hide") { tmpObjectDH. src = theSRC+ ' tb_mysrc .html? ' +tmpObjectDH . item; tmpObj ectDH.hide = false; }
} else if (tmpObjectDH. tagName ==
"OBJECT") { currentstate = returnObjectStatus (lista [itemlnLista] ) ; if (currentstate == "selected") { tmpObjectDH.hide = false tmpObjectDH. selected = false; tmpObjectDH. style.backgroundColor = AZUL; } else if (currentstate == "hide") { tmpObjectDH.hide = false; tmpObjectDH. selected = false; if (! tmpObjectDH.manual) tmpObjectDH. style .backgroundColor = GRIS;
} }
/* borra el Obj del SELECT */ PVFORM. theHiddenObj . remove (itemlnSelect) ; if (PVFORM. theHiddenObj .options. length == 0) { var unaOpcion =
TOOLBAR. document . createElement ( "OPTION" ) ; unaOpcion.value = 0; unaOpcion . text =
"None selected" ;
PVFORM. theHiddenObj .options .add(unaOpcion) ;
PVFORM. theHiddenObj .options [0] .selected = true;
} else { lastItemInSelect=PVFORM. theHiddenObj .length-1;
/* pasa la seleccion al ultimo objeto (si quedan obj ocultos al ultimo que se ingreso antes del borrado) */
PVFORM. theHiddenObj .options [lastltemlnSelect] . selected=true; } } /* deleteHideO */
end OBJECT KIDDING & DOCKING EVENTOS
esta funcion recibe parametros de toolbar .mouseDown () . envia las posiciones X & Y internas del iframe correspondiente al toolbar en donde se presiono el mouse, esas posiciones son tomadas como iniciales, luego en el mouseMove dentro del toolbar se envϊan las nuevas posiciones, y calculando las diferencias se mueve el iframe.
function mouseDow (offX, offY) { window.leftlnicial = offX; window. toplnicial = offY; MD = true;
esta funcion recibe la posicion del mouse interna del iframe, calcula las diferencias y mueve la toolbar.
*/ function movelf (offX, offY) { if(MD) { var
X = parselnt (offX) - leftlnicial ,- var Y = parselnt (offY) - toplnicial; if (document .all .control) { ifLeft = document .all .control .style.posLeft = (ifLeft + X) ; ifTop = document .all .control, style.posTop = (ifTop + Y) ,-
} } } /* function movelf (offX, offY) */ function mouseUpO { var leftlnicial
= 0; var toplnicial = 0; MD = false; restoreToolBarPositionO ,- } /* function mouseUpO */
TOOLBAR
verifica que toolbar no haya sido arrastrada fuera de la pantalla. y si asi se hizo entonces la vuelve a la posicion mas cercana pero dentro de la ventana.
function restoreToolBarPosition { var toolBarX = document .all .control . style .posLeft ; var toolBarY = document .all .control . style .posTop; var toolBarWidth = parselnt (document .all .control . style.width) ; var toolBarHeight = parselnt (document . all .control . style .height) ; var screenWidth = document .body. clientWidth - 10; var screenHeight = document .bod . clientHeight; if ( (toolBarY - document .body. scrollTop) < 0) { document .all .control .style.posTop = document .body. scrollTop,- } _ else if( (toolBarY + toolBarHeight) > (screenHeight + document .body. scrollTop) )
{ document .all. control . style. osTop = screenHeight + document .body. scrollTop - toolBarHeight; if (document .all . control . style .posTop < document .body . scrollTop) document . all .control . style.posTop=document .body. scrollTop;
} if((toolBarX - document .body. scrollLeft) < 0) { document . all . control . style .posLeft = document .body. scrollLeft; } else if ( (toolBarX + toolBarWidth) > (screenWidth + documen .body. scrollLeft) ) { document .all. control. style. osLeft = (screenWidth + document .body. scrollLeft - toolBarWidth) ,- if (document .all .control . style .posLeft < document .body. scrollLeft) document .all . control . style.posLeft = document .body. scrollLeft; } } /* function restoreToolBarPositionO */ function repositionToolbar () { var screenHeightEnough = (document .body.clientHeight > TOOLBAR. tbHeight) , var toolBarlsMaximized = (TOOLBAR. TBSIZE == "normal"); var shoshkeleWidthBiggerThanScreenWidth = document . all . sh_all_anιm_shoshkelιzer &-- ( (document .all . sh_all_anim_shoshkelιzer . style.posLeft + document .all . sh_all_anιm_shoshkelιzer . style.posWidth) > document . body. clientWidth) ; var shoshkeleHeightBiggerThanScreenHeight = document . all . sh_all_anim_shoshkelizer && ( (document .all . sh_all_anim_shoshkelizer. style.posTop + document .all . sh_all_anιm_shoshkelιzer . style.posHeight) > document.body. clientHeight) ; if ( TOOLBARLOADED &&
((screenHeightEnough £-& toolBarlsMaximized) || ! oolBarlsMaximized) )
{ window . theScrollTop = parselnt (document .body. scrollTop) ; window. theScrollLeft = parselnt (document .body. scrollLeft) ; var elAncho = document .body. scrollLeft + document .body. clientWidth; if (
(window. theScrollWidth < elAncho) &-- ! shoshkeleWidthBiggerThanScreenWidth )
{ dif = window. theScrollWidth - elAncho ; window. scrollBytdif , 0); } var elAlto = document .body . scrollTop + document .body. clientHeight ,- f ( elAlto > window. thescroHHeight && ! shoshkeleHeightBiggerThanScreenHeight)
{ dif = window. thescroHHeight - elAlto ,- window. scrollBy(0, dif);
} if (true)
{ lfdfTopAnt == null) window. ifTopAnt = window. ifTop, if (lfTopAnt != null) { if (ifTop != ifTopAnt) { t .all . control . style .posTop - window } null) window ιf(ιfLeftAnt ! = null)
Figure imgf000138_0001
{ window. ifLeft = document .all .control . style .posLeft-wmdow. theLastScrollLeft ,- window. ifLeftAnt = window. ifLeft;
} } document .all .control . style .posTop = ifTop + parselnt (document .body. scrollTop) , document .all .control . style. posLeft = ifLeft + parselnt (document .body . scrollLeft) ; } window. theLastScrollTop = parselnt (document .body. scrollTop) ; window. theLastScrollLeft = parselnt (document body scrollLeft); } } /"" function repositionToolbar () J /
FUNCIONES GENERICAS function contains (str, containsStr) { var str = str + " " ; return ( str .indexOf (containsStr) != -1 )? true : false; } /> function contains (str, containsStr) */
verifica que existan todos los campos necesarios para el uso de object hidding y docking
*/ function checklnputsO { /* Checkeo de inputs */ if ( ! PVFORM.widthDock || ! PVFORM. heightDock
I I ! PVFORM. widthHide | | ! PVFORM.heightHide | | ! PVFORM. tagNameElemForm | | ! PVFORM. tagHide || ! PVFORM. tagDock ) { return false; }
} /* function checklnputsO */
borra el contenido de los inputs de object hidding y docking
*/ function clearlnputs 0 { setValue ( "widthDock" , " " ) ,- setValue ( "widthDock" , ""),- setValue ( "heightDock" , " " ) ; setValue ( "widthHide" , " " ) ,- setValue ( "heightHide" , " " ) ; setValue ( "tagHide" , " " ) ; setValue( "tagDock" , " " ) ; setValue ( "textA" , " " ) setValue ( "hidelndex" , " " ) ; setValue ( "anchindex" , " " ) ,- } /* function clearlnputs ( ) */
funcion generica que obtiene el index de OPTION con el valor especificado dentro de un SELECT.
*/ function formGetSelectlndexByValue (objString, val) var tmpObj = PVFORM [objString] ; fortvar i=0; i<tmpObj .length; i++) { if (tmpObj .options [i] .value == val)
{ return i; } }
} /* function formGetSelectlndexByValue (objString, val)
* /
Esta funcion checkea el status del objeto en cuanto a HIDE DOCK y SELECT y devuelve el actual
*/ function returnObjectStatus (obj ) { v objeto = (obj)? obj : SELECTEDOBJECT; if (objeto. selected == true) return " selected" ,- else if (objeto.dock == crue) return "dock"; else if (obj eto. hide == true) return "hide"; else return "none"; }
/* function returnObjectStatus (obj ) */
function getSelectedlndexByValue (objString, val) { fortvar i=0; i<objString .length; i++) { if (objString.options [i] .value == val) { return i ; } }
} /* function getSelectedlndexByValue (objString,val) */
cambia el color de todos los radios con el name especificado
*/ function changeBG(tagName, name, color) { var coll = document .all .tags (tagName) ,- for(var i=0; i<coll . length; i++) { if ( Ina e || name == coll . item (i) .name ) { if ( Icoll . item(i) . style .oldStyle) coll. item(i) . style .oldStyle = coll. item(i) . style .backgroundColor,- coll. item (i) . style .backgroundColor = color; coll . item(i) .alreadyHidden = (color
== ROJO)? true : false; } }
} /* function changeBG(tagName, name, color) */ Dragging del objeto flash
function MD(e) { /* United
Virtualities onmousedown (pis, do NOT remove this line) */ top.window. thescroHHeight = top. document .body. scrollHeight; top.window. theScrollWidth = top. document .body . scrollWidth; if (event . srcElement . id == "laBarra" || event . srcElement . id == "laBarra_center" || event . srcElement . id == "laBarra_resize_img" ) { window.maskDiv = document . all . laBarra . style; window.X = event .offsetX; window. Y = event .offsetY; if ( event .srcElement . id == "laBarra_resize_img" )
{ document .all . sh_all_anim_shoshkelizer. style,visibility = "hidden" ,- document .all .maskFlagLayer. style .visibility = "hidden"; document .all . sh_all_anim_borders . style .visibility = "visible";
ORIGINAL_WIDTH = document . all . sb_all_anim_shoshkelizer . style .posWidth;
ORIGINAL_HEIGHT = document .all . sh_all_anim_shoshkelizer. style .posHeight ;
RESIZE_FLAG = true; } else
{ if ( ! TOOLBAR. SHOW_CONTENT_ON_DRAG_FLASH)
{ parent .document .all . sh_all_anim_shoshkelizer. style.visibility =
"hidden" ,- parent .document .all . sh_all_anim_borders . style.visibility = "visible" ,-
} /* si hay un panel visualizado, y no es el de posicion, lo visualizo. */ if (TOOLBAR. BBUTTONDOWN && TOOLBAR. BBUTTONDOWN != "btnpos") TOOLBAR. tbButtonPress (TOOLBAR. document .all.btnpos) ,-
} } } /* MD */
RESIZE FUNCTIONS
function resize_manualApρly ( ) { if (PVFORM. resizeWidth.value>0 I | PVFORM. resizeHeight .value>0)
{ var newW = PVFORM. resizeWidth.value; var newH = PVFORM. resizeHeight .value ; if (newW < 160) {
PVFORM. resizeWidth.value = document .all . sh_all_anim_shoshkelizer . style .posWidth; PVFORM. resizeHeight.value = document .all . sh_all_anirt_shoshkelizer. style .posHeight; uvAlert ("Width must be larger than 160 pixels");
PVFORM. resizeWidth. focus () ; return false;
} resize__setVars (newW, newH) ,- resize__applyToBorder (newW, newH) ,- resize__applyToFlash(newW, newH) ; resize_applyToBar (newW, newH) ,- * document .all . laBarra. style.posTop = resize_getBarTop () ,- documen .all .laBarra. style.posWidth = newW; resize_applyToMaskFlag () ; resize_reApplyCentered(newW) ,- }
} /* function resize_manualApply ( ) */ function resize_reApplyCentered(w) { var newCenter = ( (document .body.clientWidth - 16) - w ) / 2 ,- PVFORM. leftCenter.value = parselnt (document .all . sh_all_anim_shoshkelizer . style .posLeft - newCenter) + 1; } /* function resize_reApplyCentered (w) */ function resize_getHeightFromWidth(currentWidth) { var ob = document . all . sh_all_anim_shoshkelizer . style ,- var widthDiff = parselnt( (( (event. clientX - ob. osLeft) - ORIGINAL_WIDTH) / ORIGINAL_WIDTH) * 100); return (parselnt (ORIGINAL_HEIGHT + parselnt (ORIGINAL_HEIGHT * (widthDiff / 100)))); } /* function resize_getHeightFromWidth (current idth) */ function resize_getWidthFromHeight (currentHeight) { var ob = document .all . sh_all_anim_shoshkelizer . style; var heightDiff = parselnt ((( (event. clientX - ob.posLeft) - ORIGINAL_HEIGHT) / ORIGINAL_HEIGHT) * 100) ; return
(parselnt (ORIGINAL_WIDTH + parselnt (ORIGINAL_WIDTH * (heightDiff / 100))));
} /* function resize_getWidthFromHeight (currentHeight) */
/* no event */ function resize_getHeightFromWidthNoEvent (currentWidth) { var ob = document .all . sh_all_anim_shoshkelizer. style; var widthDiff = parselnt (( (currentWidth - ORIGINAL_WIDTH) / ORIGINAL_WIDTH) * 100) ; return
(parselnt (ORIGINALJHEIGHT + parselnt (ORIGINAL_HEIGHT * (widthDiff / 100))));
} /* function resize_getHeightFromWidthNoEvent (currentWidth) */
/* no event */ function resize_getWidthFromHeightNoEvent (currentHeight) { var ob = document . all . sh_all_anim_shoshkelize . style; var heightDiff = parselnt (( (currentHeight - ORIGINAL_HEIGHT) / ORIGINAL_HEIGHT) * 100) ; return
(parselnt (ORIGINAL_WIDTH + parselnt (ORIGINAL_WIDTH * (heightDiff / 100))));
} /* function resize_getWidthFromHeightNoEvent (currentHeight) */ function removeMinus (inputObject) { var lastlndexOfMinus = inputObject .value . lastlndexOf ( " - " ) ; if( lastlndexOf inus != 0 && lastlndexOfMinus != -1 ) { if (inputObject.value. charAt(O) == "-") { inputObject .value = inputObject . alue . replace (/-/g, " " ) ; inputObj ect .value = "-" + inputObj ect .value,-
} else { inputObject .value = inputObject .value, replace (/-/g, ""),- }
} } /* function removeMinus (inputObject) */ function resize_updateHeightFromWidth( ) { removeMinus (PVFORM. resizeWidth) ,-
PVFORM. resizeHeight .value = resize_getHeightFromWidthNoEvent (PVFORM. resizeWidth.value) ; } /* function resize_updateHeightFromWidth() */ function resize_updateWidthFromHeight 0 { removeMinus (PVFORM. resizeHeight) ;
PVFORM. esizeWidth. alue = resize_getWidthFromHeightNoEvent (PVFORM. resizeHeight .value) ;
} /* function resize_updateWidthFromHeight ( ) */ function resize_getWidth( ) { izq=event .clientX - document .all . sh_all_anim_borders . style .posLeft; return (izq) ; } /* function resize_getwidth() */ function resize_getBarTop 0 { return (document .all . sh_all_anim_borders . style. osTop + document .all . sh_all_anim_borders. style.posHeight) ,- } /* function resize_getBarTop ( ) */ function resize_setVars (newW, newH) { if(newW >= 160) {
PVFORM. resizeHeight.value = shHeight = TOOLBAR. shHeight = newH;
PVFORM.resizeWidth.value = shWidth = TOOLBAR. shWidth = newW; } } /* function resize_setVars (newW, newH) */ function resize_applyToBorder (newW,newH) { if(newW >= 160) { document .all . sh_all_anim_borders . style .posWidth = newW; document .all . sh_all_anim_borders. style.posHeight = newH; } } /* function resize_applyToBorder (newW,newH) */ function resize_applyToFlash(newW,newH) { if(newW >= 160) { document .all . sh_all_anim_shoshkelizer. style.posWidth = newW; document .all . sh_all_anim_shoshkelizer. style .posHeight = newH; } } /* function resize_applyToFlash (newW, newH) */ function resize_applyToBar (newW,newH) { if(newW >= 160) { document .all . laBarra . style.posWidth = newW; document .all . laBarra. style .posTop = newH; document . all . resize_button. style .posTop = 0; document .all . resize_button. style. osLeft = document .all . laBarra. style .posWidth - 20; top.window. thescroHHeight = top. document .body. scrollHeight ; top.window.theScrollWidth = top. document .body. scrollWidth; } }
/* function resize_applyToBar (newW,newH) */ function resize_applyToMaskFlag () { documen .all .maskFlagLayer. style.posTop = document .all .laBarra. style.posTop; } /* function resize_applyToMaskFlag() */ function resize_reApplyCentered(w) { var newCenter = ( (document .body.clientWidth - 16) - w ) / 2; PVFORM. leftCenter.value = parselnt (document .all . sh_all_anim_shoshkelizer. style.posLeft - newCenter)
} /* function resize_reApplyCentered(w) */
backward compatibility
*/
function sh_cargar ( ) { } function shFinish O { } function shClick() { } function shView () { }
/*
Eventos
*/
function MM() { /* United
Virtualities onmousemove */ if (window. event.button == 1) { if (window.maskDiv && RESIZE_FLAG) { if (TOOLBA . TBBUTTONDOWN
&& TOOLBA . TBBUTTONDOWN != "btnresize")
TOOLBAR. tbButtonPress (TOOLBAR. document .all .btnresize) ; var newW = resize_getWidth () ,- var newH = resize_getHeightFromWidth (newW) ; resize_setVars (newW, newH) ; resize_applyToBar (newW, resize_getBarTop ( ) ) ; resize_applyToBorder (newW,newH) ; resize_reApplyCentered(newW) ,- } else if (window.maskDiv) { var newX = event .clientX - X + document .body. scrollLeft - 2; var newY = event . clientY - Y + document .body. scrollTop - 2;
/* offscreen object patch. */ var condl = (event .clientX < document .body. clientWidth) ,- var cond2 = (event .clientX > 0); var cond3 =
(event .clientY < document .body. clientHeight) ,- var cond4 = (event .clientY > 0) ; if ( condl && cond2 && cond3 && cond4 )
{ document .all. sh_all_anim_borders. style. ixelLeft = newX; document .all. sh_all_anim_borders. style.pixelTop = newY - shHeight; document .all . sh_all_aniπ_shoshkelizer. style.pixelLeft = newX; document .all . sh_all_anim_shoshkelizer. style .pixelTop = newY - shHeight ; maskDiv.pixelLeft = newX; maskDiv.pixelTop = newY; document .all . laBarra. style.pixelLeft = newX; document .all .laBarra. style.pixelTop = newY; document .all .maskFlagLayer . style .pixelLeft = newX; document .all .maskFlagLayer . style.pixelTop = newY;
TOOLBAR. setUpAllPos (newX-shWidth,newY) ;
} return false;
} } else { maskDiv = null; } } /* MM */ function MU() { /* United
Virtualities onmouseup */ if (document .all . sh_all_anim_shoshkelizer) { if (RESIZE_FLAG)
{ document .all . sh_all_anim_shoshkelizer. style .posWidth = document . all . sh_all_anim_borders . style.posWidth; document .all . sh_all_anim_shoshkelizer. style .posHeight = document . all . sh_all_anim_borders . style.posHeight ; document .all . sh_all_anim_shoshkelizer . style .visibility = "visible" ,- document .all .maskFlagLayer. style. osTop = document . all . laBarr . style . posTop; document .all .maskFlagLayer. style.visibility = "visible"; document .all . sh_all_anim_borders . style .visibility = "hidden"; RESIZE_FLAG = false;
} if ( !TOOLBAR. SHOW_CONTENT_ON_DRAG_FLASH)
{ document .all . sh_all_anim_shoshkelizer. style .visibility = 'visible' ; document .all . sh_all_anim_borders .style. isibility = 'hidden';
} } }
/- MU -/ function resizeCenter () { lJ- United Virtualities onresize */ if (window. onresizeFlag)
{ window.newCenter =
( (TOOLBAR. ShGetWindowWidthO - shWidth) / 2) ,- var newLeft = newCenter + parselnt (TOOLBAR. PVFORM. leftCenter.value) ,- var newTop = TOOLBAR. PVFORM. topCenter.value; layerMove (document .all . sh_all_anirt_shoshkelizer, newLeft, newTop) ,- layerMove (document . all . sh_all_anim_borders , newLeft, newTop) ; layerMove (document .all .maskFlagLayer, newLeft, parselnt (newTop) + parselnt (shHeight) ) ,- layerMove (document . all . laBarra, newLeft , parselnt (newTop) + parselnt (shHeight) ) ,- } else if (TOOLBAR. document .forms [0] .elancladoq.value) {
TOOLBAR.moveShoshToTheFixPos () ; } window. ifLeft = window. ifLeft + window. theScrollLeft; window. ifTop = window. if op + window. theScrollTop; window. theLastScrollLeft=document .body. scrollLeft ; window. theLastScrollTop=document .body. scrollTop; restoreToolBarPositionO; } /* function resizeCenter 0
*/ function selectStart ( ) { /* United
Virtualities onselectstart */ if (event .srcElement. tagName != "TEXTAREA") return false; } /* function selectStart 0 */
posicionamiento de layers
*/
function layerMove (layer, left, top) { layer, style .posTop=top;layer. style .posLeft=left ,- }
LANDING SPOT
*/
function landing_returnShAHAnimHTML 0 { var barraWidth = TOOLBAR. shWidth; var barraHeight = 20; var pos = TOOLBAR. returnPositions 0 ,- var shTop = parseln (pos . sh_all_anim_sho'shkelizer. top) ; var shLeft
= parselnt (pos . sh_all_anim_shoshkelizer. left) ,- return '<object id="sh_all_anim_shoshkelizer" style="width: ' + shWidth + 'px; height: ' + shHeight + 'px; display-.none,- position: absolute; z-index:99; top:' + shTop + 'px; left:' + shLeft + 'px; " classid="clsid:D27CDB6E-AE6D-llcf-96B8-444553540000"
CODEBASE="http://download.macromedia. com/pub/shockwave/cabs/flash/swflash. ca b#version=5 , 0 , 0, 0" param name=movie value="' + TOOLBAR. shLocation + '"xparam name=quality value=highxparam name="loop" value="false"xparam name="wmode" value="transparent"xPARAM NAME=salign VALUE=LTx/object>\n' ,-
} /* function landing_returnShAHAnimHTML 0 */ function render () {
TOOLBAR. document. all.vidrio. style. visibility = "visible";
/* si alg'n panel est- siendo mostrado, lo oculto. */ if (TOOLBAR. TBBUTTONDOWN) TOOLBAR. tbButtonPress (TOOLBAR. document. all [TOOLBAR. TBBUTTONDOWN] ) ; if (window. LS_IVAN) { edit (window. iniLs, window. finLs , window. finish, window. eas, window. osx, window.posy) ; } else
{ / *document .all . control . style . display
= ' one ' ; */ document . all . sh_all_anim_shoshkelizer. outerHTML = ' ' ,- window . shAllAnimHTML = landing_returnShAllAnimHTML ( ) ,- document .body. insertAdjacentHTML ( "beforeEnd" , ShAllAnimHTML) ; setTimeout O'flashSetVariablesAndShow (2) ,-",1000) ,- }
} /* function render () */ function edit (iniLs, finLs, finish, eas, posx) posy) { document .all . sh_all_anim_shoshkelizer. outerHTML = ' ' ,- parent .document .body . insertAdjacentHTML ( "beforeEnd" , landing_returnShAl lAnimHTML () ) ,- window. iniLs = parselnt (iniLs) ; window. finLs = parselnt (finLs) ; window. finish = parselnt (finish) ; window. eas = parselnt (eas) ,- window. largo = parselnt (finLs - iniLs); window. posx = parselnt (posx) ; window. posy = parselnt (posy) , setTimeout O'flashSetVariablesAndShow (3) ,-",1000) ,- } /* function edit (iniLs, finLs, finish, eas, posx, posy) */ function flashSetVariablesAndShow(flag) {
//alert ( "flashSetVariablesAndShow ( "+flag+" ) ") ; if ( [document .all . sh_all_anim_shoshkelizer. wmode )
{ setTimeout ("flashSetVariablesAndShow (" + flag + ")",1000); } /* changeFlashO */ else if (flag == 1) {
TOOLBAR . ocument .all .vidrio. style.visibility = "hidden";
/* HARDCODE */ if (! window. iniLs) { window. iniLs = parselnt (TOOLBAR. qs . iniLs) ; window. eas = parselnt (TOOLBAR. qs .eas) ,- window. finLs = parselnt (TOOLBAR. qs . finLs) ; window, finish = parselnt (TOOLBAR, qs . finish) ,- window.posx = parselnt (TOOLBAR. qs .posx) ; window. posy = parselnt (TOOLBAR. qs .posy) ,-
/* si ya se analizo el Landing Spot */ if ( ! (window. iniLs == 0 && window. eas == 0 && window. finLs == 0 && window. finish == 0 && window.posx == 0 && window.posy == 0) )
{ windo . LS_IVAN = true ; } } document . ll . sh_all_anim_shoshkelizer . SetVariable ( ' ShkLandingMode ' , 'edit' ) ,- document .all . sh_all_anim_shoshkelizer .SetVariable ( ' ShkConectado ' , '1'); document . all . sh_all_anim_shoshkelizer . SetVariable ( ' ShkLandinglnicio ' , window. iniLs) ,- document . all . sh_all_anim_shoshkelizer . SetVariable ( ' ShkLandingEasing ' , window. eas) ; document . all . sh_all_anim_shoshkelizer . SetVariable ( ' ShkLandingLargo ' , window. finLs) ; document . all . sh_all_anim_shoshkelizer . SetVariable ( ' ShkTimeFinish ' , window, finish) ,- document . all . sh_all_anim_shoshkelizer . SetVariable ( ' ShkLandingPosX ' , window.posx) ; document .all . sh_all_anim_shoshkelizer.SetVariable ( ' ShkLandingPosY' , window. osy) ,- document . all . sh_all_anim_shoshkelizer . SetVariable ( ' ShkServido ' , theSRC) ; /*donde va a- estar alojado todo, debe terminar en / */ setTimeout ( "document . all . sh_all_anim_shoshkelizer . style . display = 'inline' ,-",2000) ; } /* render () */ else if (flag == 2) { document . all . sh_all_anim_shoshkelizer. SetVariable ( ' ShkLandingMode ' , ' editRender ' ) ; document .all . sh_all_anim_shoshkelizer .SetVariable ( ' ShkConectado ' , ' 1 ' ) ; document . all . sh_all_anim_shoshkelizer . SetVariable ( ' ShkRenderAncho ' , TOOLBAR. shWidth) ; document . all . sh_all_anim_shoshkelizer . SetVariable ( ' ShkRenderAlto ' , TOOLBAR . shHeight) ; document . all . sh_all_anim_shoshkelizer . SetVariable ( ' ShkServidor ' , theSRC) ,- /*donde va a estar alojado todo, debe terminar en / */
/* al mostrarse el flash llama a edit () */ setTimeout ( "document .all . sh_all_anim_shoshkelizer . style. display= ' inlin e' ;",2000) ; setTimeout ("document .all. control . style. display = 'inline' ;",3000) ; } /* editO */ else if (flag == 3) { document .all . sh_all_anim_shoshkelizer .SetVariable ( ' ShkLandingVersion' , ' easy' ) ; documen . all . sh_all_anim_shoshkelizer . SetVariable ( ' ShkLandingMode ' , ' editAct ' ) ,- document .all . sh_all_anim_shoshkelizer .SetVariable ( 'ShkConectado' , ' 1 ' ) ; document .all . sh_all_anim_shoshkelizer . SetVariable ( ' ShkLandinglnicio ' , window. iniLs) ,- document .all . sh_all_anim_shoshkelizer. SetVariable ( ' ShkLandingEasing ' , window. eas) ,- document . all . sh_all_anim_shoshkelizer . SetVariable ( ' ShkLandingLargo ' , window. finLs) ; document .all . sh_all_anim_shoshkelizer. SetVariable ( ' ShkTimeFinish' , window, finish) ,- documen . all . sh_all_anim_shoshkelizer . SetVariable ( ' ShkLandingPosX ' , window. posx) ,- document .all . sh_all_anim_shoshkelizer. SetVariable ( 'ShkLandingPosY' , window. posy) ,- documen .all . sh_all_anim_shoshkelizer .SetVariable ( ' ShkServidor' , theSRC) ,- /*donde va a estar alojado todo, debe terminar en / */ window . LS_IVAN = true; setTimeout ( "document . all . sh_all_anim_shoshkelizer . style . display= ' inlin e' ;",2000) ; setTimeout ("document .all .control . style, display = 'inline' ,-",3000) ; } } /* function flashSetVariablesAndSho (flag) */ function lsSet(iniLs, finLs, finish, eas, posx, posy) { window. iniLs_initial = window. iniLs = iniLs; window. eas_initial = window. eas = eas; window. finLs_initial = window. finLs = finLs ; window. finish_initial = window. finish = finish; window.posx_initial = window.posx = posx; window.posy_initial = window.posy = posy; windo . LS_IVAN = true; } /* function IsSet (iniLs, finLs, finish, eas, posx, posy) */ function save (iniLs, finLs, finish, eas, posx, posy) { if (TOOLBAR. qs. IdMediaDet == 0) { uvAlert ( "These changes cannot be saved because the site does not belong to the media plan."),- } else { TOOLBAR . qs . iniLs = window. iniLs = iniLs ; TOOLBAR. qs.eas = window. eas = eas,- TOOLBAR. qs.finLs = window. finLs = finLs ;
TOOLBAR. qs .finish = window. finish = finish; TOOLBA . qs .posx = window.posx = posx; TOOLBAR. qs .posy = window. osy = posy; uvAlert ("The Shoshkele has been set successfully."),- }
} /* function save (iniLs, finLs, finish, eas, posx, posy) */
variables
var stoper = false;
var ifTopAnt = null; var ifLeftAnt = null;
window. theLastScrollTop = parselnt (document .body . scrollTop) ; window. theLastScrollLeft = parselnt (document .body. scrollLeft) ;
if (document .all .control)
{ window. ifTop = document .all .control . style .posTop; window. ifLeft = document .all .control . style.posLeft;
window. onscroll = repositionToolbar;
window . theScrollTop=0 ; window . theScrollLeft=0 ,-
var TOOLBARLOADED = false; var SELECTEDOBJECT ; var lista = new Array () ; var EXISTE ;
var ITEMTODELETE=0; var LASTPOSITION=0;
var ROJO="FF1410"; var AZUL="1014FF"; var VERDE="18FB10" ; var GRIS = "AAAAAA" ;
var RESIZE_FLAG = false; var ORIGINAL WIDTH; var ORIGINAL_HEIGHT;
if (theToolBar)
{ window. control = window .TOOLBAR = theToolBar
}
top.window. onresize = resizeCenter; document .onmousedown = MD; document . onmousemove = MM; document . onmouseup = MU; document .onselectstart = selectStart;
preStart ( ) ,-
/*
verificacion de sobreescritura de eventos function overwriteEvents () { if (
! contains (window. onresize, "United Virtualities onresize") )
{ window. onresize = resizeCenter;
} if ( ! contains (document . onmousemove,
"United Virtualities unmousemove" ) ) { document . onmousemove = MM; } if ( ! contains (document .onmouseup, "United Virtualities onmouseup") ) { document . onmouseup = MU; } if ( !contains (document .onselectstart, "United Virtualities onselectstart") ) { document .onselectstart = selectStart; } setTimeout ("overwriteEvents () " , 500); } /* function overwriteEvents ( ) */
overwriteEvents ( )
ALIASES
*/ function changeFlashO { TOOLBAR. changeFlash ( ) ,- } function setQSVariable (variableName, variableValue) { TOOLBAR. setQSVariable (variableName, variableValue); } function returnDockHiddinglndex(objeto) { return TOOLBAR. returnDockHiddinglndex(objeto) ; } function setValue (objElement, objValue) { TOOLBAR. setValue (objElement , objValue) ,- } function returnObjectPropertiesIndex(obj ) { return TOOLBAR. returnObj ectPropertiesIndex (obj ) ,- }
/*
FIN de control.asp
*********************************** ******************** **************************************************************************** ********************
**************************************************************************** ********************
**************************************************************************** ********************
2.1 tb_azul.html, tb_mysrc.html, tb_rojo.html, tb_verde.html
INICIO de tb azul.html
II-
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<HTML> l
<HEAD>
<TITLE> IFRAME FOR CAPTURE </TITLE>
<BODY bgcolor="#1014FF">
<CENTER>
<FONT face= "Verdana" SIZE="2" COLOR="#333399"xB>Anchored<BR>available for hiding</Bx/FONT>
</CENTER>
<SCRIPT LANGUAGE= "JavaScript"> if (location.href .indexOf ( ' ? ' ) !=-l) { var item = location.href . substring (location.href . indexOf ('?')+!, location.href . length) ;
}else{ alertO o llego el item al IFRAME'),
} function down ( ) { parent . iframeClicked (item) ;
} function over ( ) { parent . iframeOver (item) ,- } document . onclick=down; document .onmouseover=over;
</SCRIPT>
</B0DY>
</HTML>
FIN de tb azul.html
II-
INICIO de tb_mysrc.html
//--> <html>
<headxtitle>IFRAME FOR CAPTURE</titlex/head>
<body bgcolor= " orange" --
<centerxfont face= " Verdana" size= "2 " color= "#333399 " xb>Available for hiding --amp; anchoring</bx/f ontx/center>
<script language=" avaScript"> if (location.href .indexOf ( '? ' ) !=-l)
{ var item = location. href . substring (location.href . indexO ( ' ? ' ) +1, location. href .length) ;
} else
{ alertONo llego el item al IFRAME');
}
function downO parent . iframeClicked (item) }
function over ( )
{ parent .iframeOver (item) ,-
document .onclick = down; document . onmouseover = over; </script>
</body> </html> <!--
FIN de tb_mysrc.html
II-
INICIO de tb_rojo.html
//" =
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transιtιonal//EN" >
<HTML>
<HEAD>
<TITLE> IFRAME HIDED</TITLE>
<BODY bgcolor="#FF1410">
<CENTER>
<FONT face= "Verdana" SIZE= " 2 " COLOR= "#333399 " xB>Hidden<BR>available for anchoring</Bx/FONT> </CENTER>
<SCRIPT LANGUAGE="JavaScript"> if (location.href .indexOf ( ' ?' ) !=-l) { var item = location.href . substring (location.href .indexOf ('?')+!, location.href .length) ;
}else{ alert ('No llego el item al IFRAME');
} function down ( ) { paren . iframeClicked(item) ;
} function over ( ) { parent . iframeOver (item) ,-
} document . onclick=down; document . onmouseover=over;
</SCRIPT>
</BODY>
</HTML>
FIN de tb_roj o . html
II-
INICIO de tb verde.html
//-->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" > <HTML> <HEAD>
<TITLE> IFRAME FOR CAPTURE </TITLE>
<BODY bgcolor="#18FB10">
<CENTER>
<FONT face= "Verdana" SIZE= " 2 " COLOR= " #333399 " xB>Hidden S-amp ; Anchored</Bx/FONT>
</CENTER>
<SCRIPT LANGUAGE="JavaScript"> if (location.href . indexOf ( ' ? ' ) !=-l) { var item = location.href . substring (location.href . indexOf ('?')+!, location.href .length)
}else{ alert ('No llego el item al IFRAME'),-
} function down() { parent . iframeClicked(item) ,-
} function overt) { parent . iframeOver (item) ,-
} document . onclick=down; document . onmouseover=over;
</SCRIPT>
</BODY>
</HTML>
FIN de tb verde.html
II- Module 3: Timeline Code
The final timeline code generated by the code generator looks something like this: Conventions:
The commentaries will be expressed in the following way:
/* timeline original commentary */ // explicative commentary
// TIMELINE START // // The timeline is non-lineal, that's why the commentaries will be enumerated.
//
// [STEP 1]
// // Heading
//
// Contains variables with the most important and needed values:
//
// flashWidth // FlashHeight
// shTop: flash top position (relative to the object to which is anchored)
// shLeft: flash left position (relative to the object to which is anchored) // flashName: name of the swf. file
// landingFlag: Applicable only if the landing spot was modified.
//
// (irrelevant) Necessary variables to the modified landing spot:
// iniLs // eas
// finLs
// finish
// posx
// posy // url
//
// shObjeto: initializes the variable that will contain the "anchor" object .
// shPosType: Type of position (fixed/docked/centered)
/** [ sHeader] *************************************************************** ****
/*
(paramsl=shLocation%3Dhttp%3A//www. shoshkelizer.com/upload/files/00001690/dk l_discount_tire_2. swf%26shWidth%3D755%26shHeight%3D685&params2=posType%3Ddoc ked%26top%3D-82%261eft%3D-
629%26dockHidding%3Dimg%211%21120%21600%212%210%26iniLs%3D0%26eas%3D0%26finL s%3D0%26finish%3D0%26posx%3D0%26posy%3D0%26Scroll%3Dl%26removeAds%3Dl--IdMedi aDet=32185--IdCreative=1900-.IdCreativeProps=32170&IdAnimationFile=2375--IdBann erFile=0&ventana=0&Flaco=3&LS=l&pvTipo=standard&RAND=7l4) */ var flashWidth=755 , flashHeight=685 , shTop=-82 , shLeft=-
629, flashName= 'dkl_discount_tire_2.swf ' , landingFlag = true; var iniLs = 0, eas = 0, finLs = 0, finish = 0, posx = 0, posy = 0, url =
'undefined' ; var shObjeto=false,- var shPosType = 'docked';
/*************************************************************************** ****/ /** [j sFunctions] ************************************************************ ****/ function shFlashObj ()
{ return ' <OBJECT ID="sh_all_anim" STYLE= "position: absolute; top: '+shTop+ 'px,-left : '+shLeft+ 'px,-z- index:1000;display:none,-" CLASSID="clsid:D27CDB6E-AE6D-llcf-96B8- 444553540000" CODEBASE="http://download.macromedia. com/pub/shockwave/cabs/flash/swflash. ca b#version=4 ,0,2,0" width= " ' +flashWidth+ ' " height= " ' +flashHeight+ ' "xPARAM NAME=movie VALUE=" ' +theSRC+flashName+ '"xPARAM NAME=quality VALUE=highxPARAM NAME="LOOP" VALUE="false"xPARAM NAME="wmode" VALUE= "transparent "xPARAM NAME=SALIGN VALUE=TxPARAM NAME=MENU VALUE=FALSEx/OBJECT> ' ;
} function shClose(){ shFinishO; if (shFrameObject .document .all . sh_all_anim) shFrameObject .document .all . sh_all_anim. style. display= 'none ' ,- } function shReplay ( ) { sh_all_anim. style.display = "none"; sh_all_anim.movie = "htt ://a619.g.akamai.net/7/619/2021/v001/64.42.219.1/web/mmf/pagain. swf"; if (window. shGoHide) shGoHide 0 ,- if (window. landingFlag)
{ setTimeout ("sh_all_anim. movie = '" + theSRC + flashName +
100) ; setTimeout ("shLandingSpot () ;",200) ;
} else
{ setTimeout ( "sh all anim.movie = '" + theSRC + flashName +
100) ; setTimeou ( "sh_all_anim. style .display = 'inline'", 200)
} ' function shLandingSpot 0
{ if( ! sh all anim. mode setTimeout ("shLandingSpot 0 ; " , 100) } else
{ sh_all_anim. SetVariable ' ShkLandingMode ' , ' play' ) ; sh_all_anim. SetVariable 1 ShkConectado ' , ' 1 ' ) ; sh_all_anim. SetVariable 'ShkLandinglnicio' , parselnt (iniLs) ) ,- sh_all_anim. SetVariable ' ShkLandingEasing ' , parselnt (eas) ) ,- sh_all_anim. SetVariable ' ShkLandingLargo ' , parselnt (finLs) ) ,- sh_all_anim. SetVariable ' ShkTimeFinish' , parselnt (finish) ) ,- sh_all_anim. SetVariable ' ShkLandingPosX ' , parselnt (posx) ) ,- sh_all_anim. SetVariable ' ShkLandingPosY' , parselnt (posy) ) ; sh_all_anim. SetVariable ' ShkPlayAncho ' , parselnt (flashWidth) ) ,- sh_all_anim. SetVariable 'ShkPlayAlto' , parselnt (flashHeight) ) ,- sh all anim. SetVariable ' ShkRandomPing ' , url); setTimeout ( "sh_all_anim. style. display = 'inline'", 100);
} } function overwriteEvents () function contains (str, containsStr) { var str = str + " " ,- return ( str. indexOf (containsStr) != -1 )? true : false; } if ( (shFramePointer. shPosType == "center" || shFramePointer. shPosType == "docked") &-- ! contains (window. onresize, "UV.OR") ) { window. siteResize = onresize; shFrameObject .onresize = shFramePointer . shReposition; } setTimeout ( "overwriteEvents 0 ; " , 200),;
} function shRepositio 0 { /*UV.OR*/ /*shRepositionAnchored*/ if (!window. shRepositionCount) window. shRepositionCount = 1; else shRepositionCount++ ; if (shFrameObject .siteResize && shRepositionCount > 1) shFrameObject . siteResize () ; if (! shFrameObject .shVanished) { var obj = shObjeto, shY = 0, shX = 0 ; while (obj ) { shY += obj .offsetTop; shX += obj .offsetLeft; obj = obj .offsetParent; } if (window. shScrollOK) shScroll () ; else setTimeout ("sh_all_anim. style, top = " + (shY + shTop) + ",-", 100); setTimeout ( "sh_all_anim. style .left = " + (shX + shLeft) + ";", 100); } } function returnOrHide (tag,propl,prop2 , index, action)
{ var toReturn = false; var obj Index = 0 ; docTags = shFrameObject .document .all . tags (tag) ,- for (var i=0; i<docTags . length; i++)
{ var it = docTags . item(i) ,- if (tag=="A") var condition = it . innerText . indexOf (propl) != -1;
} else if (tag == "SELECT" || tag == "INPUT")
{ prop2 = prop2. toLowerCase ( ) ,- var condition = (propl != null)? (it.name == propl && it. type == prop2) : (it. type == prop2) ,-
} else if (tag == "IFRAME" || tag == "IMG" || (tag == "OBJECT" &£-
(ϋt.id || it. id != "sh_all_anim" ) ) ) { var width = propl , height = prop2 ; if (width) var condWidth = (it. idth == width | | parselnt (it .offsetWidth) == width || it . style.posWidth == width); if (height) var condHeight = (it.height == height || parselnt (it .offsetHeight) == height || it . style .posHeight == height) if( (Iwidth) && (height) ) var condition = condHeight; else if ( (Iheight) &-- (width) ) var condition = condWidth; else if( (Iwidth) && (Iheight) ) var condition = true; else if ( (width) £-& (height) ) var condition = ( condWidth &-- condHeight ) ; } if ( condition &-- (! index || (++objIndex == index)) )
{ var debug = "condition = " + condition + ";\n" + "! index = " + ! index + ";\n" + "obj Index = " + obj Index + ";\n"; if (action=="return" ) { toReturn = inbreak;
} else
{ it . style,visibility = action,- if (width && height && index) break;
} var condition = false;
if (action=="return" && toReturn) return toReturn,-
} function sh_finish(){ shFinishO;} function shFinishO {} function shCommandO
{ var shResult = false; if ( (shResult=flashGetVar { ' SH_JS_CLICK' ) ) ) shClickO ,- if ( (shResult=flashGetVar { ' SH JS CLOSE')))
{ sh_all_anim. style .display= 'none ' ,- shFinishO ,-
} if ( (shResult=flashGetVar ( ' SH_JS_INTER' ) ) ) shRepor (shResult) ; if ( (shResult=flashGetVar ( ' SH_JS_FINISH' ) ) )
{ shFinishO ,-
if ( (shResult=flashGetVar ( 'SH_JS_REPLAY' ) ) )
{ shView() ,- shReplayO ;
/* El codigo para restartear el Shoshkele. */
} setTimeout ( " shCo mand () ",200) ; } function getobj (theTags, theWidth, theHeight, thePos) {theTags=theTags . toUpperCase ( ) .spli t(' , ') ,-var laImageCount=0, losObj etos, thelmage=false,- for (var shA=0 ; shA<theTags . length; shA++) {losObjetos=theTags [shA] ==" IMG" ?shFrameObject . document . images : shFrameObject . document .getElementsByTagName?shFrameObject .d ocument .getElementsByTagName (theTags [shA] ) : shFrameObj ect . document . all . tags?s hFrameObject .document .all. tags (theTags [shA] ) :false,-if (losObjetos) {for (var shl=0; shl<losObj etos. length,-shI++) {if ( (losObjetos [shl] .width==theWidth--£-losO bjetos [shl] . eight==theHeight | | losObjetos [shl] .offsetWidth==theWidth--&losObj etos [shl] .offsetHeight==theHeight) ----++laImageCount==thePos) {thelmage=los0bje tos [shl] ;break;} } laImageCount=0 ; if (thelmage) break; } } return thelmage;} function shDisableOtherAds 0 {var shObjects=shFrameObject . document . all . tags ( "OBJECT" ) , shObj Id; for (var shl=0 ;shI<shObjects . length;shl++) {shObjId=shObjects . item(shl) . id. toLowerCase () ;if (shObj Id. mdexOf { 'ebfloating' ) !=-l| | shObj Id. mdexOf ( ' cm8 ' ) !=- l| I shObj Id. indexOf ( 'orange' ) !=-l) shObjects. item (shl) . style.display= 'none' ; } } /*********** ******************************* **** * ********** *** ********** **** *
**** function shPlayShoshkele ( ) //jsOnloadTemp shObjeto = getObj ("IMG, IFRAME, OBJECT", 120, 600,1) ; if (shObjeto)
{ shReposition ( ) ,- window. setTimeout ( 'shViewO ',100) ; shLandingSpot ( ) ; }
}
// [STEP 2]
//
// Write the flash on the same page in which the tag was implemented although this may not be visible for being hidden. Also, write the necessary functions in order to communicate flash to js.
//
// The same page in which the tag was implemented can be "within an IFRAME" .
En that case, the flash will be loaded with the only intention of pre-load. //
/*jsAlone*/ document.write (shFlashObj ()+' <SCRIPT LANGUAGE= "VBScript ">Function flashGetVar (ByVal shFlashVarName) \nOn Error Resume
Next\nflashGetVar=shFrameObject .document .all . sh_all_anim. GetVariable (shFlash VarName) \nlf flashGetVar Then shFrameObject .document .all . sh_all_anim. SetVariable shFlashVarName, ""\nEnd Function<\/SCRIPT>' ) ;
// [STEP 3]
//
// shCreate is the initial function. This function will be shoot as soon as the page ends loading.
// // This is defined on the prior timeline
// function shCreate ( ) { if ( (shFrameObject .document . readyState==" complete" ) &&! shFrameObj ect . sh FramePointer)
{ shFrameObject . shFrameObject=window; shFrameObject . shFramePointer=window; var shScriptString=window. shReposition? 'window . siteResize=window. onresize ,-window . onresize=shFramePointer. shReposition; ' : ' ' ; shScriptString+=window. shScroll? ' indow.onscroll=shFramePointer . shScr
Oil; ' : ' ' ;
// [STEP 4] If the implementation was made by IFRAME, then writes the flash again and the necessary code for the communication, but this time on the top page (in which the Shoshkele appears) // if (window. thelndex)
{ if (shPosType !="fixed") shScriptString+=overwriteEvents+ ' overwriteEvents () ,- ' ; shFrameObject .document .body. insertAdjacentHTML ( ' afterBegin' , shFlashOb j ( ) + ' <SPAN STYLE= "display: none" >OLAF<SCRIPT DEFER> ' +shScriptString+ ' <\/SCRIPTx\/SPAN> ' ) ;
} else { eval (shScriptString) ,- }
// // [Step 5]
// communication betv/een Flash and JS initializes. /'/ flash shows.
window. setTimeout ( "window. sh_all_anim=shFrameObject .document .all . sh_a ll_anim; ",100) ; window. setTimeout ( "if (window. ShDisableOtherAds) window. shDisableOtherAds () ; shCommand( ) ,- shPlayShoshkele 0 ,-",500) ,- else setTimeout (' shCreate () ' ,100) ,-
}
// End of timeline

Claims

What Is Claimed:
1. A method for producing a signal to control characteristics, including the position, size and appearance of a multimedia object to be placed over an image to be displayed by a client computer system running an application program and connected to a network, the image to be received via the application program from a content server connected to the network, the object to be received over the network separately from the image after the image is displayed, the method comprising the steps of: to a user's computer system downloading, from an application server connected to the network, a first signal producing on a display of the user's computer system, a representation of the image with a representation of the object overlying the image, and a second signal comprising executable code designed to produce, on the display, control elements actuable by the user to adjust characteristics ofthe object, including the position, size and appearance ofthe object; sensing the user's actuations ofthe control elements; and storing a control signal representing a plurality of the user's actuations ofthe control elements.
2. The method of claim 1, wherein the application program is a browser, and the image is part of the content displayed on a client computer browser page, the user's computer system running a browser and the first and second signals, being received in the browser.
3. The method of any preceding claim, wherein the object constitutes advertising material.
4. The method of any preceding claim, wherein the control signal is used to generate a timeline signal representing temporal and spatial characteristics of the object to be placed over the image, the timeline signal being subsequently provided to the client computer along with the multimedia object.
5. The method of any preceding claim, wherein one of the control elements is effective to anchor the object's position relative to a selected portion of the image.
6. The method of any preceding claim, wherein one of the control elements is effective to modify or hide a selected portion ofthe image.
7. The method of any preceding claim, wherein one of the control elements is effective to adjust the object's size relative to a selected portion of the image.
8. The method of any preceding claim, wherein one of the control elements is effective to adjust the object's size or position by operations performed with a pointing device.
9. The method of any preceding claim, wherein the control elements are constructed to create a toolbar.
10. The method of any preceding claim, wherein the control elements are constructed to create a menu or a system of linked menus.
11. The method of any preceding claim utilized in an operating system providing multilayered windows, the object being produced in the window of the image on a layer above any layer ofthe image.
12. The method according to any preceding claim, wherein a portion of the object is transparent, so that a portion of the image can be seen therethrough.
13. The method according to claim 12, wherein the transparent portion of the object is indicated by indicia appearing in the display of the user's computer system, representing to the user the portion of the object which is transparent.
PCT/US2004/003103 2003-02-03 2004-02-03 Method for laying out multimedia advertisements WO2004070579A2 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
US44444303P 2003-02-03 2003-02-03
US60/444,443 2003-02-03

Publications (2)

Publication Number Publication Date
WO2004070579A2 true WO2004070579A2 (en) 2004-08-19
WO2004070579A3 WO2004070579A3 (en) 2004-12-09

Family

ID=32850862

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/US2004/003103 WO2004070579A2 (en) 2003-02-03 2004-02-03 Method for laying out multimedia advertisements

Country Status (1)

Country Link
WO (1) WO2004070579A2 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2007064656A2 (en) 2005-11-29 2007-06-07 Google Inc. Formatting a user network site based on user preferences and format performance data
CN102378049A (en) * 2010-08-19 2012-03-14 中兴保全股份有限公司 Intelligent network television playing platform

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020194070A1 (en) * 1999-12-06 2002-12-19 Totham Geoffrey Hamilton Placing advertisement in publications

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020194070A1 (en) * 1999-12-06 2002-12-19 Totham Geoffrey Hamilton Placing advertisement in publications

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
'Ad4ever Announces 25% CTR for Interactive Online Advertising Campaign' AD4EVER 20 March 2001, page 1, XP002903158 *

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2007064656A2 (en) 2005-11-29 2007-06-07 Google Inc. Formatting a user network site based on user preferences and format performance data
EP1960864A2 (en) * 2005-11-29 2008-08-27 Google, Inc. Formatting a user network site based on user preferences and format performance data
EP1960864A4 (en) * 2005-11-29 2010-01-20 Google Inc Formatting a user network site based on user preferences and format performance data
US9703886B2 (en) 2005-11-29 2017-07-11 Google Inc. Formatting a user network site based on user preferences and format performance data
CN102378049A (en) * 2010-08-19 2012-03-14 中兴保全股份有限公司 Intelligent network television playing platform

Also Published As

Publication number Publication date
WO2004070579A3 (en) 2004-12-09

Similar Documents

Publication Publication Date Title
US11010538B2 (en) Systems and methods for hosted applications
US8504929B2 (en) Editing user interface components
US9514235B2 (en) Web page authoring tool for structured documents
US8667415B2 (en) Web widgets
US7293034B2 (en) Dynamically customizing a user interface for the aggregation of content
US10152732B2 (en) Methods, systems, and apparatus to design online advertising units via a web-based application
US10084878B2 (en) Systems and methods for hosted application marketplaces
US20020156815A1 (en) Method and apparatus for the separation of web layout, logic, and data when used in server-side scripting languages
US20070162842A1 (en) Selective content imaging for web pages
WO1997027553A1 (en) Distributed electronic publishing system
US20140068421A1 (en) Systems and methods for tracking and updating hosted applications
WO2009001166A1 (en) Method to generate a software part of a web page and such software part
US20080195949A1 (en) Rendition of a content editor
WO2010118129A1 (en) A device and method for creating, distributing, managing and monetizing widgets using templates
Neumann Web mapping and web cartography
JP2001084212A (en) Method for preparing homepage
WO2004070579A2 (en) Method for laying out multimedia advertisements
JP2010015292A (en) Emphasis display addition method, display control program and server
CN112084750A (en) Sticker processing method and device, electronic equipment and storage medium
Rahmel Advanced joomla!
WO2003005184A2 (en) Web windowed graphical user interface
KR20030006451A (en) Method for generating web page by user mode
Wagner Beginning IOS Application Development with HTML and JavaScript
Lydford Working with Images and Video
Ayesh et al. Dynamic HTML and Style Sheets

Legal Events

Date Code Title Description
AK Designated states

Kind code of ref document: A2

Designated state(s): AE AG AL AM AT AU AZ BA BB BG BR BW BY BZ CA CH CN CO CR CU CZ DE DK DM DZ EC EE EG ES FI GB GD GE GH GM HR HU ID IL IN IS JP KE KG KP KR KZ LC LK LR LS LT LU LV MA MD MG MK MN MW MX MZ NA NI NO NZ OM PG PH PL PT RO RU SC SD SE SG SK SL SY TJ TM TN TR TT TZ UA UG US UZ VC VN YU ZA ZM ZW

AL Designated countries for regional patents

Kind code of ref document: A2

Designated state(s): BW GH GM KE LS MW MZ SD SL SZ TZ UG ZM ZW AM AZ BY KG KZ MD RU TJ TM AT BE BG CH CY CZ DE DK EE ES FI FR GB GR HU IE IT LU MC NL PT RO SE SI SK TR BF BJ CF CG CI CM GA GN GQ GW ML MR NE SN TD TG

121 Ep: the epo has been informed by wipo that ep was designated in this application
WWE Wipo information: entry into national phase

Ref document number: 2431/DELNP/2006

Country of ref document: IN

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 69(1) EPC DATED 01-02-2006.

122 Ep: pct application non-entry in european phase