Unregistered Avatar

Reply

Hmm some help with buttons and saving


 
LinkBack Thread Tools Display Modes

  #1 (permalink)  

Old 07-09-2004, 06:43 PM

Hmm some help with buttons and saving

Ok, well I got a idea for a slidshow kinda of thing. and what I want is for it to be able to save dependant on each person.

this is my idea.
*I have 2 sigs; sig a and sig b

*sig a is the first sig.

*someone can click sig b and it saves.

*when someone comes to a new thred and sees the sig. they see sig b just as they set it.

*or if someone likes sig a more. they can leave it there. and that person sees sig a when they vist a page inwhitch the sig is on.

I hope that makes sence. kinda confusing... Anyways yeah I was wonder if there was any action skrips or something. kinda like a flash game where you can save and come back latter and it is still in the spot you left off.
__________________
(\ /)
(O.o) copy bunny into ur sig,
(u u) to help him rule the world.

UAGFX is offline registered.

Join Date: May 2004

Location: Plymouth, MI

Posts: 61

Send a message via AIM to UAGFX

  #2 (permalink)  

Old 07-11-2004, 02:21 PM

well.. you would need a forum that supports .swf on thier site.

once you found said forum, this is what you would need to do.

The breakdown:
You need to make an xml script that stores two variables. The ip address of the user, & the option they chose. This xml file will need to be stored on a remote server. Once you have completed your xml file would look somewhat like this:

Code:
<?xml version="1.0"?>
<mymenu>
<myitem sig="1" ip="192.168.1.3" />
<myitem sig="2" ip="192.168.1.2" />
</mymenu>
The nice thing about flash is that it has a built in xml parser. that means you dont need to use a dynamic page (asp, php) to communicate with the xml.

Okay, so now that you have your xml file, you need to load the xml variables via actionscript, and display the correct signature.

[as]
menuXml = new XML();
menuXml.ignoreWhite = true;
menuXml.onLoad = function() {
menuItem = menuXml.firstChild.childNodes;
for (var i=0; i<menuItem.length; i++) {
sig =menuItem[num].attributes.src);
Ip = menuItem[num].attributes.url;
};
}
menuXml.load("myMenu.xml");
[/as]

now that will load your two variables IP & Sig

you will need to get the ip adress of the user, either via php or ASp

PHP Code:
<?php echo $_SERVER['REMOTE_ADDR']; ?>
so you will need to create a php connection in asp. It may even serv you better to use a flat file (.txt) to store the variables and pass an array into flash via php.

either way your going to need to use php or asp to do this.

For your flash file, you'll have two keyframes. One will have sig one, with 2 buttons (gotoAndPlay("2"),www.yourwebserver.com/add.php)

And the 2nd frame will also have too buttons. save & gotoandplay(1). On both keyframes you will also have stop();

the 2nd button that adds will go directly to a php or asp page that adds the ip and passes the sig number to it. That way it will save it correctly.

missionsix is offline loves you.

missionsix's Avatar

Join Date: Feb 2004

Location: under you.

Posts: 4,790

Send a message via AIM to missionsix Send a message via MSN to missionsix
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


All times are GMT -7. The time now is 10:48 AM.