From b7a30542d9eba32194ba963c6612c670fb7fdf32 Mon Sep 17 00:00:00 2001 From: dave Date: Mon, 21 Sep 2009 07:48:54 +0000 Subject: [PATCH] - Pretty it up a bit --- admin/award_upload.php | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/admin/award_upload.php b/admin/award_upload.php index a1b2e798..5658033e 100644 --- a/admin/award_upload.php +++ b/admin/award_upload.php @@ -75,6 +75,7 @@ function get_winners($awardid) $award=mysql_fetch_assoc($q); $winners=array( 'prizes' => array(), + 'award_name' => $award['name'], 'external_identifier' => $award['external_identifier'], 'postback' => $award['external_postback']); @@ -143,7 +144,7 @@ case 'award_upload': $q = mysql_query("SELECT * FROM fairs WHERE id='{$a['award_source_fairs_id']}'"); $fair = mysql_fetch_assoc($q); - echo 'Award
'; + echo '
'; if($winners == false) { echo notice(i18n('No winners selected for this award')); } else { @@ -151,8 +152,8 @@ case 'award_upload': $req=array("awardwinners"=>array( "username"=>$fair['username'], "password"=>$fair['password'], - "identifier"=>$winners['external_identifier']; - "prizes"=>$winners; + "identifier"=>$winners['external_identifier'], + "prizes"=>$winners, ) ); $url = $winners['external_postback']; @@ -161,13 +162,17 @@ case 'award_upload': $req['award_upload']['year'] = $config['FAIRYEAR']; $url = ''; /* url is ignored for type = sfiab */ } + echo i18n("Sending %1 winners to %2...", array(''.$winners['award_name'].'', + ''.$fair['name'].'')); + echo '
'; $data = curl_query($fair, $req, $url); if($data['error'] != 0) { echo error("Server said: $data"); } else { - echo notice("Server Said: $data"); + echo notice("{$fair['name']} server said:
".join("\n", $data['notice'])."
"); + echo happy(i18n("Upload completed successfully")); } echo "
";
 		print_r($winners);