Spudhead
12-13-2003, 05:29 PM
Well, it's actually two questions. But they're kinda related.
Anyway - I stuck this in here, I dunno how many Flash heads we get in here or if any of youse are into your ActionScripting, but I'm an ASP coder who's suddenly found himself needing to build a Flash shopping cart. :confused:
I've found a couple of references, and... well, it's ugly as hell but it's kinda like javascript, innit?
So - question one; string concatenation. IS the concatenation operator "+", same as javascript? ie:
var1="hello";
var2="world";
var3=var1+" "+var2;
Next question - variable name concatenation. I'm not sure how to describe this.... it's like eval() I guess...
OK, I've got some stuff coming in via the querystring. Let's say it looks like this:
ts1=MensTShirt&ts1_size=XL&ts1_color=red&ts2=LadiesTShirt&ts2_size=M&ts2_color=blue
The pattern there is fairly clear. Each tshirt has a name, size and color. But it could have any number of tshirts in.
I want to loop through the querystring, getting values out. Like:
for (i=1;i<someNumberIllWorkOutWhenIGetThere;i++){
myTshirtName=ts+i;
myTshirtSize=ts+i+"_size";
myTshirtColor=ts+i"_color";
}
Now I hope that want I want the code to do is clear: drop whatever value is contained in "ts1" (or ts2, or ts3, or tsn) into the variable "myTshirtName". But what I'm likely to get, I think, is either myshirtName="ts1", or an error.
And, uh, a third question.... is there anywhere out there that does the job of SoYou'reAnASPDeveloperWhoNeedsToStartMessingAboutWithActionscript.com
?
Thanks guys.
Anyway - I stuck this in here, I dunno how many Flash heads we get in here or if any of youse are into your ActionScripting, but I'm an ASP coder who's suddenly found himself needing to build a Flash shopping cart. :confused:
I've found a couple of references, and... well, it's ugly as hell but it's kinda like javascript, innit?
So - question one; string concatenation. IS the concatenation operator "+", same as javascript? ie:
var1="hello";
var2="world";
var3=var1+" "+var2;
Next question - variable name concatenation. I'm not sure how to describe this.... it's like eval() I guess...
OK, I've got some stuff coming in via the querystring. Let's say it looks like this:
ts1=MensTShirt&ts1_size=XL&ts1_color=red&ts2=LadiesTShirt&ts2_size=M&ts2_color=blue
The pattern there is fairly clear. Each tshirt has a name, size and color. But it could have any number of tshirts in.
I want to loop through the querystring, getting values out. Like:
for (i=1;i<someNumberIllWorkOutWhenIGetThere;i++){
myTshirtName=ts+i;
myTshirtSize=ts+i+"_size";
myTshirtColor=ts+i"_color";
}
Now I hope that want I want the code to do is clear: drop whatever value is contained in "ts1" (or ts2, or ts3, or tsn) into the variable "myTshirtName". But what I'm likely to get, I think, is either myshirtName="ts1", or an error.
And, uh, a third question.... is there anywhere out there that does the job of SoYou'reAnASPDeveloperWhoNeedsToStartMessingAboutWithActionscript.com
?
Thanks guys.