2 ################################################################################
4 # File: $RCSfile: editprofile.cgi,v $
5 # Revision: $Revision: 1.1 $
6 # Description: Edit the user's profile
7 # Author: Andrew@DeFaria.com
8 # Created: Mon Jan 16 20:25:32 PST 2006
9 # Modified: $Date: 2013/06/12 14:05:47 $
12 # (c) Copyright 2000-2006, Andrew@DeFaria.com, all rights reserved.
14 ################################################################################
19 local $0 = $FindBin::Script;
21 use lib "$FindBin::Bin/../lib";
22 use lib "$FindBin::Bin/../../lib";
27 use CGI qw(:standard *table);
30 my $table_name = 'profile';
33 FindUser(userid => $userid);
37 my %options = GetUserOptions($userid);
41 -action => 'updateprofile.cgi',
42 -onSubmit => 'return validate (this);'
53 td {-class => 'label',
54 -width => 134}, 'Username:',
55 td {-width => 290}, $userid,
56 td {-class => 'notetext'}, 'Specify a username to log into MAPS'
59 td {-class => 'label'}, 'Full name:',
61 textfield {-class => 'inputfield',
64 -value => $rec->{name}}),
65 td {-class => 'notetext'},'Specify your full name'
68 td {-class => 'label'}, 'Email:',
70 textfield {-class => 'inputfield',
73 -value => $rec->{email}}),
74 td {-class => 'notetext'},'Your email address is used if you are a ' .
75 i ("Tag & Forward") .
76 ' user. This is the email address that MAPS will forward your email to after it tags it. This email address is also used in case you forget your password so that we can email you your password.'
79 td {-class => 'label'}, 'Old Password:',
81 password_field {-class => 'inputfield',
83 -name => 'old_password'}),
84 td {-class => 'notetext'}, 'Enter your old password'
87 td {-class => 'label'}, 'New Password:',
89 password_field {-class => 'inputfield',
91 -name => 'new_password',
93 td {-class => 'notetext'}, 'Choose a new password greater than 6 characters.'
96 td {-class => 'label'},'Repeat Password:',
98 password_field {-class => 'inputfield',
100 -name => 'repeated_password',
102 td {-class => 'notetext'}, 'Re-enter your password so we can be sure you typed it correctly.'
105 td {-class => 'label'}, 'MAPSPOP user:',
107 font ({-class => 'label'},
108 radio_group {-name => 'MAPSPOP',
109 -values => ['yes', 'no'],
111 -labels => {'yes' => 'Yes',
113 td {-class => 'notetext'}, 'MAPSPOP users need to download ' .
114 a ({-href => '/maps/bin/MAPSPOP.exe'}, 'MAPSPOP') .
116 a ({-href => '/maps/doc/UsingMAPSPOP.html'}, 'Using MAPSPOP') .
117 ' for more information.'
120 td {-class => 'label'}, 'Keep history for:',
122 font ({-class => 'label'},
123 popup_menu {-class => 'inputfield',
125 -values => ['7', '14', '30', '60', '90'],
126 -default => $options{'History'}}),
127 font ({-class => 'label'}, ' days')),
128 td {-class => 'notetext'}, 'This specifies how many days of history that MAPS will keep before discarding returned messages.'
131 td {-class => 'label'}, 'Dates in Stats Page:',
133 font ({-class => 'label'},
134 popup_menu {-class => 'inputfield',
136 -values => ['7', '14', '21', '30'],
137 -default => $options{'Dates'}})),
138 td {-class => 'notetext'}, 'This specifies how many days are displayed in the MAPS Stats Page.'
141 td {-class => 'label'}, 'Entries per page:',
143 font ({-class => 'label'},
144 popup_menu {-class => 'inputfield',
146 -values => ['10', '20', '30', '40', '50'],
147 -default => $options{'Page'}})),
148 td {-class => 'notetext'}, 'This specifies how many entries are displayed per page in the online MAPS Reports.'
151 td {-class => 'label'}, i ('Tag & Forward:'),
153 font ({-class => 'label'},
154 radio_group {-name => 'tag_and_forward',
155 -values => ['yes', 'no'],
157 -labels => {'yes' => 'Yes',
159 td {-class => 'notetext'},
160 i ('Tag and Forward') . ' means that MAPS will not filter or save any email for you. Instead it will simply add an X-MAPS header to your email indicating what MAPS would have done with the email. This allows you to filter your email in your local email client.'
163 print br (div {-align => 'center'},
164 submit (-name => 'submit',
165 -value => 'Update Profile'));
172 my @scripts = ('MAPSUtils.js', 'CheckEditProfile.js');
178 'Spam Elimination System',
184 $userid //= $ENV{USER};
187 NavigationBar $userid;