I started working as a web developer for a company a few months ago, managing many Coldfusion applications, among other things. Apparently, the planned task was created many years ago and worked perfectly until it stopped working under the control of one of the previous web developers, a couple of years ago. No one knows why he stopped working, but now my task is to fix it. This is my first job as a web developer, I did not know CF when I started my work (I barely knew that it existed), and I just started studying the planned tasks this morning, so just know that I'm a complete beginner.
The file is basic: it just updates the table in the database. If you run the URL in the browser (what they have been doing for the last couple of years), it works fine and everything updates. The scheduled task, which was supposed to run every night, did not update the file. I tried to enable the log in CF Admin, setting it to run at different times this morning, and also simply saying that it starts manually, and according to the log, it executes (without errors), but the file is not updated. I tried to comment on most of the file and simply told him to send a basic email message without any variables or anything else, but I get the same result.
Any ideas? I have no idea what is from here. I tried to find a solution on the Internet, but the only message that I found was similar to my situation is that people seem to suggest that the problem may be variables not available to the scheduler:
coldfusion scheduled task does not send emails
There are no variables on my page right now. I tried to run the task through CFSCHEDULE, as suggested on this page, but I got the same result as before. Some of the other suggestions (server monitor / FusionReactor / cflog) I just don't know how to do this, so I haven't tried them.
Edit: right now this is the only code on the page that is not commented out:
<cfmail to="[e-mail address]" from="[e-mail address]" Subject="is it running at all?"> Is it running? </cfmail>
Edit 2: Ok, now I have something like this before and after the email code:
<cflog text = "before e-mail" application = "yes" log = "Scheduler" type = "information">
I see log messages if I really go to the URL for the file (and an email is also sent), but not if I tell him to run a scheduled task from CF admin. Since the email sends when I open the file in the browser, I do not think this is a problem with the mail server.
Edit 3: Yes, email addresses are simple string strings. I'm not quite sure what you mean by the "coverage" of the Application.cfm file. At the top level of the site is the Application.cfm file, but not inside this particular subdirectory. There are a number of application area variables, but none of them are used in the file as of now.
Edit 4: Thanks for the explanation. As I said, it's all n00b when it comes to CF, so I appreciate the help. The Application.cfm page for this application checks to see if you are logged in, and if not, redirects you to the login page. Could this be a problem?
Edit 5: YAY! That seems to be the problem. Thank you thank you thank you! Lee, please send this as an answer so that I can select it. You are my hero!