hey everybody,
i have a problem with a website that i got from a customer, which i sould update now.
i didnt code it only get all the files.
the menu of the website is driven by a xml file. the buttonnames are importet from the xml file. when i include a forwardslash (/) to the label (WE/US) for the buttonname the button do not work, if remove the forwardslash (WE US) the button works.
i try to use “/ ;” but it didnt work.
does someone has a tip for me.
ps. sorry for my bad english;(
XML File:
<?xml version="1.0" encoding="UTF-8"?>
<menuPrimary id="1" url_config="xml/configuration_menu_tree.xml">
<item id="7" label=" HOME" background="" template="text" xml="xml/home.xml"/>
<item id="8" label=" WE/US" background="" template="text" xml="xml/we_us.xml">
<item id="9" label=" WHO WE ARE" background="" template="text" xml="xml/who_we_are.xml"/>
<item id="100" label=" SERVICE" background="" template="text" xml="xml/service.xml"/>
<item id="101" label= " HISTORY" background="" template="text" xml="xml/history.xml"/>
</item>
<item id="1002" label=" COLLECTION" background="" template="carousel" xml="xml/coll_1.xml">
<item id="1637" visible="false" label=" Barco" background="" template="text" xml="xml/coll_2.xml"/>
<item id="1638" visible="false" label=" Trinit" background="" template="text" xml="xml/coll_3.xml"/>
</item>
<item id="45" label=" CONTACT" background="" template="book" xml="xml/contact.xml"/>
</menuPrimary>
And the AS-Code for the Menu
import factory.Swf;
import menu_tree.mvctemplate.TreeModel;
//import ModolSubmenu.mvcsubmenu.SubMenuModel;
import templateLoader.mvctemplate.*
import templateLoader.mvc.*
import templateLoader.I.*
import flash.display.BitmapData
import templateLoader.util.Observable
import mx.transitions.Tween
import mx.transitions.easing.*
import LuminicBox.Log.*;
class templateLoader.mvctemplate.MenuPrimaryView extends AbstractView {
var __date:XMLNode
var __container:MovieClip
var __containerBig:MovieClip
var __xml:XML
var backgroundMenu:MovieClip
var __onlyFirst
var xml_config:XML
var __shov:Boolean=false
var __inter_hide:Number
var __menu:TreeModel
var __interMenu:Number
var __menuY:Number = 0
private var currentSwapDepth:Number=20
var containerLogo:MovieClip
var spaceVisible:Number
var firstOverMenu:Boolean = false
var align:Number /// if align==1 it is left , if align==-1 it is right align
var footerHeight
///////////////////////////////////////////////////////////////////////
public function defaultController (model:Observable):Controller {
return new MenuPrimaryController(model)
}
//////////////////////////////////////////////////////////////////////////
function MenuPrimaryView() {
spaceVisible=Number(ConfigurationSite.SPACE_VISIBLE)
align=(ConfigurationSite.ALIGN_MENU=="left") ? 1 : -1
this.__container = this.createEmptyMovieClip("mcContainerMenu", 1).createEmptyMovieClip("mc", 1)
containerLogo = this.__container._parent.createEmptyMovieClip("mcContainerLogo", 1243123)
this.__container._parent._x=-__containerBig._width + spaceVisible
}
////////////////////////////////////////////////////////////
function get xml():XML{
return this.__xml
}
/////////////////////////////////////////////////////////////////
function set xml(xml_:XML){
this.__xml=xml_
}
////////////////////////////////////////////////////////////
private function onIntroEnd() {
var m:LoaderModel=LoaderModel(this.getModel())
__xml=m.menuPrimary
if (!__onlyFirst && this.__xml.firstChild.childNodes.length) {
clearInterval(__interMenu)
__interMenu=setInterval(this,'loadMenu',0)
__onlyFirst=1
}
}
//////////////////////load menu module/////////////////////////////////////////////////////////////////
private function loadMenu() {
///trace("loadMenu!")
clearInterval(__interMenu)
var m:LoaderModel=LoaderModel(this.getModel())
__containerBig = this.__container._parent
__containerBig._y=0//-120
__container._x=0
__container._y=0
var loader:MovieClipLoader=new MovieClipLoader()
loader.addListener(this)
var swf:Swf=new Swf()
loader.loadClip(swf.getSwf("menuPrimary"),__container)
}
////////////////////////////////////////////////////////////
private function onLoad() {
var m:LoaderModel = LoaderModel(this.getModel())
footerHeight = m.heightContent()
////currentSwapDepth=this.getDepth()
swapDepths(currentSwapDepth)
}
////////////////////////////////////////////////////////////
private function onResize() {
var m:LoaderModel = LoaderModel(this.getModel())
__menu.height=getHeightMenu()
if (align == 1) {
this._x = 0
}else {
this._x = m.width
}
this._y = Number(ConfigurationSite.MARGIN_VERTICAL_MENU_UP)
}
/////////////////////////////////////////////////////////////////
function getHeightMenu():Number {
var m:LoaderModel = LoaderModel(this.getModel())
var value:Number = ( m.__footerHeightHide )
////return 300;
if(ConfigurationSite.FOOTER_VISIBLE=="true"){
return (m.height - value)- ( Number(ConfigurationSite.MARGIN_VERTICAL_MENU_UP)+Number(ConfigurationSite.MARGIN_VERTICAL_MENU_DOWN))
//return
}else {
return m.height-ConfigurationSite.MARGIN_VERTICAL_MENU
}
}
//////////////////////////////load configuration menu//////////////
private function loadConfigMenu(url_){
xml_config=new XML()
xml_config.ignoreWhite=true
xml_config.load(url_)
xml_config.onLoad=Delegate2.create(this,this.onLoadConfig)
}
////////////////////on laod config menu////////////////////////////
private function onLoadConfig() {
var m:LoaderModel = LoaderModel(this.getModel())
__menu = __container.ini(this.__xml, xml_config)
__menu.alignTitle = (align == -1) ? "left" : "right"
__menu.alignScroll=(align == 1) ? "left" : "right"
__menu.addEventListener("onPressRow", this)
__menu.addEventListener("onIntroStartMenu", this)
__menu.addEventListener("onExitEndMenu",this)
__menu.height = getHeightMenu()
if(align==1){
__containerBig._x = -__containerBig._width
}else {
__containerBig._x = __containerBig._width
}
onResize()
//////first shov
//if(ConfigurationSite.VISIBLE_MENU_START=="true"){
///shov(.5)
///}else{
//hide()
//}
shov()
m.__target.__footer.show(.5)
///clearInterval(__inter_hide)
//__inter_hide=setInterval(this,'hide_delay',4000)
onChangedPositionMenu()
m.dispatchEvent( { target:this, type:"onLoadMenuTree" } )
}
////////////
private function onIntroStartMenu() {
//this.swapDepths(324329244)
}
////////
private function onExitEndMenu() {
///this.swapDepths(currentSwapDepth)
}
/////////////////////////////////////////////////////////////////////////////////////////////////////////
private function hide_delay() {
clearInterval(__inter_hide)
if(!i****Test()){
hide()
}
}
/////////////////////on load menu module//////////////////////////////////////////////////////////////////
private function onLoadInit(target:MovieClip) {
loadConfigMenu(this.__xml.firstChild.attributes.url_config) ///load config menu
}
///////////////// events module //////////////////////////////////////////////////////
private function onPressRow(obj) {
var m:LoaderModel=LoaderModel(this.getModel())
var target:MovieClip= obj.target;
var node:XMLNode = target.node
m.setSelectedId(Number(node.attributes.id))
}
///////////////////////////////////////////////////////////////////////////////////////////
private function onChangedPositionMenu(){
var m:LoaderModel=LoaderModel(this.getModel())
var id:Number = m.currentNode.attributes.id
__menu.removeEventListener("onPressRow", this)
__menu.setSelectedId(id)
__menu.addEventListener("onPressRow", this)
//if(!__menu.__target.__target.hitTest(_root._xmouse,_root._ymouse,true)){
//__menu.__target.__menuSubItem.zjazdStart(true)
//}
}
///////////////////////////////////////////////////////////////////////////////////////////
private function shov(delay_) {
__shov = true
var delay = (delay_ == undefined) ? 0 : delay_
__containerBig.stopTween()
if(align==1){
var newX:Number = 0
}else {
var newX:Number = -__container._width
}
__containerBig.tween('_x', newX, 1, 'easeInOutCubic', delay)
__containerBig._alpha=0
__containerBig.tween('_alpha',100,1, 'easeInOutCubic', delay)
///this.swapDepths(324329244)
}
///////////////////////////////////////////////////////////////////////////////////////////
private function hide() {
__shov = false
__containerBig.stopTween()
if(align==1){
var newX:Number = -__menu.width+spaceVisible///-__container._width + spaceVisible
}else {
var newX:Number = - spaceVisible
}
__containerBig.tween('_x',newX, .3, 'easeInOutCubic',0,{scope:this,func:hide_end})
}
///////////////////////////////////////////////////////////////////////////////////////////
private function hide_end() {
this.swapDepths(currentSwapDepth)
}
///////////////////////////////////////////////////////////////////////////////////////////
private function ___onMouseMove() {
if (i****Test()) {
firstOverMenu=true
if(__shov==false){
//this.shov()
}
}else if(!i****Test()) {
if(__shov==true&&firstOverMenu==true){
///this.hide()
}
}
}
///////////////////////////////////////////////////////////////////////////////////////////
private function mask() {
var m:LoaderModel=LoaderModel(this.getModel())
var mcMask:MovieClip = this.createEmptyMovieClip("mcMaskClip", 435435)
Drawing.rectangle(mcMask, 0, -30, 500, m.height + 30, ["0xFF0000", 50])
this.setMask(mcMask)
}
///////////////////////////////////////////////////////////////////////////////////////////
private function i****Test() {
return this.__containerBig.hitTest(_root._xmouse, _root._ymouse, true)
}
///////////////////////////////////////////////////////////////////////////////////////////
}
SWFAdresss
/**
* SWFAddress 2.4: Deep linking for Flash and Ajax <http://www.asual.com/swfaddress/>
*
* SWFAddress is (c) 2006-2009 Rostislav Hristov and contributors
* This software is released under the MIT License <http://www.opensource.org/licenses/mit-license.php>
*
*/
/**
* @author Rostislav Hristov <http://www.asual.com>
* @author Ma Bingyao <andot@ujn.edu.cn>
*/
_global.SWFAddress = function(){
this._init = false;
this._initChange = false;
this._initChanged = false;
this._queue = new Array();
this._strict = true;
this._value = '';
this._availability = flash.external.ExternalInterface.available;
this._check = function() {
if (typeof SWFAddress.onInit == 'function' && !_init) {
SWFAddress._setValueInit(this._getValue());
SWFAddress._init = true;
}
if (typeof SWFAddress.onChange == 'function' ||
typeof SWFAddress.onExtenalChange == 'function') {
clearInterval(this._interval);
SWFAddress._init = true;
SWFAddress._setValueInit(this._getValue());
}
}
this._strictCheck = function(value, force) {
if (SWFAddress.getStrict()) {
if (force) {
if (value.substr(0, 1) != '/') value = '/' + value;
} else {
if (value == '') value = '/';
}
}
return value;
}
this._getValue = function() {
var value, ids = 'null';
if (this._availability) {
value = String(flash.external.ExternalInterface.call('SWFAddress.getValue'));
ids = String(flash.external.ExternalInterface.call('SWFAddress.getIds'));
}
if (ids == 'undefined' || ids == 'null' || !this._availability || this._initChange) {
value = this._value;
} else if (value == undefined || value == 'undefined' || value == 'null') {
value = '';
}
return SWFAddress._strictCheck(value || '', false);
}
this._setValueInit = function(value) {
SWFAddress._value = value;
if (!this._init) {
SWFAddress._dispatchEvent('init');
} else {
SWFAddress._dispatchEvent('change');
SWFAddress._dispatchEvent('externalChange');
}
SWFAddress._initChange = true;
}
this._setValue = function(value) {
if (value == 'undefined' || value == 'null') value = '';
if (SWFAddress._value == value && SWFAddress._init) return;
if (!SWFAddress._initChange) return;
SWFAddress._value = value;
if (!this._init) {
SWFAddress._init = true;
if (typeof SWFAddress.onInit == 'function') SWFAddress.onInit();
}
SWFAddress._dispatchEvent('change');
SWFAddress._dispatchEvent('externalChange');
}
this._dispatchEvent = function(type) {
type = type.substr(0, 1).toUpperCase() + type.substring(1);
if (typeof SWFAddress['on' + type] == 'function') {
SWFAddress['on' + type]();
}
}
this._callQueue = function() {
if (this._queue.length != 0) {
var script = '';
for (var i = 0, obj; obj = this._queue*; i++) {
if (typeof obj.param == 'string') obj.param = '"' + SWFAddress.encodeURI(SWFAddress.decodeURI(String(obj.param))) + '"';
script += obj.fn + '(' + obj.param + ');';
}
this._queue = new Array();
getURL('javascript:' + script + 'void(0);');
} else {
clearInterval(this._queueInterval);
}
}
this._call = function(fn, param) {
if (typeof param == 'undefined') param = '';
if (this._availability) {
if (System.capabilities.os.indexOf('Mac') != -1) {
if (this._queue.length == 0) {
this._queueInterval = setInterval(this, '_callQueue', 10);
}
this._queue.push({fn: fn, param: param});
} else {
flash.external.ExternalInterface.call(fn, param);
}
}
}
if (this._availability) {
try {
this._availability =
Boolean(flash.external.ExternalInterface.call('function() { return (typeof SWFAddress != "undefined"); }'));
flash.external.ExternalInterface.addCallback('getSWFAddressValue', this,
function(){return SWFAddress.getValue();});
flash.external.ExternalInterface.addCallback('setSWFAddressValue', this,
function(value){SWFAddress._setValue(value);});
} catch (e) {
this._availability = false;
}
}
this._interval = setInterval(this, '_check', 10);
}
_global.SWFAddress = new SWFAddress();
SWFAddress.toString = function() {
return '[class SWFAddress]';
}
String.prototype.replace = function(pattern, replacement) {
return this.split(pattern).join(replacement);
}
var str = "/";
var newstr = str.replace("/", "/");
/**
* Ported from iecompat.js <http://www.coolcode.cn/?action=show&id=126>
*/
SWFAddress.encodeURI = function(str) {
var l = ['%00', '%01', '%02', '%03', '%04', '%05', '%06', '%07', '%08',
'%09', '%0A', '%0B', '%0C', '%0D', '%0E', '%0F', '%10',
'%11', '%12', '%13', '%14', '%15', '%16', '%17', '%18',
'%19', '%1A', '%1B', '%1C', '%1D', '%1E', '%1F', '%20',
'!', '%22', '#', '$', '%25', '&', '\'', '(', ')', '*',
'+', ',', '-', '.', '/' , '0', '1', '2', '3', '4', '5',
'6', '7', '8', '9', ':', ';', '%3C', '=', '%3E', '?',
'@', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J',
'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U',
'V', 'W', 'X', 'Y', 'Z', '%5B', '%5C', '%5D', '%5E', '_',
'%60', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j',
'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u',
'v', 'w', 'x', 'y', 'z', '%7B', '%7C', '%7D', '~', '%7F'];
var out = [], i, j, len = str.length, c, c2;
for (i = 0, j = 0; i < len; i++) {
c = str.charCodeAt(i);
if (c <= 0x007F) {
out[j++] = l[c];
continue;
} else if (c <= 0x7FF) {
out[j++] = '%' + (0xC0 | ((c >> 6) & 0x1F)).toString(16).toUpperCase();
out[j++] = '%' + (0x80 | (c & 0x3F)).toString(16).toUpperCase();
continue;
} else if (c < 0xD800 || c > 0xDFFF) {
out[j++] = '%' + (0xE0 | ((c >> 12) & 0x0F)).toString(16).toUpperCase();
out[j++] = '%' + (0x80 | ((c >> 6) & 0x3F)).toString(16).toUpperCase();
out[j++] = '%' + (0x80 | (c & 0x3F)).toString(16).toUpperCase();
continue;
} else {
if (++i < len) {
c2 = str.charCodeAt(i);
if (c <= 0xDBFF && 0xDC00 <= c2 && c2 <= 0xDFFF) {
c = ((c & 0x03FF) << 10 | (c2 & 0x03FF)) + 0x010000;
if (0x010000 <= c && c <= 0x10FFFF) {
out[j++] = '%' + (0xF0 | ((c >>> 18) & 0x3F)).toString(16).toUpperCase();
out[j++] = '%' + (0x80 | ((c >>> 12) & 0x3F)).toString(16).toUpperCase();
out[j++] = '%' + (0x80 | ((c >>> 6) & 0x3F)).toString(16).toUpperCase();
out[j++] = '%' + (0x80 | (c & 0x3F)).toString(16).toUpperCase();
continue;
}
}
}
}
return null;
}
return out.join('');
}
/**
* Ported from iecompat.js <http://www.coolcode.cn/?action=show&id=126>
*/
SWFAddress.decodeURI = function(str) {
var out = [], i = 0, j = 0, len = str.length;
var c, c2, c3, c4, s;
var checkcode = function (strcc, i2, i1) {
var d1 = strcc.charAt(i1),
d2 = strcc.charAt(i2);
if (isNaN(parseInt(d1, 16)) || isNaN(parseInt(d2, 16))) {
return null;
}
return parseInt(d1 + d2, 16);
}
var checkutf8 = function (strcu, i3, i2, i1) {
var ccu = strcu.charCodeAt(i1);
if (ccu == 37) {
if ((ccu = checkcode(strcu, i3, i2)) == null) return null;
}
if ((ccu >> 6) != 2) {
return null;
}
return ccu;
}
while(i < len) {
c = str.charCodeAt(i++);
if (c == 37) {
if ((c = checkcode(str, i++, i++)) == null) return null;
} else {
out[j++] = String.fromCharCode(c);
continue;
}
switch(c) {
case 35: case 36: case 38: case 43: case 44: case 47:
case 58: case 59: case 61: case 63: case 64: {
if (str.charCodeAt(i - 3) == 37) {
out[j++] = str.substr(i - 3, 3);
} else {
out[j++] = str.substr(i - 1, 1);
}
break;
}
default: {
switch (c >> 4) {
case 0: case 1: case 2: case 3: case 4: case 5: case 6: case 7: {
// 0xxxxxxx
out[j++] = String.fromCharCode(c);
break;
}
case 12: case 13: {
// 110x xxxx 10xx xxxx
if ((c2 = checkutf8(str, i++, i++, i++)) == null) return null;
out[j++] = String.fromCharCode(((c & 0x1F) << 6) | (c2 & 0x3F));
break;
}
case 14: {
// 1110 xxxx 10xx xxxx 10xx xxxx
if ((c2 = checkutf8(str, i++, i++, i++)) == null) return null;
if ((c3 = checkutf8(str, i++, i++, i++)) == null) return null;
out[j++] = String.fromCharCode(((c & 0x0F) << 12) |
((c2 & 0x3F) << 6) | ((c3 & 0x3F) << 0));
break;
}
default: {
switch (c & 0xf) {
case 0: case 1: case 2: case 3: case 4: case 5: case 6: case 7: {
// 1111 0xxx 10xx xxxx 10xx xxxx 10xx xxxx
if ((c2 = checkutf8(str, i++, i++, i++)) == null) return null;
if ((c3 = checkutf8(str, i++, i++, i++)) == null) return null;
if ((c4 = checkutf8(str, i++, i++, i++)) == null) return null;
s = ((c & 0x07) << 18) |
((c2 & 0x3f) << 12) |
((c3 & 0x3f) << 6) |
(c4 & 0x3f) - 0x10000;
if (0 <= s && s <= 0xfffff) {
out[j++] = String.fromCharCode(((s >>> 10) & 0x03ff) | 0xd800, (s & 0x03ff) | 0xdc00);
} else {
return null;
}
break;
}
default: {
return null;
}
}
}
}
}
}
}
return out.join('');
}
SWFAddress.back = function() {
this._call('SWFAddress.back');
}
SWFAddress.forward = function() {
this._call('SWFAddress.forward');
}
SWFAddress.up = function() {
var path:String = SWFAddress.getPath();
SWFAddress.setValue(path.substr(0, path.lastIndexOf('/', path.length - 2) + (path.substr(path.length - 1) == '/' ? 1 : 0)));
}
SWFAddress.go = function(delta) {
this._call('SWFAddress.go', delta);
}
SWFAddress.href = function(url, target) {
target = (typeof target != 'undefined') ? target : '_self';
if (this._availability && System.capabilities.playerType == 'ActiveX') {
flash.external.ExternalInterface.call('SWFAddress.href', url, target);
return;
}
getURL(url, target);
}
SWFAddress.popup = function(url, name, options, handler) {
name = (typeof name != 'undefined') ? name : 'popup';
options = (typeof options != 'undefined') ? options : '""';
handler = (typeof handler != 'undefined') ? handler : '';
if (this._availability && System.capabilities.playerType == 'ActiveX') {
flash.external.ExternalInterface.call('SWFAddress.popup', url, name, options, handler);
return;
}
getURL('javascript:popup=window.open("' + url + '","' + name + '",' + options + ');' + handler + ';void(0);');
}
SWFAddress.getBaseURL = function() {
var url = 'null';
if (this._availability)
url = String(flash.external.ExternalInterface.call('SWFAddress.getBaseURL'));
return (url == 'undefined' || url == 'null' || !this._availability) ? '' : url;
}
SWFAddress.getStrict = function() {
var strict = 'null';
if (this._availability)
strict = String(flash.external.ExternalInterface.call('SWFAddress.getStrict'));
return (strict == 'null' || strict == 'undefined') ? this._strict : (strict == 'true');
}
SWFAddress.setStrict = function(strict) {
this._call('SWFAddress.setStrict', strict);
this._strict = strict;
}
SWFAddress.getHistory = function() {
return (this._availability) ?
Boolean(flash.external.ExternalInterface.call('SWFAddress.getHistory')) : false;
}
SWFAddress.setHistory = function(history) {
this._call('SWFAddress.setHistory', history);
}
SWFAddress.getTracker = function() {
return (this._availability) ?
String(flash.external.ExternalInterface.call('SWFAddress.getTracker')) : '';
}
SWFAddress.setTracker = function(tracker) {
this._call('SWFAddress.setTracker', tracker);
}
SWFAddress.getTitle = function() {
var title = (this._availability) ?
String(flash.external.ExternalInterface.call('SWFAddress.getTitle')) : '';
if (title == 'undefined' || title == 'null') title = '';
return title;
}
SWFAddress.setTitle = function(title) {
this._call('SWFAddress.setTitle', title);
}
SWFAddress.getStatus = function() {
var status = (this._availability) ?
String(flash.external.ExternalInterface.call('SWFAddress.getStatus')) : '';
if (status == 'undefined' || status == 'null') status = '';
return status;
}
SWFAddress.setStatus = function(status) {
this._call('SWFAddress.setStatus', status);
}
SWFAddress.resetStatus = function() {
this._call('SWFAddress.resetStatus');
}
SWFAddress.getValue = function() {
return SWFAddress.decodeURI(SWFAddress._strictCheck(SWFAddress._value || '', false));
}
SWFAddress.setValue = function(value) {
if (value == 'undefined' || value == 'null') value = '';
value = SWFAddress.encodeURI(SWFAddress.decodeURI(value));
if (SWFAddress._value == value) return;
SWFAddress._value = value;
this._call('SWFAddress.setValue', value);
if (SWFAddress._init) {
SWFAddress._dispatchEvent('change');
SWFAddress._dispatchEvent('internalChange');
} else {
SWFAddress._initChanged = true;
}
}
SWFAddress.getPath = function() {
var value = SWFAddress.getValue();
if (value.indexOf('?') != -1) {
return value.split('?')[0];
} else if (value.indexOf('#') != -1) {
return value.split('#')[0];
} else {
return value;
}
}
SWFAddress.getPathNames = function() {
var path = SWFAddress.getPath();
var names = path.split('/');
if (path.substr(0, 1) == '/' || path.length == 0)
names.splice(0, 1);
if (path.substr(path.length - 1, 1) == '/')
names.splice(names.length - 1, 1);
return names;
}
SWFAddress.getQueryString = function() {
var value = SWFAddress.getValue();
var index = value.indexOf('?');
if (index != -1 && index < value.length) {
return value.substr(index + 1);
}
}
SWFAddress.getParameter = function(param) {
var value = SWFAddress.getValue();
var index = value.indexOf('?');
if (index != -1) {
value = value.substr(index + 1);
var params = value.split('&');
var p, i = params.length, r = [];
while(i--) {
p = params*.split('=');
if (p[0] == param) {
r.push(p[1]);
}
}
if (r.length != 0)
return r.length != 1 ? r : r[0];
}
}
SWFAddress.getParameterNames = function() {
var value = SWFAddress.getValue();
var index = value.indexOf('?');
var names = new Array();
if (index != -1) {
value = value.substr(index + 1);
if (value != '' && value.indexOf('=') != -1) {
var params = value.split('&');
var i = 0;
while(i < params.length) {
names.push(params*.split('=')[0]);
i++;
}
}
}
return names;
}