[Tutorial] CronJob Prevent Email
Posted: Mon Jun 02, 2014 3:27 pm
File: /usr/local/vesta/web/add/cron/index.php
Find:
Replace with:
File: /usr/local/vesta/web/templates/admin/add_cron.html
Find:
Add After:
Now your done.
Find:
Code: Select all
$v_cmd = escapeshellarg($_POST['v_cmd']);
Code: Select all
$v_preventemail = isset($_POST['v_preventemail']);
$v_cmd = escapeshellarg($_POST['v_cmd'] . ($v_preventemail ? ' &> /dev/null' : '' ));
Find:
Code: Select all
<tr>
<td class="vst-text" style="padding: 12px 0 0 0;">
<?php print __('Command');?>
</td>
</tr>
<tr>
<td>
<input type="text" size="20" class="vst-input" name="v_cmd" <?php if (!empty($v_cmd)) echo "value='".$v_cmd."'"; ?>>
</td>
</tr>
Code: Select all
<tr>
<td class="vst-text" style="padding: 12px 0 0 0;">
<?php print __('Prevent Email');?>
</td>
</tr>
<tr>
<td>
<input type="checkbox" class="vst-input" name="v_preventemail" <?php if (!empty($v_preventemail)) echo 'value="'.'prevent'.'"'; ?>>
</td>
</tr>