 
 					case "AGE":
 						break;
-
+					
+					//there is some ambiguity surrounding how vCard versions are handled
+					//so we need to check it here as well as looking for the attribute
+					//as above.  SEE:  http://xmpp.org/extensions/xep-0054.html#impl
+					case "VERSION":
+						version = Number(child.text());
+						break;
+						
 					default:
 						trace( "handleVCard. unhandled case child.name(): " + child.name() );
 						break;

		 *
		 */
		private var _avatar:DisplayObject;

		/**
		 *

				homeVoiceNode.NUMBER = homeVoiceNumber;
				vcardExtNode.appendChild( homeVoiceNode );
			}
			
			if ( avatar != null && _avatarType != null)
			{
				var avatarNode:XML = <PHOTO/>
				var avatarBase64:String;

				try
				{
					avatarBase64 = Base64.encodeByteArray(avatar);
				}
				catch(err:Error)
				{
					throw new Error("VCard:saveVCard Error encoding bytes " + err.getStackTrace());
				}
				
				try
				{
					var binaryNode:XML = <BINVAL/>;
					binaryNode.appendChild(avatarBase64);
					avatarNode.appendChild(binaryNode);
				}
				catch(err:Error)
				{
					throw new Error("VCard:saveVCard Error converting bytes to string " + err.message);
				}

				var typeNode:XML = <TYPE/>;
				typeNode.appendChild(_avatarType);
				avatarNode.appendChild(typeNode);
					
				vcardExtNode.appendChild( avatarNode );
			}

			iq.addExtension( vcardExt );
			connection.send( iq );
