# Adding a cron job using curl to access a url containing & does not execute successfully, nor does it add \\ in front of &

**URL:** <https://forum.hestiacp.com/t/adding-a-cron-job-using-curl-to-access-a-url-containing-does-not-execute-successfully-nor-does-it-add-in-front-of/7001>\
**Category:** Cron Jobs\
**Created:** [July 20, 2022, 4:49am UTC](https://forum.hestiacp.com/t/adding-a-cron-job-using-curl-to-access-a-url-containing-does-not-execute-successfully-nor-does-it-add-in-front-of/7001 "2022-07-20T04:49:42Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![luren549](https://forum.hestiacp.com/letter_avatar_proxy/v4/letter/l/779978/32.png) [@luren549](https://forum.hestiacp.com/u/luren549)\
**Post date:** [July 20, 2022, 4:49am UTC](https://forum.hestiacp.com/t/adding-a-cron-job-using-curl-to-access-a-url-containing-does-not-execute-successfully-nor-does-it-add-in-front-of/7001/1 "2022-07-20T04:49:43Z")

</div>

`curl to access the url containing "&" must add "\" in front of "&", otherwise it will not be able to read the parameters after "&", unfortunately adding "\" in front of "&" through hestiacp web interface is not valid.`

---

<div class="post-metadata">

**Author:** ![eris](https://forum.hestiacp.com/user_avatar/forum.hestiacp.com/eris/32/1241_2.png) [@eris](https://forum.hestiacp.com/u/eris)\
**Post date:** [July 20, 2022, 5:16am UTC](https://forum.hestiacp.com/t/adding-a-cron-job-using-curl-to-access-a-url-containing-does-not-execute-successfully-nor-does-it-add-in-front-of/7001/2 "2022-07-20T05:16:59Z")

</div>

> <https://github.com/hestiacp/hestiacp/issues/2783>
>
> \### Describe the bug
> 
> \`curl to access the url containing "&" must add "\\" in f…ront of "&", otherwise it will not be able to read the parameters after "&", unfortunately adding "\\" in front of "&" through hestiacp web interface is not valid.\`
> 
> \### Tell us how to replicate the bug
> 
> \`curl to access the url containing "&" must add "\\" in front of "&", otherwise it will not be able to read the parameters after "&", unfortunately adding "\\" in front of "&" through hestiacp web interface is not valid.\`
> 
> \### Which components are affected by this bug?
> 
> Control Panel Web Interface
> 
> \### Hestia Control Panel Version
> 
> 1.6.4
> 
> \### Operating system
> 
> debian11
> 
> \### Log capture
> 
> \_No response\_

Please provide more infornation

I am going to close the GitHub issue

---

<div class="post-metadata">

**Author:** ![luren549](https://forum.hestiacp.com/letter_avatar_proxy/v4/letter/l/779978/32.png) [@luren549](https://forum.hestiacp.com/u/luren549)\
**Post date:** [July 20, 2022, 5:23am UTC](https://forum.hestiacp.com/t/adding-a-cron-job-using-curl-to-access-a-url-containing-does-not-execute-successfully-nor-does-it-add-in-front-of/7001/3 "2022-07-20T05:23:03Z")

</div>

In the timed task using curl can not get the parameters after the URL &, you need to add \ in front of &

---

<div class="post-metadata">

**Author:** ![luren549](https://forum.hestiacp.com/letter_avatar_proxy/v4/letter/l/779978/32.png) [@luren549](https://forum.hestiacp.com/u/luren549)\
**Post date:** [July 20, 2022, 5:30am UTC](https://forum.hestiacp.com/t/adding-a-cron-job-using-curl-to-access-a-url-containing-does-not-execute-successfully-nor-does-it-add-in-front-of/7001/4 "2022-07-20T05:30:51Z")

</div>

v-add-cron-job luren \* \* \* \* \* sudo curl [https://xxxxxxx.com/cron/wztask.php?sys=1&key=673007](https://xxxxxxx.com/cron/wztask.php?sys=1&key=673007)  
I can’t add \ in front of the & in the above URL, and the same problem is with the timed tasks in the web interface

---

<div class="post-metadata">

**Author:** ![eris](https://forum.hestiacp.com/user_avatar/forum.hestiacp.com/eris/32/1241_2.png) [@eris](https://forum.hestiacp.com/u/eris)\
**Post date:** [July 20, 2022, 5:31am UTC](https://forum.hestiacp.com/t/adding-a-cron-job-using-curl-to-access-a-url-containing-does-not-execute-successfully-nor-does-it-add-in-front-of/7001/5 "2022-07-20T05:31:16Z")

</div>

Use:  
“[https://xxxxxxx.com/cron/wztask.php?sys=1&key=673007](https://xxxxxxx.com/cron/wztask.php?sys=1&key=673007)”

---

<div class="post-metadata">

**Author:** ![system](https://forum.hestiacp.com/uploads/default/original/1X/d9a5b68bf50ced83e880b56452e592b204761b19.png) [@system](https://forum.hestiacp.com/u/system)\
**Post date:** [August 19, 2022, 5:32am UTC](https://forum.hestiacp.com/t/adding-a-cron-job-using-curl-to-access-a-url-containing-does-not-execute-successfully-nor-does-it-add-in-front-of/7001/6 "2022-08-19T05:32:05Z")

</div>

Closed on August 19, 2022, 5:32am UTC

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
