This repository was archived by the owner on Mar 1, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathsmartdonations-settings.php
More file actions
78 lines (67 loc) · 2.2 KB
/
Copy pathsmartdonations-settings.php
File metadata and controls
78 lines (67 loc) · 2.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
<?php
if(!defined('ABSPATH'))
die('Forbidden');
if(isset($_GET["posting"]))
{
?>
<script type="text/javascript">
alert('Information saved successfully');
</script>
<?php
$sendlogto=$_GET["sendlogto"];
if(isset($_GET["enabledebug"]))
$enableDebug='y';
else
$enableDebug='n';
if(isset($_GET["rednao_skippaypal"]))
$rednao_skippaypal='y';
else
$rednao_skippaypal='n';
update_option('smartDonationsEnableDebug',$enableDebug);
update_option('smartDonationsSendToLog',trim($sendlogto));
update_option('rednao_skippaypal',$rednao_skippaypal);
}else
{
$enableDebug=get_option('smartDonationsEnableDebug');
$sendlogto=get_option('smartDonationsSendToLog');
$rednao_skippaypal=get_option('rednao_skippaypal');
}
?>
<div>
<form action="?page=smart-donations/smartdonations.phpsettings" method="GET">
<input type="hidden" name="page" value="smart-donations/smartdonations.phpsettings"/>
<input type="hidden" name="posting" value="y">
<table style="padding:10px;">
<tr>
<td>
<span>Enable Debug</span>
</td>
<td>
<input type="checkbox" name="enabledebug" value="y" <?php echo $enableDebug=='y'?'checked="checked"':"" ?>>
</td>
</tr>
<tr>
<td>
<span>Send logging information to</span>
</td>
<td>
<input type="text" style="width: 200px;" name="sendlogto" value="<?php echo $sendlogto ?>">
</td>
</tr>
<tr>
<td>
<span>Skip PayPal request validation</span>
</td>
<td>
<input type="checkbox" name="rednao_skippaypal" value="y" <?php echo $rednao_skippaypal=='y'?'checked="checked"':"" ?>>
</td>
</tr>
<tr>
<td></td>
<td><button>Save</button></td>
</tr>
</table>
</form>
<p>Latest error log</p>
<textarea style="width:500px;height: 500px;"><?php echo get_option('smart_donations_latest_error'); ?></textarea>
</div>