Vesta Control Panel - Forum

Community Forum

Skip to content

Advanced search
  • Quick links
    • Main site
    • Github repo
    • Google Search
  • FAQ
  • Login
  • Register
  • Board index Dev Section Modification & Patches
  • Search

[Tutorial] CronJob Prevent Email

Section with modification and patches for Vesta
Post Reply
  • Print view
Advanced search
1 post • Page 1 of 1
ludalabs
Posts: 2
Joined: Mon Jun 02, 2014 3:08 pm

[Tutorial] CronJob Prevent Email
  • Quote

Post by ludalabs » Mon Jun 02, 2014 3:27 pm

File: /usr/local/vesta/web/add/cron/index.php

Find:

Code: Select all

$v_cmd = escapeshellarg($_POST['v_cmd']);
Replace with:

Code: Select all

$v_preventemail = isset($_POST['v_preventemail']);
$v_cmd = escapeshellarg($_POST['v_cmd'] . ($v_preventemail ? ' &> /dev/null' : '' ));
File: /usr/local/vesta/web/templates/admin/add_cron.html

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>
Add After:

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>
Now your done.
Top


Post Reply
  • Print view
1 post • Page 1 of 1

Return to “Modification & Patches”



  • Board index
  • All times are UTC
  • Delete all board cookies
  • The team
Powered by phpBB® Forum Software © phpBB Limited
*Original Author: Brad Veryard
*Updated to 3.2 by MannixMD
 

 

Login  •  Register

I forgot my password