If you do have an internal and external IP, you can extract either from the
ipconfig/ifconfig command via cfexecute


.:.:.:.:.:.:.:.:.:.:.:.:.:.
Bobby Hartsfield
http://acoderslife.com
http://cf4em.com

-----Original Message-----
From: Bobby Hartsfield [mailto:[email protected]] 
Sent: Friday, March 11, 2011 11:19 PM
To: cf-talk
Subject: RE: CFSchedule


If it is internal traffic, compare cgi.remote_addr to #createObject("java",
"java.net.InetAddress").getLocalHost().getHostAddress()#

Otherwise, you can restrict directory access to IP in all web servers. Just
restrict yours to the server's external address.

.:.:.:.:.:.:.:.:.:.:.:.:.:.
Bobby Hartsfield
http://acoderslife.com
http://cf4em.com

-----Original Message-----
From: Scott Williams [mailto:[email protected]] 
Sent: Friday, March 11, 2011 11:05 PM
To: cf-talk
Subject: Re: CFSchedule


Me likee...

How do I check to see if the IP is coming from the server?

 Scott 




----- Original Message ----
From: Phillip Vector <[email protected]>
To: cf-talk <[email protected]>
Sent: Fri, March 11, 2011 7:01:56 PM
Subject: Re: CFSchedule


As a side note, instead of putting it in a directory that anyone can
access and run your scheduled tasks, why not set up a check to see if
the IP is coming from the server. If it is, then bypass the logged in
check.

This way, no separate directory and also prevents people from running
it outside of your server. I use it myself and it works wonders. :)

On Fri, Mar 11, 2011 at 6:59 PM, Scott Williams
<[email protected]> wrote:
>
> Russ wins!
>
> That is indeed what was happening. In the Application.cfm file, there's
some
> code that checks to see if a user has logged in. I moved my files to a 
>directory
> with its own Application.cfm file, which contained no content, and now
it's
> working just fine.
>
>  Scott
>
>
>
>
> ----- Original Message ----
> From: Russ Michaels <[email protected]>
> To: cf-talk <[email protected]>
> Sent: Fri, March 11, 2011 6:44:36 PM
> Subject: Re: CFSchedule
>
>
> You have a form based login on that url, thus why the scheduled task wont
> run.The username/password fields in the cfschedule tag are for web server
> authentication. You need to exclude the scheduled task outside of your
login
> routine or use webserver authentication instead.
>
>
>
> On Fri, Mar 11, 2011 at 9:00 PM, Scott Williams
> <[email protected]>wrote:
>
>>
>> Hi all --
>>
>> I'm trying to use CFSchedule to have automatic emails sent. I don't have
>> access
>> to the CF Administrator, so I'm using the CFSchedule tag. So far it
hasn't
>> worked. Here's my code:
>>
>> <cfschedule action="update" task="eMailToDoList" operation="HTTPRequest"
>> url="http://www.studioregionperformers.com/DailyWhatToDoTodayEmail.cfm";
>> startdate="1/1/2011" starttime="12:00 PM" enddate="12/31/2011"
>> username="SF300"
>> password="Sw578668" interval=once resolveurl="no" publish="no">
>>
>> I included this code in a template, uploaded it to the website, then ran
>> the
>> page that contains it. No error messages, so knock wood.
>>
>> I next sent and ran a template with this code:
>>
>> <cfschedule action="run" task="eMailToDoList">
>>
>> My expectation was that the template
>> http://www.studioregionperformers.com/DailyWhatToDoTodayEmail.cfm would
>> run. I
>> did not receive an email. The DailyWhatToDoTodayEmail.cfm page works just
>> fine.
>>
>> Any idea about why this isn't working?
>>
>> Scott
>>
>>
>
>
>
> 







~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:342949
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm

Reply via email to