x
Yes
No
Do you want to visit DriveHQ English website?
首页
产品服务
价格
免费试用
下载客户端
关于我们
云文件服务
|
云备份服务
|
FTP服务
|
企业邮箱服务
|
网站托管
|
客户端软件
云文件服务
云备份服务
FTP服务
企业级邮箱服务
网站托管
客户端软件
admin_user.pl - Hosted on DriveHQ Cloud IT Platform
返回上层目录
上传
下载
共享
发布
新建文件夹
新建文件
复制
剪切
删除
粘贴
评论
升级服务
路径: \\LITTLELEV\ImageFolioLite\admin\admin_user.pl
旋转
特效
属性
历史版本
############################################################################### # BizDesign ImageFolio Lite Edition 4.2 (Four-dot-Two) ############################################################################### # # ## ### VERSION : 4.2 # #### ## ## RELEASED ON : 02/15/2007 # ## ## ## LAST MODIFIED : 02/15/2007 # ########## ## # ## ### ## # ## ### ######## # ############################################################################### # Released by BizDesign, Inc. # written by Dirk Koppers and Greg Raaum of BizDesign # # Purchasing : http://imagefolio.com/purchase/ # Support : http://imagefolio.com/support/ # Phone : (214) 642-9787 # Email : sales@bizdesign.com ############################################################################### # COPYRIGHT AND LICENSE INFORMATION : # # Copyright (c) 1999-2007 BizDesign, Inc. All rights reserved. # # Selling or distributing the code for this program without prior written # consent is expressly forbidden. # # One licensed copy of the program may reside on a single server, in use by a # single domain. For each installed instance of the program, a separate # license is required. # # Licensed users may alter or modify this software, at their own risk, of # course. They may also hire others to modify their own copy of the code, as # long as the code is not transferred to or retained by the individual who is # hired (unless he/she is also a license holder). Although license-holders # may modify the code for their use, modified code may NOT be resold or # distributed. # # THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND # FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BIZDESIGN, # INC. OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, # PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR # BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # # BizDesign, Inc. is not liable for any conduct associated with image gallery # activity, nor for any binary media posted using this program, including but # not imited to images, photographs, movies, and clipart. # # The user must assume the entire risk of using the program. Although this # program has been thoroughly tested on BizDesign's servers, BizDesign does not # warrant that it works on all servers and will not be held liable for anything, # including but not limited to, misusage, error, or loss of data. ANY # LIABILITY OF THE SELLER WILL BE LIMITED EXCLUSIVELY TO PRODUCT REPLACEMENT # OR REFUND OF PURCHASE PRICE. Use at your own risk! ############################################################################### # Do not modify below this line unless you know what you are doing. ############################################################################### ############################################################################### # MODIFY USER # Shows the modify a user form ############################################################################### sub modify_user { $MODIFYADMIN = "active"; if ($userstep eq "2") { &modify_user_step2; } elsif ($userstep eq "final") { &modify_user_final; } else { $pagetitle = "Modify Admin - Select Admin"; &get_header; &get_user_list; print qq|$comment
<$admin_big_font>
Select Admin
<$admin_big_font>
Step 1 of 2
$userlist
|; &get_footer; } } ############################################################################### # MODIFY USER STEP 2 # Shows a form to modify a single user's information ############################################################################### sub modify_user_step2 { $pagetitle = "Modify Admin"; &get_header; &get_user; if ($admin_demo_mode) { $iffirstname = "**********"; $iflastname = "**********"; $ifemail = "**********"; $ifusername = "**********"; $decryptpassword = "**********"; } print qq|
<$admin_big_font>
Modify Admin
<$admin_big_font>
Step 2 of 2
<$admin_small_font>
A D M I N I D E N T I T Y
<$admin_font>
First Name
<$admin_font>
Last Name
<$admin_font>
Email
<$admin_font>
Username
<$admin_font>
Password
<$admin_small_font>
A D M I N P E R M I S S I O N S
<$admin_font color="#ffffff">
Allow this administrator to...
<$admin_font color="#ffffff">
Yes
<$admin_font color="#ffffff">
No
<$admin_font>
Add IPTC File Info
?
|; if ($ifdesc_per eq "Yes") { print qq|
|; } else { print qq|
|; } print qq|
<$admin_font>
Upload Media
?
|; if ($ifupload_per eq "Yes") { print qq|
|; } else { print qq|
|; } print qq|
<$admin_font>
Add Categories
?
|; if ($ifaddcat_per eq "Yes") { print qq|
|; } else { print qq|
|; } print qq|
<$admin_font>
Rename Categories
?
|; if ($ifrencat_per eq "Yes") { print qq|
|; } else { print qq|
|; } print qq|
<$admin_font>
Delete Categories
?
|; if ($ifdelcat_per eq "Yes") { print qq|
|; } else { print qq|
|; } print qq|
<$admin_font>
Rebuild the Database/Index
?
|; if ($ifbuild_per eq "Yes") { print qq|
|; } else { print qq|
|; } print qq|
<$admin_font>
Add New Administrators/Groups/Users
?
|; if ($ifaddusr_per eq "Yes") { print qq|
|; } else { print qq|
|; } print qq|
<$admin_font>
Modify Other Administrators/Groups/Users
?
|; if ($ifmodusr_per eq "Yes") { print qq|
|; } else { print qq|
|; } print qq|
<$admin_font>
Delete Other Administrators/Groups/Users
?
|; if ($ifdelusr_per eq "Yes") { print qq|
|; } else { print qq|
|; } print qq|
<$admin_font color="#ffffff">
Use demontration/tutorial mode ?
<$admin_font color="#ffffff">
Yes
<$admin_font color="#ffffff">
No
<$admin_font>If set to "Yes" then this administrator has access to all functions above, but no changes are saved. Useful for showing colleagues/friends or educating employees.
|; if ($ifdemo_per eq "Yes") { print qq|
|; } else { print qq|
|; } print qq|
|; &get_footer; } ############################################################################### # MODIFY USER FINAL # Modifies a user's information in the database ############################################################################### sub modify_user_final { &get_user; if (!$FORM{'ifusername'}) { print &Error('You must enter a Username.'); exit; } elsif (!$FORM{'ifemail'}) { print &Error('You must enter your Email Address.'); exit; } elsif (!$FORM{'ifpassword'}) { print &Error('You must enter a Password.'); exit; } elsif ($plength < 6) { print &Error('Your Password must be at least six characters.'); exit; } elsif ($llength < 5) { print &Error('Your Username must be at least five characters.'); exit; } elsif (!$FORM{'iffirstname'}) { print &Error('You must enter your First Name.'); exit; } elsif (!$FORM{'iflastname'}) { print &Error('You must enter your Last Name.'); exit; } require "$libpath/crypt.pl"; $newpass = &admin_encrypt($FORM{'ifpassword'}, $secret_key); unless ($admin_demo_mode) { open (ADMINDB,">$admindb") or print &Error('Could not open the admin database!'); if ($useflock) { flock(ADMINDB, 2); } print ADMINDB "$database"; # print the existing database minus this user, then the user print ADMINDB "$FORM{'ifusername'}\|$newpass\|$ifuser\|$FORM{'ifemail'}\|"; print ADMINDB "$FORM{'iffirstname'}\|$FORM{'iflastname'}\|$FORM{'ifdesc_per'}\|$FORM{'ifupload_per'}\|"; print ADMINDB "$FORM{'ifaddcat_per'}\|$FORM{'ifrencat_per'}\|$FORM{'ifdelcat_per'}\|$FORM{'ifbuild_per'}\|"; print ADMINDB "$FORM{'ifaddusr_per'}\|$FORM{'ifmodusr_per'}\|$FORM{'ifdelusr_per'}\|$FORM{'ifdemo_per'}\n"; if ($useflock) { flock(ADMINDB, 8); } close(ADMINDB); } $comment = qq|<$admin_font>
The administrator
$FORM{'ifusername'}
has been modified.
|; $userstep = ""; &modify_user; } ############################################################################### # DELETE USER # Opens the user database and builds a select box of all users ############################################################################### sub delete_user { $DELETEADMIN = "active"; if ($userstep eq "final" && $ifuser) { &get_user; unless ($admin_demo_mode) { open (ADMINDB,">$admindb") or print &Error('Could not open the admin database!'); if ($useflock) { flock(ADMINDB, 2); } print ADMINDB "$database"; if ($useflock) { flock(ADMINDB, 8); } close(ADMINDB); } $comment = qq|<$admin_font>
The administrator
$ifusername
has been deleted.
|; } $pagetitle = "Delete Admin - Select Admin"; &get_header; &get_user_list; print qq|$comment
<$admin_big_font>
Delete Admin
<$admin_big_font>
Step 1 of 1
$userlist
|; &get_footer; } ############################################################################### # GET USER LIST # Opens the user database and builds a select box of all users ############################################################################### sub get_user { if ($useraction eq "modify" && $userstep eq "final") { $FORM{'ifusername'} =~ s/ //g; $plength = length($FORM{'ifpassword'}); $llength = length($FORM{'ifusername'}); } open (ADMINDB, "$admindb"); while (
) { chomp; /^#/ and next; # Skip comment Lines. /^\s*$/ and next; # Skip blank lines. $row=$_; @user = split(/\|/,$row); if ($user[2] eq $ifuser) { $ifusername = $user[0]; $ifpassword = $user[1]; $ifusernum = $user[2]; $ifemail = $user[3]; $iffirstname = $user[4]; $iflastname = $user[5]; $ifdesc_per = $user[6]; $ifupload_per = $user[7]; $ifaddcat_per = $user[8]; $ifrencat_per = $user[9]; $ifdelcat_per = $user[10]; $ifbuild_per = $user[11]; $ifaddusr_per = $user[12]; $ifmodusr_per = $user[13]; $ifdelusr_per = $user[14]; $ifdemo_per = $user[15]; require "$libpath/crypt.pl"; $decryptpassword = &admin_decrypt($ifpassword, $secret_key); } elsif ($userstep eq "final") { if ($useraction eq "modify" && lc($user[0]) eq lc($FORM{'ifusername'})) { print &Error('The Username you requested is already in use by another administrator.'); exit; } $database .= "$user[0]\|$user[1]\|$user[2]\|$user[3]\|$user[4]\|"; $database .= "$user[5]\|$user[6]\|$user[7]\|$user[8]\|$user[9]\|"; $database .= "$user[10]\|$user[11]\|$user[12]\|$user[13]\|$user[14]\|$user[15]\n"; } } close (ADMINDB); $decryptpassword = "**********" if $admin_demo_mode; } ############################################################################### # GET USER LIST # Opens the user database and builds a select box of all users ############################################################################### sub get_user_list { $userlist = qq|
|; open (ADMINDB, "$admindb"); while (
) { chomp; /^#/ and next; # Skip comment Lines. /^\s*$/ and next; # Skip blank lines. push(@rows, $_); } close (ADMINDB); @rows = sort { lc($a) cmp lc($b) } @rows; foreach $users (@rows) { @user = split(/\|/,$users); if ($admin_demo_mode) { $userlist .= qq|
($user[0]) - ********** **********|; } else { $userlist .= qq|
($user[0]) - $user[4] $user[5]|; } } $userlist .= qq|
|; } 1;
admin_user.pl
网页地址
文件地址
上一页
3/27
下一页
下载
( 19 KB )
Comments
Total ratings:
0
Average rating:
无评论
of 10