Browse Source

PHP CS Fixer

pjc 5 years ago
parent
commit
80347bbc91
1 changed files with 71 additions and 70 deletions
  1. 71
    70
      sections/user/edit.php

+ 71
- 70
sections/user/edit.php View File

1
-<?
1
+<?php
2
 require_once(SERVER_ROOT.'/classes/twofa.class.php');
2
 require_once(SERVER_ROOT.'/classes/twofa.class.php');
3
 $UserID = $_REQUEST['userid'];
3
 $UserID = $_REQUEST['userid'];
4
 if (!is_number($UserID)) {
4
 if (!is_number($UserID)) {
5
-  error(404);
5
+    error(404);
6
 }
6
 }
7
 
7
 
8
 $DB->query("
8
 $DB->query("
32
 $Email = apcu_exists('DBKEY') ? Crypto::decrypt($Email) : '[Encrypted]';
32
 $Email = apcu_exists('DBKEY') ? Crypto::decrypt($Email) : '[Encrypted]';
33
 
33
 
34
 if ($UserID != $LoggedUser['ID'] && !check_perms('users_edit_profiles', $Class)) {
34
 if ($UserID != $LoggedUser['ID'] && !check_perms('users_edit_profiles', $Class)) {
35
-  error(403);
35
+    error(403);
36
 }
36
 }
37
 
37
 
38
 $Paranoia = json_decode($Paranoia, true);
38
 $Paranoia = json_decode($Paranoia, true);
39
 if (!is_array($Paranoia)) {
39
 if (!is_array($Paranoia)) {
40
-  $Paranoia = [];
40
+    $Paranoia = [];
41
 }
41
 }
42
 
42
 
43
-function paranoia_level($Setting) {
44
-  global $Paranoia;
45
-  // 0: very paranoid; 1: stats allowed, list disallowed; 2: not paranoid
46
-  return (in_array($Setting . '+', $Paranoia)) ? 0 : (in_array($Setting, $Paranoia) ? 1 : 2);
43
+function paranoia_level($Setting)
44
+{
45
+    global $Paranoia;
46
+    // 0: very paranoid; 1: stats allowed, list disallowed; 2: not paranoid
47
+    return (in_array($Setting . '+', $Paranoia)) ? 0 : (in_array($Setting, $Paranoia) ? 1 : 2);
47
 }
48
 }
48
 
49
 
49
-function display_paranoia($FieldName) {
50
-  $Level = paranoia_level($FieldName);
51
-  print "\t\t\t\t\t<label><input type=\"checkbox\" name=\"p_{$FieldName}_c\"".checked($Level >= 1).' onchange="AlterParanoia()" /> Show count</label>'."&nbsp;&nbsp;\n";
52
-  print "\t\t\t\t\t<label><input type=\"checkbox\" name=\"p_{$FieldName}_l\"".checked($Level >= 2).' onchange="AlterParanoia()" /> Show list</label>'."\n";
50
+function display_paranoia($FieldName)
51
+{
52
+    $Level = paranoia_level($FieldName);
53
+    print "\t\t\t\t\t<label><input type=\"checkbox\" name=\"p_{$FieldName}_c\"".checked($Level >= 1).' onchange="AlterParanoia()" /> Show count</label>'."&nbsp;&nbsp;\n";
54
+    print "\t\t\t\t\t<label><input type=\"checkbox\" name=\"p_{$FieldName}_l\"".checked($Level >= 2).' onchange="AlterParanoia()" /> Show list</label>'."\n";
53
 }
55
 }
54
 
56
 
55
-function checked($Checked) {
56
-  return ($Checked ? ' checked="checked"' : '');
57
+function checked($Checked)
58
+{
59
+    return ($Checked ? ' checked="checked"' : '');
57
 }
60
 }
58
 
61
 
59
 if ($SiteOptions) {
62
 if ($SiteOptions) {
60
-  $SiteOptions = json_decode($SiteOptions, true) ?? [];
63
+    $SiteOptions = json_decode($SiteOptions, true) ?? [];
61
 } else {
64
 } else {
62
-  $SiteOptions = [];
65
+    $SiteOptions = [];
63
 }
66
 }
64
 
67
 
65
 View::show_header("$Username &gt; Settings", 'user,password_validate,validate,cssgallery,preview_paranoia,bbcode,user_settings,donor_titles');
68
 View::show_header("$Username &gt; Settings", 'user,password_validate,validate,cssgallery,preview_paranoia,bbcode,user_settings,donor_titles');
70
 $DonorIsVisible = Donations::is_visible($UserID);
73
 $DonorIsVisible = Donations::is_visible($UserID);
71
 
74
 
72
 if ($DonorIsVisible === null) {
75
 if ($DonorIsVisible === null) {
73
-  $DonorIsVisible = true;
76
+    $DonorIsVisible = true;
74
 }
77
 }
75
 
78
 
76
 extract(Donations::get_enabled_rewards($UserID));
79
 extract(Donations::get_enabled_rewards($UserID));
140
         <td class="label tooltip" title="Selecting a stylesheet will change <?=SITE_NAME?>'s visual appearance."><strong>Stylesheet</strong></td>
143
         <td class="label tooltip" title="Selecting a stylesheet will change <?=SITE_NAME?>'s visual appearance."><strong>Stylesheet</strong></td>
141
         <td>
144
         <td>
142
           <select name="stylesheet" id="stylesheet">
145
           <select name="stylesheet" id="stylesheet">
143
-<?  foreach ($Stylesheets as $Style) { ?>
146
+<?php  foreach ($Stylesheets as $Style) { ?>
144
             <option value="<?=($Style['ID'])?>"<?=$Style['ID'] == $StyleID ? ' selected="selected"' : ''?>><?=($Style['ProperName'])?></option>
147
             <option value="<?=($Style['ID'])?>"<?=$Style['ID'] == $StyleID ? ' selected="selected"' : ''?>><?=($Style['ProperName'])?></option>
145
-<?  } ?>
148
+<?php  } ?>
146
           </select>&nbsp;&nbsp;
149
           </select>&nbsp;&nbsp;
147
           <a data-toggle-target="#css_gallery" class="brackets">Show gallery</a>
150
           <a data-toggle-target="#css_gallery" class="brackets">Show gallery</a>
148
           <div id="css_gallery" class="hidden">
151
           <div id="css_gallery" class="hidden">
149
-<?  foreach ($Stylesheets as $Style) { ?>
152
+<?php  foreach ($Stylesheets as $Style) { ?>
150
             <div class="preview_wrapper">
153
             <div class="preview_wrapper">
151
               <div class="preview_image" name="<?=($Style['Name'])?>">
154
               <div class="preview_image" name="<?=($Style['Name'])?>">
152
                 <img src="<?=STATIC_SERVER.'stylespreview/thumb_'.$Style['Name'].'.png'?>" alt="<?=$Style['Name']?>" />
155
                 <img src="<?=STATIC_SERVER.'stylespreview/thumb_'.$Style['Name'].'.png'?>" alt="<?=$Style['Name']?>" />
155
                 </p>
158
                 </p>
156
               </div>
159
               </div>
157
             </div>
160
             </div>
158
-<?  } ?>
161
+<?php  } ?>
159
           </div>
162
           </div>
160
         </td>
163
         </td>
161
       </tr>
164
       </tr>
162
       <tr id="style_additions_tr" class="<?=($Stylesheets[$LoggedUser['StyleID']]['Additions'][0] ?? false)?'':'hidden'?>">
165
       <tr id="style_additions_tr" class="<?=($Stylesheets[$LoggedUser['StyleID']]['Additions'][0] ?? false)?'':'hidden'?>">
163
         <td class="label tooltip" title="Select changes that you want made to your chosen stylesheet"><strong>Stylesheet additions</strong></td>
166
         <td class="label tooltip" title="Select changes that you want made to your chosen stylesheet"><strong>Stylesheet additions</strong></td>
164
-        <td> <?
165
-          foreach($Stylesheets as $Style) {
166
-            $StyleAdditions = explode('|', $Style['Additions']);
167
-            ?> <ul class="nobullet style_addition<?=$Style['ID']==$Stylesheets[$LoggedUser['StyleID']]['ID']?'':' hidden'?>" id="style_addition_<?=$Style['Name']?>"> <?
168
-            foreach($StyleAdditions as $i => $Addition) {
169
-              if ($Addition) { ?>
167
+        <td> <?php
168
+          foreach ($Stylesheets as $Style) {
169
+              $StyleAdditions = explode('|', $Style['Additions']); ?> <ul class="nobullet style_addition<?=$Style['ID']==$Stylesheets[$LoggedUser['StyleID']]['ID']?'':' hidden'?>" id="style_addition_<?=$Style['Name']?>"> <?php
170
+            foreach ($StyleAdditions as $i => $Addition) {
171
+                if ($Addition) { ?>
170
                 <li>
172
                 <li>
171
                 <input type="checkbox" name="style_additions[]" value="<?=$Addition?>" id="addition_<?=$Addition?>"<?=(in_array($Addition, $SiteOptions['StyleAdditions']??[])?' checked="checked"':'')?>>
173
                 <input type="checkbox" name="style_additions[]" value="<?=$Addition?>" id="addition_<?=$Addition?>"<?=(in_array($Addition, $SiteOptions['StyleAdditions']??[])?' checked="checked"':'')?>>
172
                   <label for="addition_<?=$Addition?>"><?=explode('|', $Style['ProperAdditions'])[$i]?></label>
174
                   <label for="addition_<?=$Addition?>"><?=explode('|', $Style['ProperAdditions'])[$i]?></label>
173
                 </li>
175
                 </li>
174
-           <? }
175
-            }
176
-            ?> </ul> <?
176
+           <?php }
177
+            } ?> </ul> <?php
177
           }
178
           }
178
         ?> </td>
179
         ?> </td>
179
       </tr>
180
       </tr>
183
           <input type="text" size="40" name="styleurl" id="styleurl" value="<?=display_str($StyleURL)?>" />
184
           <input type="text" size="40" name="styleurl" id="styleurl" value="<?=display_str($StyleURL)?>" />
184
         </td>
185
         </td>
185
       </tr>
186
       </tr>
186
-<?  if (check_perms('users_mod')) { ?>
187
+<?php  if (check_perms('users_mod')) { ?>
187
       <tr id="site_autostats_tr">
188
       <tr id="site_autostats_tr">
188
         <td class="label tooltip" title="This is a staff-only feature to bypass the &quot;Show stats&quot; button for seeding, leeching, snatched, and downloaded stats on profile pages."><strong>Profile stats</strong></td>
189
         <td class="label tooltip" title="This is a staff-only feature to bypass the &quot;Show stats&quot; button for seeding, leeching, snatched, and downloaded stats on profile pages."><strong>Profile stats</strong></td>
189
         <td>
190
         <td>
193
           </label>
194
           </label>
194
         </td>
195
         </td>
195
       </tr>
196
       </tr>
196
-<?  } ?>
197
+<?php  } ?>
197
     </table>
198
     </table>
198
     <table cellpadding="6" cellspacing="1" border="0" width="100%" class="layout border user_options" id="torrent_settings">
199
     <table cellpadding="6" cellspacing="1" border="0" width="100%" class="layout border user_options" id="torrent_settings">
199
       <tr class="colhead_dark">
200
       <tr class="colhead_dark">
201
           <strong>Torrent Settings</strong>
202
           <strong>Torrent Settings</strong>
202
         </td>
203
         </td>
203
       </tr>
204
       </tr>
204
-<?  if (check_perms('site_advanced_search')) { ?>
205
+<?php  if (check_perms('site_advanced_search')) { ?>
205
       <tr id="tor_searchtype_tr">
206
       <tr id="tor_searchtype_tr">
206
         <td class="label tooltip" title="This option allows you to choose whether the default torrent search menu will be basic (fewer options) or advanced (more options)."><strong>Default search type</strong></td>
207
         <td class="label tooltip" title="This option allows you to choose whether the default torrent search menu will be basic (fewer options) or advanced (more options)."><strong>Default search type</strong></td>
207
         <td>
208
         <td>
217
           </ul>
218
           </ul>
218
         </td>
219
         </td>
219
       </tr>
220
       </tr>
220
-<?  } ?>
221
+<?php  } ?>
221
       <tr id="tor_group_tr">
222
       <tr id="tor_group_tr">
222
         <td class="label tooltip" title="Enabling torrent grouping will place multiple formats of the same torrent group together beneath a common header."><strong>Torrent grouping</strong></td>
223
         <td class="label tooltip" title="Enabling torrent grouping will place multiple formats of the same torrent group together beneath a common header."><strong>Torrent grouping</strong></td>
223
         <td>
224
         <td>
258
           <label for="showmagnets">Show magnet links</label>
259
           <label for="showmagnets">Show magnet links</label>
259
         </td>
260
         </td>
260
       </tr>
261
       </tr>
261
-<? /* ?>
262
+<?php /* ?>
262
       <tr>
263
       <tr>
263
         <td class="label"><strong>Collage album art view</strong></td>
264
         <td class="label"><strong>Collage album art view</strong></td>
264
         <td>
265
         <td>
308
               <label for="showtfilter">Display filter controls</label>
309
               <label for="showtfilter">Display filter controls</label>
309
             </li>
310
             </li>
310
             <li>
311
             <li>
311
-              <input type="checkbox" name="showtags" id="showtags"<? Format::selected('ShowTags', 1, 'checked', $SiteOptions); ?> />
312
+              <input type="checkbox" name="showtags" id="showtags"<?php Format::selected('ShowTags', 1, 'checked', $SiteOptions); ?> />
312
               <label for="showtags">Display official tag filters</label>
313
               <label for="showtags">Display official tag filters</label>
313
             </li>
314
             </li>
314
           </ul>
315
           </ul>
375
       <tr id="comm_badge_tr">
376
       <tr id="comm_badge_tr">
376
         <td class="label tooltip" title="Select up to 5 badges to display next to your username."><strong>Displayed Badges</strong></td>
377
         <td class="label tooltip" title="Select up to 5 badges to display next to your username."><strong>Displayed Badges</strong></td>
377
         <td>
378
         <td>
378
-<?  $Badges = Badges::get_badges($UserID);
379
+<?php  $Badges = Badges::get_badges($UserID);
379
     if (empty($Badges)) {
380
     if (empty($Badges)) {
380
-      ?><span>You have no badges :(</span><?
381
+        ?><span>You have no badges :(</span><?php
381
     } else {
382
     } else {
382
-      $Count = 0;
383
-      foreach ($Badges as $BadgeID => $Displayed) {
384
-        ?><input type="checkbox" name="badges[]" class="badge_checkbox" value="<?=$BadgeID?>" <?=($Displayed)?"checked ":""?>/><?=Badges::display_badge($BadgeID, true)?><?
383
+        $Count = 0;
384
+        foreach ($Badges as $BadgeID => $Displayed) {
385
+            ?><input type="checkbox" name="badges[]" class="badge_checkbox" value="<?=$BadgeID?>" <?=($Displayed)?"checked ":""?>/><?=Badges::display_badge($BadgeID, true)?><?php
385
         $Count++;
386
         $Count++;
386
-        echo ($Count % 8) ? '' : '<br>';
387
-      }
387
+            echo ($Count % 8) ? '' : '<br>';
388
+        }
388
     }
389
     }
389
 ?>
390
 ?>
390
         </td>
391
         </td>
410
           <label for="unseededalerts">Enable unseeded torrent alerts</label>
411
           <label for="unseededalerts">Enable unseeded torrent alerts</label>
411
         </td>
412
         </td>
412
       </tr>
413
       </tr>
413
-      <? NotificationsManagerView::render_settings(NotificationsManager::get_settings($UserID)); ?>
414
+      <?php NotificationsManagerView::render_settings(NotificationsManager::get_settings($UserID)); ?>
414
     </table>
415
     </table>
415
     <table cellpadding="6" cellspacing="1" border="0" width="100%" class="layout border user_options" id="personal_settings">
416
     <table cellpadding="6" cellspacing="1" border="0" width="100%" class="layout border user_options" id="personal_settings">
416
       <tr class="colhead_dark">
417
       <tr class="colhead_dark">
424
           <input type="text" size="50" name="avatar" id="avatar" value="<?=display_str($Avatar)?>" />
425
           <input type="text" size="50" name="avatar" id="avatar" value="<?=display_str($Avatar)?>" />
425
         </td>
426
         </td>
426
       </tr>
427
       </tr>
427
-<?  if ($HasSecondAvatar) { ?>
428
+<?php  if ($HasSecondAvatar) { ?>
428
       <tr id="pers_avatar2_tr">
429
       <tr id="pers_avatar2_tr">
429
         <td class="label tooltip_interactive" title="Congratulations! You've unlocked this option by reaching Special Rank #2. Thanks for donating. Your normal avatar will &quot;flip&quot; to this one when someone runs their mouse over the image. Please link to an avatar which follows the &lt;a href=&quot;rules.php&quot;&gt;site rules&lt;/a&gt;. The avatar width should be 150 pixels and will be resized if necessary." data-title-plain="Congratulations! You've unlocked this option by reaching Special Rank #2. Thanks for donating. Your normal avatar will &quot;flip&quot; to this one when someone runs their mouse over the image. Please link to an avatar which follows the site rules. The avatar width should be 150 pixels and will be resized if necessary."><strong>Second avatar URL</strong></td>
430
         <td class="label tooltip_interactive" title="Congratulations! You've unlocked this option by reaching Special Rank #2. Thanks for donating. Your normal avatar will &quot;flip&quot; to this one when someone runs their mouse over the image. Please link to an avatar which follows the &lt;a href=&quot;rules.php&quot;&gt;site rules&lt;/a&gt;. The avatar width should be 150 pixels and will be resized if necessary." data-title-plain="Congratulations! You've unlocked this option by reaching Special Rank #2. Thanks for donating. Your normal avatar will &quot;flip&quot; to this one when someone runs their mouse over the image. Please link to an avatar which follows the site rules. The avatar width should be 150 pixels and will be resized if necessary."><strong>Second avatar URL</strong></td>
430
         <td>
431
         <td>
431
           <input type="text" size="50" name="second_avatar" id="second_avatar" value="<?=$Rewards['SecondAvatar']?>" />
432
           <input type="text" size="50" name="second_avatar" id="second_avatar" value="<?=$Rewards['SecondAvatar']?>" />
432
         </td>
433
         </td>
433
       </tr>
434
       </tr>
434
-<?  }
435
+<?php  }
435
   if ($HasAvatarMouseOverText) { ?>
436
   if ($HasAvatarMouseOverText) { ?>
436
       <tr id="pers_avatarhover_tr">
437
       <tr id="pers_avatarhover_tr">
437
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #3. Thanks for donating. Text you enter in this field will appear when someone mouses over your avatar. All text should follow site rules. 200 character limit."><strong>Avatar mouseover text</strong></td>
438
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #3. Thanks for donating. Text you enter in this field will appear when someone mouses over your avatar. All text should follow site rules. 200 character limit."><strong>Avatar mouseover text</strong></td>
439
           <input type="text" size="50" name="avatar_mouse_over_text" id="avatar_mouse_over_text" value="<?=$Rewards['AvatarMouseOverText']?>" />
440
           <input type="text" size="50" name="avatar_mouse_over_text" id="avatar_mouse_over_text" value="<?=$Rewards['AvatarMouseOverText']?>" />
440
         </td>
441
         </td>
441
       </tr>
442
       </tr>
442
-<?  }
443
+<?php  }
443
   if ($HasDonorIconMouseOverText) { ?>
444
   if ($HasDonorIconMouseOverText) { ?>
444
       <tr id="pers_donorhover_tr">
445
       <tr id="pers_donorhover_tr">
445
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #2. Thanks for donating. Text you enter in this field will appear when someone mouses over your donor icon. All text should follow site rules. 200 character limit."><strong>Donor icon mouseover text</strong></td>
446
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #2. Thanks for donating. Text you enter in this field will appear when someone mouses over your donor icon. All text should follow site rules. 200 character limit."><strong>Donor icon mouseover text</strong></td>
447
           <input type="text" size="50" name="donor_icon_mouse_over_text" id="donor_icon_mouse_over_text" value="<?=$Rewards['IconMouseOverText']?>" />
448
           <input type="text" size="50" name="donor_icon_mouse_over_text" id="donor_icon_mouse_over_text" value="<?=$Rewards['IconMouseOverText']?>" />
448
         </td>
449
         </td>
449
       </tr>
450
       </tr>
450
-<?  }
451
+<?php  }
451
   if ($HasDonorIconLink) { ?>
452
   if ($HasDonorIconLink) { ?>
452
       <tr id="pers_donorlink_tr">
453
       <tr id="pers_donorlink_tr">
453
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #4. Thanks for donating. Links you enter in this field will be accessible when your donor icon is clicked. All links should follow site rules."><strong>Donor icon link</strong></td>
454
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #4. Thanks for donating. Links you enter in this field will be accessible when your donor icon is clicked. All links should follow site rules."><strong>Donor icon link</strong></td>
455
           <input type="text" size="50" name="donor_icon_link" id="donor_icon_link" value="<?=$Rewards['CustomIconLink']?>" />
456
           <input type="text" size="50" name="donor_icon_link" id="donor_icon_link" value="<?=$Rewards['CustomIconLink']?>" />
456
         </td>
457
         </td>
457
       </tr>
458
       </tr>
458
-<?  }
459
+<?php  }
459
   if ($HasCustomDonorIcon) { ?>
460
   if ($HasCustomDonorIcon) { ?>
460
       <tr id="pers_donoricon_tr">
461
       <tr id="pers_donoricon_tr">
461
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #5. Thanks for donating. Please link to an icon which you'd like to replace your default donor icon with. Icons must be 15 pixels wide by 13 pixels tall. Icons of any other size will be automatically resized."><strong>Custom donor icon URL</strong></td>
462
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #5. Thanks for donating. Please link to an icon which you'd like to replace your default donor icon with. Icons must be 15 pixels wide by 13 pixels tall. Icons of any other size will be automatically resized."><strong>Custom donor icon URL</strong></td>
463
           <input type="text" size="50" name="donor_icon_custom_url" id="donor_icon_custom_url" value="<?=$Rewards['CustomIcon']?>" />
464
           <input type="text" size="50" name="donor_icon_custom_url" id="donor_icon_custom_url" value="<?=$Rewards['CustomIcon']?>" />
464
         </td>
465
         </td>
465
       </tr>
466
       </tr>
466
-<?  }
467
+<?php  }
467
   if ($HasDonorForum) { ?>
468
   if ($HasDonorForum) { ?>
468
       <tr id="pers_donorforum_tr">
469
       <tr id="pers_donorforum_tr">
469
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #5. Thanks for donating. You may select a prefix and suffix which will be used in the Donor Forum you now have access to."><strong>Donor forum honorific</strong></td>
470
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #5. Thanks for donating. You may select a prefix and suffix which will be used in the Donor Forum you now have access to."><strong>Donor forum honorific</strong></td>
480
           <strong>Preview:</strong> <span id="donor_title_prefix_preview"></span><?=$Username?><span id="donor_title_comma_preview">, </span><span id="donor_title_suffix_preview"></span>
481
           <strong>Preview:</strong> <span id="donor_title_prefix_preview"></span><?=$Username?><span id="donor_title_comma_preview">, </span><span id="donor_title_suffix_preview"></span>
481
         </td>
482
         </td>
482
       </tr>
483
       </tr>
483
-<?  } ?>
484
+<?php  } ?>
484
       <tr id="pers_proftitle_tr">
485
       <tr id="pers_proftitle_tr">
485
         <td class="label tooltip" title="You can customize your profile information with text and BBCode. Entering a title will label your profile information section. Unlock additional profile info boxes via Donor Ranks."><strong>Profile title 1</strong></td>
486
         <td class="label tooltip" title="You can customize your profile information with text and BBCode. Entering a title will label your profile information section. Unlock additional profile info boxes via Donor Ranks."><strong>Profile title 1</strong></td>
486
         <td><input type="text" size="50" name="profile_title" id="profile_title" value="<?=display_str($InfoTitle)?>" />
487
         <td><input type="text" size="50" name="profile_title" id="profile_title" value="<?=display_str($InfoTitle)?>" />
491
         <td><?php $textarea = new TEXTAREA_PREVIEW('info', 'info', display_str($Info), 40, 8); ?></td>
492
         <td><?php $textarea = new TEXTAREA_PREVIEW('info', 'info', display_str($Info), 40, 8); ?></td>
492
       </tr>
493
       </tr>
493
       <!-- Excuse this numbering confusion, we start numbering our profile info/titles at 1 in the donor_rewards table -->
494
       <!-- Excuse this numbering confusion, we start numbering our profile info/titles at 1 in the donor_rewards table -->
494
-<?  if ($HasProfileInfo1) { ?>
495
+<?php  if ($HasProfileInfo1) { ?>
495
       <tr id="pers_proftitle2_tr">
496
       <tr id="pers_proftitle2_tr">
496
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #2. Thanks for donating. You can customize your profile information with text and BBCode. Entering a title will label your profile information section."><strong>Profile title 2</strong></td>
497
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #2. Thanks for donating. You can customize your profile information with text and BBCode. Entering a title will label your profile information section."><strong>Profile title 2</strong></td>
497
         <td><input type="text" size="50" name="profile_title_1" id="profile_title_1" value="<?=display_str($ProfileRewards['ProfileInfoTitle1'])?>" />
498
         <td><input type="text" size="50" name="profile_title_1" id="profile_title_1" value="<?=display_str($ProfileRewards['ProfileInfoTitle1'])?>" />
501
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #2. Thanks for donating. You can customize your profile information with text and BBCode. Entering a title will label your profile information section."><strong>Profile info 2</strong></td>
502
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #2. Thanks for donating. You can customize your profile information with text and BBCode. Entering a title will label your profile information section."><strong>Profile info 2</strong></td>
502
         <td><?php $textarea = new TEXTAREA_PREVIEW('profile_info_1', 'profile_info_1', display_str($ProfileRewards['ProfileInfo1']), 40, 8); ?></td>
503
         <td><?php $textarea = new TEXTAREA_PREVIEW('profile_info_1', 'profile_info_1', display_str($ProfileRewards['ProfileInfo1']), 40, 8); ?></td>
503
       </tr>
504
       </tr>
504
-<?  }
505
+<?php  }
505
   if ($HasProfileInfo2) { ?>
506
   if ($HasProfileInfo2) { ?>
506
       <tr id="pers_proftitle3_tr">
507
       <tr id="pers_proftitle3_tr">
507
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #3. Thanks for donating. You can customize your profile information with text and BBCode. Entering a title will label your profile information section."><strong>Profile title 3</strong></td>
508
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #3. Thanks for donating. You can customize your profile information with text and BBCode. Entering a title will label your profile information section."><strong>Profile title 3</strong></td>
512
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #3. Thanks for donating. You can customize your profile information with text and BBCode. Entering a title will label your profile information section."><strong>Profile info 3</strong></td>
513
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #3. Thanks for donating. You can customize your profile information with text and BBCode. Entering a title will label your profile information section."><strong>Profile info 3</strong></td>
513
         <td><?php $textarea = new TEXTAREA_PREVIEW('profile_info_2', 'profile_info_2', display_str($ProfileRewards['ProfileInfo2']), 40, 8); ?></td>
514
         <td><?php $textarea = new TEXTAREA_PREVIEW('profile_info_2', 'profile_info_2', display_str($ProfileRewards['ProfileInfo2']), 40, 8); ?></td>
514
       </tr>
515
       </tr>
515
-<?  }
516
+<?php  }
516
   if ($HasProfileInfo3) { ?>
517
   if ($HasProfileInfo3) { ?>
517
       <tr id="pers_proftitle4_tr">
518
       <tr id="pers_proftitle4_tr">
518
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #4. Thanks for donating. You can customize your profile information with text and BBCode. Entering a title will label your profile information section."><strong>Profile title 4</strong></td>
519
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #4. Thanks for donating. You can customize your profile information with text and BBCode. Entering a title will label your profile information section."><strong>Profile title 4</strong></td>
523
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #4. Thanks for donating. You can customize your profile information with text and BBCode. Entering a title will label your profile information section."><strong>Profile info 4</strong></td>
524
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #4. Thanks for donating. You can customize your profile information with text and BBCode. Entering a title will label your profile information section."><strong>Profile info 4</strong></td>
524
         <td><?php $textarea = new TEXTAREA_PREVIEW('profile_info_3', 'profile_info_3', display_str($ProfileRewards['ProfileInfo3']), 40, 8); ?></td>
525
         <td><?php $textarea = new TEXTAREA_PREVIEW('profile_info_3', 'profile_info_3', display_str($ProfileRewards['ProfileInfo3']), 40, 8); ?></td>
525
       </tr>
526
       </tr>
526
-<?  }
527
+<?php  }
527
   if ($HasProfileInfo4) { ?>
528
   if ($HasProfileInfo4) { ?>
528
       <tr id="pers_proftitle5_tr">
529
       <tr id="pers_proftitle5_tr">
529
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #5. Thanks for donating. You can customize your profile information with text and BBCode. Entering a title will label your profile information section."><strong>Profile title 5</strong></td>
530
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #5. Thanks for donating. You can customize your profile information with text and BBCode. Entering a title will label your profile information section."><strong>Profile title 5</strong></td>
534
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #5. Thanks for donating. You can customize your profile information with text and BBCode. Entering a title will label your profile information section."><strong>Profile info 5</strong></td>
535
         <td class="label tooltip" title="Congratulations! You've unlocked this option by reaching Donor Rank #5. Thanks for donating. You can customize your profile information with text and BBCode. Entering a title will label your profile information section."><strong>Profile info 5</strong></td>
535
         <td><?php $textarea = new TEXTAREA_PREVIEW('profile_info_4', 'profile_info_4', display_str($ProfileRewards['ProfileInfo4']), 40, 8); ?></td>
536
         <td><?php $textarea = new TEXTAREA_PREVIEW('profile_info_4', 'profile_info_4', display_str($ProfileRewards['ProfileInfo4']), 40, 8); ?></td>
536
       </tr>
537
       </tr>
537
-<?  } ?>
538
+<?php  } ?>
538
     </table>
539
     </table>
539
     <table cellpadding="6" cellspacing="1" border="0" width="100%" class="layout border user_options" id="paranoia_settings">
540
     <table cellpadding="6" cellspacing="1" border="0" width="100%" class="layout border user_options" id="paranoia_settings">
540
       <tr class="colhead_dark">
541
       <tr class="colhead_dark">
576
       <tr id="para_stats_tr">
577
       <tr id="para_stats_tr">
577
         <td class="label tooltip" title="These settings control the display of your uploaded data amount, downloaded data amount, and ratio."><strong>Statistics</strong></td>
578
         <td class="label tooltip" title="These settings control the display of your uploaded data amount, downloaded data amount, and ratio."><strong>Statistics</strong></td>
578
         <td>
579
         <td>
579
-<?
580
+<?php
580
 $UploadChecked = checked(!in_array('uploaded', $Paranoia));
581
 $UploadChecked = checked(!in_array('uploaded', $Paranoia));
581
 $DownloadChecked = checked(!in_array('downloaded', $Paranoia));
582
 $DownloadChecked = checked(!in_array('downloaded', $Paranoia));
582
 $RatioChecked = checked(!in_array('ratio', $Paranoia));
583
 $RatioChecked = checked(!in_array('ratio', $Paranoia));
595
       <tr id="para_comments_tr">
596
       <tr id="para_comments_tr">
596
         <td class="label"><strong>Comments (torrents)</strong></td>
597
         <td class="label"><strong>Comments (torrents)</strong></td>
597
         <td>
598
         <td>
598
-<? display_paranoia('torrentcomments'); ?>
599
+<?php display_paranoia('torrentcomments'); ?>
599
         </td>
600
         </td>
600
       </tr>
601
       </tr>
601
       <tr id="para_collstart_tr">
602
       <tr id="para_collstart_tr">
602
         <td class="label"><strong>Collections (started)</strong></td>
603
         <td class="label"><strong>Collections (started)</strong></td>
603
         <td>
604
         <td>
604
-<? display_paranoia('collages'); ?>
605
+<?php display_paranoia('collages'); ?>
605
         </td>
606
         </td>
606
       </tr>
607
       </tr>
607
       <tr id="para_collcontr_tr">
608
       <tr id="para_collcontr_tr">
608
         <td class="label"><strong>Collections (contributed to)</strong></td>
609
         <td class="label"><strong>Collections (contributed to)</strong></td>
609
         <td>
610
         <td>
610
-<? display_paranoia('collagecontribs'); ?>
611
+<?php display_paranoia('collagecontribs'); ?>
611
         </td>
612
         </td>
612
       </tr>
613
       </tr>
613
       <tr id="para_reqfill_tr">
614
       <tr id="para_reqfill_tr">
614
         <td class="label"><strong>Requests (filled)</strong></td>
615
         <td class="label"><strong>Requests (filled)</strong></td>
615
         <td>
616
         <td>
616
-<?
617
+<?php
617
 $RequestsFilledCountChecked = checked(!in_array('requestsfilled_count', $Paranoia));
618
 $RequestsFilledCountChecked = checked(!in_array('requestsfilled_count', $Paranoia));
618
 $RequestsFilledBountyChecked = checked(!in_array('requestsfilled_bounty', $Paranoia));
619
 $RequestsFilledBountyChecked = checked(!in_array('requestsfilled_bounty', $Paranoia));
619
 $RequestsFilledListChecked = checked(!in_array('requestsfilled_list', $Paranoia));
620
 $RequestsFilledListChecked = checked(!in_array('requestsfilled_list', $Paranoia));
626
       <tr id="para_reqvote_tr">
627
       <tr id="para_reqvote_tr">
627
         <td class="label"><strong>Requests (voted for)</strong></td>
628
         <td class="label"><strong>Requests (voted for)</strong></td>
628
         <td>
629
         <td>
629
-<?
630
+<?php
630
 $RequestsVotedCountChecked = checked(!in_array('requestsvoted_count', $Paranoia));
631
 $RequestsVotedCountChecked = checked(!in_array('requestsvoted_count', $Paranoia));
631
 $RequestsVotedBountyChecked = checked(!in_array('requestsvoted_bounty', $Paranoia));
632
 $RequestsVotedBountyChecked = checked(!in_array('requestsvoted_bounty', $Paranoia));
632
 $RequestsVotedListChecked = checked(!in_array('requestsvoted_list', $Paranoia));
633
 $RequestsVotedListChecked = checked(!in_array('requestsvoted_list', $Paranoia));
639
       <tr id="para_upltor_tr">
640
       <tr id="para_upltor_tr">
640
         <td class="label"><strong>Uploaded torrents</strong></td>
641
         <td class="label"><strong>Uploaded torrents</strong></td>
641
         <td>
642
         <td>
642
-<? display_paranoia('uploads'); ?>
643
+<?php display_paranoia('uploads'); ?>
643
         </td>
644
         </td>
644
       </tr>
645
       </tr>
645
       <tr id="para_uplunique_tr">
646
       <tr id="para_uplunique_tr">
646
         <td class="label"><strong>Uploaded torrents (unique groups)</strong></td>
647
         <td class="label"><strong>Uploaded torrents (unique groups)</strong></td>
647
         <td>
648
         <td>
648
-<? display_paranoia('uniquegroups'); ?>
649
+<?php display_paranoia('uniquegroups'); ?>
649
         </td>
650
         </td>
650
       </tr>
651
       </tr>
651
       <tr id="para_torseed_tr">
652
       <tr id="para_torseed_tr">
652
         <td class="label"><strong>Torrents (seeding)</strong></td>
653
         <td class="label"><strong>Torrents (seeding)</strong></td>
653
         <td>
654
         <td>
654
-<? display_paranoia('seeding'); ?>
655
+<?php display_paranoia('seeding'); ?>
655
         </td>
656
         </td>
656
       </tr>
657
       </tr>
657
       <tr id="para_torleech_tr">
658
       <tr id="para_torleech_tr">
658
         <td class="label"><strong>Torrents (leeching)</strong></td>
659
         <td class="label"><strong>Torrents (leeching)</strong></td>
659
         <td>
660
         <td>
660
-<? display_paranoia('leeching'); ?>
661
+<?php display_paranoia('leeching'); ?>
661
         </td>
662
         </td>
662
       </tr>
663
       </tr>
663
       <tr id="para_torsnatch_tr">
664
       <tr id="para_torsnatch_tr">
664
         <td class="label"><strong>Torrents (snatched)</strong></td>
665
         <td class="label"><strong>Torrents (snatched)</strong></td>
665
         <td>
666
         <td>
666
-<? display_paranoia('snatched'); ?>
667
+<?php display_paranoia('snatched'); ?>
667
         </td>
668
         </td>
668
       </tr>
669
       </tr>
669
       <tr id="para_torsubscr_tr">
670
       <tr id="para_torsubscr_tr">
672
           <label><input type="checkbox" name="p_notifications"<?=checked(!in_array('notifications', $Paranoia))?> /> Allow torrent upload subscriptions</label>
673
           <label><input type="checkbox" name="p_notifications"<?=checked(!in_array('notifications', $Paranoia))?> /> Allow torrent upload subscriptions</label>
673
         </td>
674
         </td>
674
       </tr>
675
       </tr>
675
-<?
676
+<?php
676
 $DB->query("
677
 $DB->query("
677
   SELECT COUNT(UserID)
678
   SELECT COUNT(UserID)
678
   FROM users_info
679
   FROM users_info
685
           <label><input type="checkbox" name="p_invitedcount"<?=checked(!in_array('invitedcount', $Paranoia))?> /> Show count</label>
686
           <label><input type="checkbox" name="p_invitedcount"<?=checked(!in_array('invitedcount', $Paranoia))?> /> Show count</label>
686
         </td>
687
         </td>
687
       </tr>
688
       </tr>
688
-<?
689
+<?php
689
 $DB->query("
690
 $DB->query("
690
   SELECT COUNT(ArtistID)
691
   SELECT COUNT(ArtistID)
691
   FROM torrents_artists
692
   FROM torrents_artists
778
   </div>
779
   </div>
779
   </form>
780
   </form>
780
 </div>
781
 </div>
781
-<? View::show_footer(); ?>
782
+<?php View::show_footer(); ?>

Loading…
Cancel
Save