Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8775249
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T18:45:29+00:00 2026-06-13T18:45:29+00:00

I have setup cron job, it is working properly, however when i directly runs

  • 0

I have setup cron job, it is working properly, however when i directly runs the php file(from the path/url) it successfully runs, but from cron its not. However i set another very simple file to make sure my cron command/path is set correctly i created another file and used simple php mail function and its is running successfully. Kindly suggest me the possible areas to look into it. (I am using Cpanel)

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T18:45:30+00:00Added an answer on June 13, 2026 at 6:45 pm

    Instead of putting in cronjob command like

    php -f /path_to_script/script.php 
    

    put command like this:

    curl http://domain.com/yourscript.php
    

    if you want to suppress output you can add > /dev/null at the end.

    So full command would be:

    curl http://domain.com/yourscript.php > /dev/null
    

    Hope this helps!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Some setup background first: I have a cronjob which runs a PHP file called
I have a cron job the executes a PHP script. The cron is setup
Is it possible to setup a cron job from within a PHP script on
I have cron jobs setup that runs a few PHP scripts often. The issue
I'm trying to setup a PHP file as a cron job, where that PHP
I have a CRON job php script that I just set up not too
we have a developer who setup a crondoc.txt file that is handling our cron
How to setup a cron job command to execute an URL? /usr/bin/wget -q http://www.domain.com/cron_jobs/job1.php
I have a cron job setup to look every 24 hours for a change
I have an already setted up cron job. Now i have a file whose

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.