[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 643
  • Last Modified:

Is there any way to execute javascript in cron job

I am using javascript in my php file. when i execute this file in my browser its working fine. But in cron job its not working. But i want to use javascript that file. Is there any way to execute javascript file in cron job?
0
jnj_web_solutions
Asked:
jnj_web_solutions
1 Solution
 
Derek JensenCommented:
By very definition, JavaScript is only run client-side. That means that PHP can only output JavaScript via a text string. However, the JavaScript is not going to actually be executed until the output is accessed, externally.

Is there a particular reason you require javascript? There's nothing I've found that JS can do that PHP can't, and PHP usually does it much better and faster. :)
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now