Control Web Panel

WebPanel => How to => Topic started by: redy on March 06, 2020, 04:59:41 PM

Title: Quote/quotes in cronjob
Post by: redy on March 06, 2020, 04:59:41 PM
Can anyone tell me, how to add cron job with quote/quotes within command ?
Right now, when I put new cron job from user, quote/quotes will get escaped.
Example:
Code: [Select]
wget -q -O - "https://example.com/system/jobs/run_single?auth=f27e083fdc05a20474eafa808d430a1c&jID=11" >/dev/null 2>&1
will saved like this:
Code: [Select]
wget -q -O - \"https://example.com/system/jobs/run_single?auth=f27e083fdc05a20474eafa808d430a1c&jID=11\" >/dev/null 2>&1
Which was just can't read by the system.
Note: quotes is needed because there a '&' symbol in url.