Vale, a ver, que no me había fijado en algunas cosas.
Por lo visto, en ese código llamas dos veces al script php, lo cual creo que no es necesario al pasar el parámetro por get. Por lo que veo, tampoco sería necesaria la variable nombreFoto.
Debería quedar algo así:
Código :
var t:SharedObject = SharedObject.getLocal("user", "/");
function not_set_yet() {
t.flush();
}
if (t.data.id) {
nick = t.data.id;
}
System.security.allowDomain("http://www.ciberbluenet.com/ciber/");
import flash.net.FileReference;
// The listener object listens for FileReference events.
var listener:Object = new Object();
// When the user selects a file, the onSelect() method is called, and
// passed a reference to the FileReference object.
listener.onSelect = function(selectedFile:FileReference):Void {
//clean statusArea and details area
statusArea.text = details.text="";
// Flash is attempting to upload the image.
statusArea.text += "Attempting to upload "+t.data.id+"\n";
// Upload the file to the PHP script on the server.
selectedFile.upload("upload.php?nick="+t.data.id);
};
// the file is starting to upload.
listener.onOpen = function(selectedFile:FileReference):Void {
statusArea.text += "Uploading "+t.data.id+"\n";
};
//Possible file upload errors
listener.onHTTPError = function(file:FileReference, httpError:Number):Void {
imagePane.contentPath = "error";
imagePane.content.errorMSG.text = "HTTPError number: "+httpError+"\nFile: "+t.data.id;
};
listener.onIOError = function(file:FileReference):Void {
imagePane.contentPath = "error";
imagePane.content.errorMSG.text = "IOError: "+t.data.id;
};
listener.onSecurityError = function(file:FileReference, errorString:String):Void {
imagePane.contentPath = "error";
imagePane.content.errorMSG.text = "SecurityError: "+SecurityError+"\nFile: "+t.data.id;
};
// the file has uploaded
listener.onComplete = function(selectedFile:FileReference):Void {
// Notify the user that Flash is starting to download the image.
statusArea.text += "Upload finished.\nNow downloading "+t.data.id+" to player\n";
//Show file details
details.text = "";
for (i in selectedFile) {
details.text += "<b>"+i+":</b> "+selectedFile[i]+"\n";
}
// Call the custom downloadImage() function.
downloadImage(t.data.id);
};
var imageFile:FileReference = new FileReference();
imageFile.addListener(listener);
uploadBtn.onPress = uploadImage;
imagePane.addEventListener("complete", imageDownloaded);
// Call the uploadImage() function, opens a file browser dialog.
function uploadImage(event:Object):Void {
imageFile.browse([{description:"Image Files", extension:"*.jpg;*.gif;*.png"}]);
}
// If the image does not download, the event object's total property
// will equal -1. In that case, display am error message
function imageDownloaded(event:Object):Void {
if (event.total == -1) {
imagePane.contentPath = "error";
}
}
// show uploaded image in scrollPane
function downloadImage(file:Object):Void {
imagePane.contentPath = "./fotografias/"+file;
}
stop();
Y el php como está.
Creo que debería funcionar, pero no veo qué hace exactamente el sharedObjects y qué hacía el loadVars, así que igual sólo estamos dando palos de ciego.
Si no te funciona, habrá que esperar el consejo de alguien más sabio

Salu2