Sim Posted November 18, 2020 Share Posted November 18, 2020 (edited) So I am trying to test a cron job php file,but every time I try to list the file I get a HTTP ERROR 500. http://sim.makeweb.games/FRESH/modules/installed/businesses/businesses.cron.php Which is even clocked on from the directory but just can't get my page to load. Which it should, or show an error. Http://sim.makeweb.games/FRESH/modules/installed/businesses First 9 lines from code:, so if the page posts it should either display a php error, or "lie" <?php $PATH = "../../../"; $PASSWORD = "NEWPASS"; die("lie"); if($_GET['code'] != $PASSWORD) { exit(); } Edited November 18, 2020 by Sim Quote Link to comment Share on other sites More sharing options...
Dayo Posted November 18, 2020 Share Posted November 18, 2020 Can I ask why do you need a cron? Also if you have invalid PHP it wont run the script at all we would need more then the first 9 lines to debug Quote Link to comment Share on other sites More sharing options...
Sim Posted November 19, 2020 Author Share Posted November 19, 2020 Issue was fixed hours ago. I overlooked the errorlog file. Cron to update something once a hour. 2 Quote Link to comment Share on other sites More sharing options...
Dayo Posted November 19, 2020 Share Posted November 19, 2020 I strongly advise against using crons I even made a PHP class to replace them with when I’m up I’ll link it 2 Quote Link to comment Share on other sites More sharing options...
SwiftGameR Posted November 19, 2020 Share Posted November 19, 2020 (edited) i just get a white page when accessing link no errors or nothing? Scrap what i said above i forgot to put the ?code=NEWPASS lol but this is what shows up for me Edited November 19, 2020 by SwiftGameR Oops just noticed you already fixed it haha Quote Link to comment Share on other sites More sharing options...
Sim Posted November 19, 2020 Author Share Posted November 19, 2020 (edited) 4 hours ago, SwiftGameR said: i just get a white page when accessing link no errors or nothing? That's what it's supposed to do. 🙂 I don't see how a cron class is more effective then a cron. Cron class has to check before executing "cronJobTypeCode". The cron automatically executes the "cronJobTypeCode" with nif statement check. Then calculating minute difference and updating the time in DB. I'm pretty sure that post makes sense @Dayo Edited November 19, 2020 by Sim 1 Quote Link to comment Share on other sites More sharing options...
Magictallguy Posted November 19, 2020 Share Posted November 19, 2020 Command Run ON != timestamp tickers Quote Link to comment Share on other sites More sharing options...
Dayo Posted November 19, 2020 Share Posted November 19, 2020 11 minutes ago, Sim said: I don't see how a cron class is more effective then a cron. Cron class has to check before executing "cronJobTypeCode". For you it may be simple to set up a cron ... What if the user does not know what a cron is? What if their host does not support crons? What if they don't change the default password? What if they break the code changing that password? The whole point of the module system in GL is to make installing modules seamless, all the tools are there to do it. I don't understand why you would want to do it that way, it just makes installing it a lot harder and when someone buys it and cant install it will you help them set up the cron? Quote Link to comment Share on other sites More sharing options...
rednspirited Posted November 19, 2020 Share Posted November 19, 2020 my crons dont work think its due to the server not wanting to be loaded down by all the minute changes. i use mccodes2 is there a program out there that can be added that does the same thing as cronjobs with out using the cronjobs? Quote Link to comment Share on other sites More sharing options...
Sim Posted November 19, 2020 Author Share Posted November 19, 2020 1 hour ago, Dayo said: For you it may be simple to set up a cron ... What if the user does not know what a cron is? What if their host does not support crons? What if they don't change the default password? What if they break the code changing that password? The whole point of the module system in GL is to make installing modules seamless, all the tools are there to do it. I don't understand why you would want to do it that way, it just makes installing it a lot harder and when someone buys it and cant install it will you help them set up the cron? I understand that, show that cron example when got chance 3 minutes ago, rednspirited said: my crons dont work think its due to the server not wanting to be loaded down by all the minute changes. i use mccodes2 is there a program out there that can be added that does the same thing as cronjobs with out using the cronjobs? Should be,. Gooogle automated url brower or something similar. Should let you enter a url every X amount of time. Quote Link to comment Share on other sites More sharing options...
Dayo Posted November 19, 2020 Share Posted November 19, 2020 2 minutes ago, Sim said: I understand that, show that cron example when got chance 2 Quote Link to comment Share on other sites More sharing options...
rednspirited Posted November 19, 2020 Share Posted November 19, 2020 ok i have tried to run my crons via and outside cronjob and they still dont seem to work. the outside source says no errors but nothing changes. i will also add that my time and the game time is different is there a way to set the game in my timezone? Quote Link to comment Share on other sites More sharing options...
Dayo Posted November 19, 2020 Share Posted November 19, 2020 26 minutes ago, rednspirited said: ok i have tried to run my crons via and outside cronjob and they still dont seem to work. the outside source says no errors but nothing changes. i will also add that my time and the game time is different is there a way to set the game in my timezone? This isnt the place to ask for help as its a different thread, try making a mew post in the McCodes forum. try here https://makewebgames.io/forum/65-engine-support/ Quote Link to comment Share on other sites More sharing options...
rednspirited Posted November 19, 2020 Share Posted November 19, 2020 sorry Quote Link to comment Share on other sites More sharing options...
SwiftGameR Posted November 19, 2020 Share Posted November 19, 2020 8 hours ago, Sim said: That's what it's supposed to do. 🙂 I don't see how a cron class is more effective then a cron. Cron class has to check before executing "cronJobTypeCode". The cron automatically executes the "cronJobTypeCode" with nif statement check. Then calculating minute difference and updating the time in DB. I'm pretty sure that post makes sense @Dayo Yea thats what meant to happen but stupid me forgot to put ?code=NEWPASS at the end so obvious reasons it shows as blank 😛 updated my op Quote Link to comment Share on other sites More sharing options...
sniko Posted November 19, 2020 Share Posted November 19, 2020 15 hours ago, Dayo said: I strongly advise against using crons I even made a PHP class to replace them with when I’m up I’ll link it Crons are ok to use, generally speaking. Why do you strongly advice against them? Quote Link to comment Share on other sites More sharing options...
Dayo Posted November 20, 2020 Share Posted November 20, 2020 10 hours ago, sniko said: Crons are ok to use, generally speaking. Why do you strongly advice against them? Yes crons are useful and have their place, i have them running on almost every server i maintain. But you have to look at the use case. If all you want to do is add 1 energy to an account every 60 seconds is a cron the best way to do it? Backing up my filesystem at 2am thats not something i want to do cronless ... I strongly advised against them in this scenario purely for ease of install and to help Sim out in the long run, the less support calls you have to answer the more development you can do and more money you make. Plus it gives the customer a better experience if they can just upload a zip file and everything is done. They don't have to chase the developer but because of time zones/weekends it takes 3/4 days to get it fixed. 3 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.