Jump to content
MakeWebGames

Hey I need help.wity my game my Crons doesn't work


athena26

Recommended Posts

We can't offer suggestions for potential fixes without knowing a little more about your system.

Looks like you're hosted with iFastNet, who do offer crons via cPanel, and at a guess, it looks like you're using MC Codes v2.

The cron commands required are given upon installation.
Failing that, your cron code will be in `config.php` - you'll need this to allow your crons to run.

In your File Manager, you should see 4 files starting with `cron_` (by default); these are `cron_day.php`, `cron_hour.php`, `cron_fivemins.php` and `cron_minute.php`
And in your cPanel, you should see a "Cron Jobs" option (usually under "Advanced").

Add a Cron Job for each file, with its schedule settings matching the file's name.
Be sure to alter the path (`~/public_html/` given in the example below) to your paths and `YOUR_CODE_HERE` to the cron code you (hopefully) found in your config.php.

 

* * * * *   php ~/public_html/cron_minute.php code=YOUR_CODE_HERE
*/5 * * * * php ~/public_html/cron_fivemins.php code=YOUR_CODE_HERE
0 * * * *   php ~/public_html/cron_hour.php code=YOUR_CODE_HERE
0 0 * * *   php ~/public_html/cron_day.php code=YOUR_CODE_HERE


*Note: cPanel's crontab might play funny with a relative homedir path (the `~`). Simply alter this to an absolute path (`/home/your-cpanel-username`, for example)
*Note: Here's a tool I used to reference to understand what the schedule formats mean: Crontab.Guru

  • Like 2
Link to comment
Share on other sites

Thanks will try this now I did go to cron jobs and added all 4 Crons but it still doesn't work 😞

I'm new to this so I hardly understand on how to do this I also will be moving to a upgraded plan. In a week time with ifastnet however I'm clueless on how to do this .

http://gangsterparadise.rf.gd/htdocs/cron_fivemins.php this is the code I add to cron jobs .

And correct I'm using MC codes v2

now ive done this http://gangsterparadise.rf.gd/htdocs/cron_day.php_code=2c72366341cc8e9c36fc7565fe77b1b4 and it still doesnt work  ;(

can someone please help me ive tried every method and i cant do it 

Link to comment
Share on other sites

So basically remove the under score PHP (space) code so no under score ?

cron_hour.phpcode= my code like this ...

no it still aint working ..

i dont know why it doesnt work i know removed the underscore and it still doesnt work what do i do ..

well jail time was at 5 mins it now went to 4 minutes and its stuck in 4 minutes

Link to comment
Share on other sites

1 hour ago, athena26 said:

So basically remove the under score PHP (space) code so no under score ?

cron_hour.phpcode= my code like this ...

no it still aint working ..

i dont know why it doesnt work i know removed the underscore and it still doesnt work what do i do ..

well jail time was at 5 mins it now went to 4 minutes and its stuck in 4 minutes

cron_hour.php?code=WHATEVER

you need the ?=

Link to comment
Share on other sites

On 3/7/2021 at 2:47 PM, athena26 said:

will try it now hope it works 

im afriad it still doesnt work i dont know what to do anymore

http://gangsterparadise.rf.gd/htdocs/cron_minute.php?code= this is what i put and it doesnt work 

If your trying to access this URL from the browser, it wont happen because of htdocs/ 

That URL goes in the cron.

Your cron is NEVER GOING TO WORK because you are not fully understanding what is going on.

Let me try to break this down.

So yOUR URL to this cron file is gansgerparadise/cron_minute.php

But heres the kicker, there's a password inside the file which if the password is not correct it will just exit the file.

 

This is why everyone keeps talking about adding

?code=YOUR_SECRET_PASSWORD to the end of the cron file URL

 

BUT

inside the cron file if the "code" secret password does not match the files secret password IT WILL JUST EXIT/CLOSE/ACT LIKE NO one ever visited the file. 

 

This is why I asked you to post the first 15 lines or so of that file code. 

Edited by Sim
  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...