diff options
author | the_systech <the_systech@users.sourceforge.net> | 2002-03-01 18:04:27 +0000 |
---|---|---|
committer | the_systech <the_systech@users.sourceforge.net> | 2002-03-01 18:04:27 +0000 |
commit | 89ceaa9975343ebc0ce817d64ad62a282c11beb9 (patch) | |
tree | 9ef0742ee39c12aba8a3798a795575c7c3d443c5 | |
parent | ebef1197964061ae2f2eb17dce2061fad1df6a35 (diff) | |
download | forums-89ceaa9975343ebc0ce817d64ad62a282c11beb9.tar forums-89ceaa9975343ebc0ce817d64ad62a282c11beb9.tar.gz forums-89ceaa9975343ebc0ce817d64ad62a282c11beb9.tar.bz2 forums-89ceaa9975343ebc0ce817d64ad62a282c11beb9.tar.xz forums-89ceaa9975343ebc0ce817d64ad62a282c11beb9.zip |
Oops I did a Paul... Still allow avatar uploads from Urls
git-svn-id: file:///svn/phpbb/trunk@2243 89ea8834-ac86-4346-8a33-228a782c2dd0
-rw-r--r-- | phpBB/admin/admin_board.php | 8 | ||||
-rw-r--r-- | phpBB/admin/admin_users.php | 4 | ||||
-rw-r--r-- | phpBB/profile.php | 8 | ||||
-rw-r--r-- | phpBB/templates/subSilver/admin/board_config_body.tpl | 2 | ||||
-rw-r--r-- | phpBB/templates/subSilver/admin/user_edit_body.tpl | 2 | ||||
-rw-r--r-- | phpBB/templates/subSilver/profile_add_body.tpl | 2 |
6 files changed, 14 insertions, 12 deletions
diff --git a/phpBB/admin/admin_board.php b/phpBB/admin/admin_board.php index 2c55f5fc2c..714d1b05f0 100644 --- a/phpBB/admin/admin_board.php +++ b/phpBB/admin/admin_board.php @@ -122,14 +122,6 @@ $smtp_no = ( !$new['smtp_delivery'] ) ? "checked=\"checked\"" : ""; $template->set_filenames(array( "body" => "admin/board_config_body.tpl") ); -// -// Check to see if file uploads are possible before displaying -// avatar upload option. -// -if( (get_cfg_var('file_uploads') != 0) && (strtolower(get_cfg_var('file_uploads')) != 'off') && (phpversion() != '4.0.4pl1') ) -{ - $template->assign_block_vars('switch_uploads_possible', array()); -} // // Escape any quotes in the site description for proper display in the text diff --git a/phpBB/admin/admin_users.php b/phpBB/admin/admin_users.php index bbc9905fda..a9cf26b336 100644 --- a/phpBB/admin/admin_users.php +++ b/phpBB/admin/admin_users.php @@ -1107,6 +1107,10 @@ if( $mode == "edit" || $mode == "save" && ( isset($HTTP_POST_VARS['username']) | if( file_exists("./../" . $board_config['avatar_path']) ) { $template->assign_block_vars("avatarupload", array() ); + if($form_enctype != '') + { + $template->assign_block_vars('avatarupload.fileuploads', array() ); + } } if( file_exists("./../" . $board_config['avatar_gallery_path']) ) diff --git a/phpBB/profile.php b/phpBB/profile.php index b8e64e042e..74578fd6d6 100644 --- a/phpBB/profile.php +++ b/phpBB/profile.php @@ -1626,13 +1626,17 @@ if( isset($HTTP_GET_VARS['mode']) || isset($HTTP_POST_VARS['mode']) ) // of the templates to 'fake' an IF...ELSE...ENDIF solution // it works well :) // - if( $userdata['user_allowavatar'] && ( ($board_config['allow_avatar_upload'] && $form_enctype != '') || $board_config['allow_avatar_local'] || $board_config['allow_avatar_remote'] ) ) + if( $userdata['user_allowavatar'] && ( $board_config['allow_avatar_upload'] || $board_config['allow_avatar_local'] || $board_config['allow_avatar_remote'] ) ) { $template->assign_block_vars("avatarblock", array() ); - if($board_config['allow_avatar_upload'] && file_exists("./" . $board_config['avatar_path']) && $form_enctype != '') + if($board_config['allow_avatar_upload'] && file_exists("./" . $board_config['avatar_path'])) { $template->assign_block_vars("avatarblock.avatarupload", array() ); + if( $form_enctype != '' ) + { + $template->assign_block_vars("avatarblock.avatarupload.avatarfileupload", array() ); + } } if($board_config['allow_avatar_remote']) diff --git a/phpBB/templates/subSilver/admin/board_config_body.tpl b/phpBB/templates/subSilver/admin/board_config_body.tpl index 0447747cb6..e3739d49c4 100644 --- a/phpBB/templates/subSilver/admin/board_config_body.tpl +++ b/phpBB/templates/subSilver/admin/board_config_body.tpl @@ -178,12 +178,10 @@ <td class="row1">{L_ALLOW_REMOTE} <br /><span class="gensmall">{L_ALLOW_REMOTE_EXPLAIN}</span></td> <td class="row2"><input type="radio" name="allow_avatar_remote" value="1" {AVATARS_REMOTE_YES} /> {L_YES} <input type="radio" name="allow_avatar_remote" value="0" {AVATARS_REMOTE_NO} /> {L_NO}</td> </tr> - <!-- BEGIN switch_uploads_possible --> <tr> <td class="row1">{L_ALLOW_UPLOAD}</td> <td class="row2"><input type="radio" name="allow_avatar_upload" value="1" {AVATARS_UPLOAD_YES} /> {L_YES} <input type="radio" name="allow_avatar_upload" value="0" {AVATARS_UPLOAD_NO} /> {L_NO}</td> </tr> - <!-- END switch_uploads_possible --> <tr> <td class="row1">{L_MAX_FILESIZE}<br /><span class="gensmall">{L_MAX_FILESIZE_EXPLAIN}</span></td> <td class="row2"><input type="text" size="4" maxlength="10" name="avatar_filesize" value="{AVATAR_FILESIZE}" /> Bytes</td> diff --git a/phpBB/templates/subSilver/admin/user_edit_body.tpl b/phpBB/templates/subSilver/admin/user_edit_body.tpl index 1790582c98..d73f25d21c 100644 --- a/phpBB/templates/subSilver/admin/user_edit_body.tpl +++ b/phpBB/templates/subSilver/admin/user_edit_body.tpl @@ -223,6 +223,7 @@ </td> </tr> <!-- BEGIN avatarupload --> + <!-- BEGIN fileuploads --> <tr> <td class="row1"><span class="gen">{L_UPLOAD_AVATAR_FILE}</span></td> <td class="row2"> @@ -230,6 +231,7 @@ <input type="file" name="avatar" class="post" style="width: 200px" /> </td> </tr> + <!-- END fileuploads --> <tr> <td class="row1"><span class="gen">{L_UPLOAD_AVATAR_URL}</span></td> <td class="row2"> diff --git a/phpBB/templates/subSilver/profile_add_body.tpl b/phpBB/templates/subSilver/profile_add_body.tpl index 05ebadee9f..7c445a963f 100644 --- a/phpBB/templates/subSilver/profile_add_body.tpl +++ b/phpBB/templates/subSilver/profile_add_body.tpl @@ -232,6 +232,7 @@ </td> </tr> <!-- BEGIN avatarupload --> + <!-- BEGIN avatarfileupload --> <tr> <td class="row1"><span class="gen">{L_UPLOAD_AVATAR_FILE}:</span></td> <td class="row2"> @@ -239,6 +240,7 @@ <input type="file" name="avatar" class="post"style="width: 200px" /> </td> </tr> + <!-- END avatarfileupload --> <tr> <td class="row1"><span class="gen">{L_UPLOAD_AVATAR_URL}:</span><br /> <span class="gensmall">{L_UPLOAD_AVATAR_URL_EXPLAIN}</span></td> |