[xoops-cvslog 1842] CVS update: xoops2jp/html/modules/user/forms

Back to archive index

Minahito minah****@users*****
2006年 1月 19日 (木) 02:14:23 JST


Index: xoops2jp/html/modules/user/forms/AvatarUploadForm.class.php
diff -u xoops2jp/html/modules/user/forms/AvatarUploadForm.class.php:1.1.2.1 xoops2jp/html/modules/user/forms/AvatarUploadForm.class.php:1.1.2.2
--- xoops2jp/html/modules/user/forms/AvatarUploadForm.class.php:1.1.2.1	Wed Jan 18 22:09:51 2006
+++ xoops2jp/html/modules/user/forms/AvatarUploadForm.class.php	Thu Jan 19 02:14:23 2006
@@ -17,6 +17,7 @@
 		//
 		// Set form properties
 		//
+		$this->mFormProperties['uid'] =& new XCube_IntProperty('uid');
 		$this->mFormProperties['uploadavatar'] =& new XCube_ImageFileProperty('uploadavatar');
 
 		//
@@ -25,17 +26,20 @@
 		$this->mFieldProperties['uploadavatar'] =& new XCube_FieldProperty($this);
 		$this->mFieldProperties['uploadavatar']->setDependsByArray(array('extension'));
 		$this->mFieldProperties['uploadavatar']->addMessage('required', _MD_USER_ERROR_REQUIRED, _MD_USER_LANG_EMAIL);
-		$this->mFieldProperties['uploadavatar']->addVar('extension', jpg,gif,png);
+		$this->mFieldProperties['uploadavatar']->addVar('extension', "jpg,gif,png");
 	}
 
 	function load(&$obj)
 	{
-		$this->setVar('uploadavatar', $obj->get('uploadavatar'));
+		$this->setVar('uid', $obj->get('uid'));
 	}
 
 	function update(&$obj)
 	{
-		$obj->setVar('uploadavatar', $this->get('uploadavatar'));
+		$obj->setVar('uid', $this->get('uid'));
+		
+		$fileform = $this->get('uploadavatar');
+		$obj->setVar('uploadavatar', $this->get($fileform->getFileName()));	//< TODO
 	}
 }
 


xoops-cvslog メーリングリストの案内
Back to archive index