Flash Vista - หนัาแรก
เว็บใหม่ล่าสุด
The Two Tales
เกี่บยวกับเว็บไซท์ | Archive
แนวิเกชั่นหลัก
หนัาแรก
ลิ้งค์มาใหม่
คะแนนสุดสุด
นิยมที่สุด
เลือกโดยบรรณาธิการ
ค้นหา

บทเรียนแฟลช
แหล่งข้อมูลแฟลช
ข่าว Flash
แฟลชเทมเพลท
แฟลชเทมเพลทอินโทร
Website Templates
แฟลชเกมส์
หนังสือแฟลช
FlashVista โพลส์
Sitemap


สุ่มลิงก์
English
Taig Chris - Ramp Warrior
เกี่บยวกับเว็บไซท์ | Get another
FlashVista
เข้าสู่ระบบ
สมัครเป็นสมาชิก
สมัครรับจดหมายข่าว

เพิ่มลิ้งค์
แก้ไขลิ้งค์
รายการโปรด
แนะนำหมวด

โฆษณากับเรา
สนับสนุนเรา
Credits / Thanks
ติดต่อกับเรา

Flash Templates:

More Templates ...

รับจดหมายข่าว
ผู้ใช้

รหัดผ่าน



สมัครเป็นสมาชิก
ลืมรหัสผ่าน?
Partner websites
Free Hit Counter
Free Seo Tools
Free Tutorials
Free Video Tutorials
Forum signatures
Best Free Scripts
Wii Fit
Wii Fit News
Cool Tech Gadgets
Other Resources
แนะนำ
แนะนำเวบนี้ให้เพื่อน


รับจดหมายข่าว
สถานะ: ไม่ได้เข้าสู่ระบบ

Thai English German French Spanish Italian Portuguese Russian Polish Finnish Dutch Swedish Thai Romanian Traditional Chinese Simplified Chinese
ค้นหาไม่ได้เข้าสู่ระบบ
คำค้น: สิ่งที่ค้นหา: ค้นหาแบบกำหนดเงื่อนไข


LoadVars.decode


NEW Flash Tutorials in Video Format - Powered by LearnFlash.com: 45 minutes of flash tutorials now available in streaming format or download. Topics Include flash for beginners, text effects, actionscripting, audio/video, flash 8 and more.


Printer version



by Guy Watson
www.flashguru.co.uk

Another hidden away feature of Flash MX, this time a method of the LoadVars object. This little method, is the method that the LoadVars object uses internally to decode your name/value pairs into object properties and values...

LoadVars.decode is inherited by all instances of the LoadVars object. The Method accepts one argument, the argument is a string that contains name/value pairs, that you wish to be converted into object properties and associated values. Name/value pairs look like this:
myvariable=value&myothervariable=anothervalue

This hidden method, will convert the above name/value pairs into two properties 'myvariable' and 'myothervariable', the values of these properties are the associated values in the name/value pair string, so the value of 'myvariable' in the above string is 'value' and the value of 'myothervariable' in the above string is 'anothervalue'. Heres a little code example to show you what this method does:


//create a new instance of the LoadVars object
myvars=new LoadVars()
//call the method with our name/value pair string
myvars.decode("name=Guy&age=18&icq=71063418")
//iterate over all the properties in the 'myvars' object
for(var i in myvars){
//trace the property name and property value
trace(i+":"+myvars[i])
}


The output of the above code is:


name:Guy
age:18
icq:71063418


This method has not yet been added to the Macromedia Flash MX Actionscript Dictionary Errata.

(เพิ่มไปแล้ว: 02-06-2004, ฮิต: 1, คะแนน: 2.86, โหวด: 7, คำวิจารณ์: 2)
เพิ่มในรายการโปรด แนะนำให้เพื่อน

คำวิจารณ์: (2)

Can this method be overridden so that you can send a string to the loadvars object that is formatted differently?
(เพิ่มไปแล้ว: 04-28-2006 ผู้ใช้: Guest)

wow this method is really great, maybe with this one we could make txt files dynamically !!!
(เพิ่มไปแล้ว: 02-14-2004 ผู้ใช้: Guest)


เขียนคำวิจารณ์
Please note:
We review EVERY comment before it appears on the site, so please dont waste your time by posting spam links :)
No URLs allowed, no HTML please.

If you register or login first, your review will contain your nickname


ให้คะแนน



ดีที่สุด
ดีมาก
ดี
พอได้
ไม่ดี,ไม่สมบูรณ์