Re: Ajax Post Value on CF Side

2015-04-07 Thread Dean Lawrence

Once you convert it into a CF structure using deserializeJSON, you can then
use cfdump to see how CF interprets it.

On Tue, Apr 7, 2015 at 12:31 PM Robert Harrison rharri...@aimg.com wrote:


 Let me make this simpler.  The value being send via an ajax post is:

 Object {name: rid, value: 1}

 If I just want to dump that value/object how to I do it?   I have no idea
 what name CF see that as.

 Robert Harrison
 Full Stack Developer
 AIMG
 rharri...@aimg.com
 Main Office: 704-321-1234  ext.118
 Direct Line: 516-302-4345
 www.aimg.com



 

~|
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:360420
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax Post Value on CF Side

2015-04-07 Thread Jon Clausen

With JQuery:

var post_data = $('#myform').serializeArray();

$.post('/mycfpage',post_data,function(data){
//do stuff with JSON data here
var name = data.name;
var value = data.value;

//then manipulate the DOM from there

},'json');




On April 7, 2015 at 11:55:47 AM, Robert Harrison (rharri...@aimg.com) wrote:


I'm sending an Ajax post to a CF page. The post data looks like (below) in 
the counsel: 



Object {name: rid, value: 1} 



How in the heck to I get that value on the ColdFusion page? 





Robert Harrison 
Full Stack Developer 
AIMG 
mailto:rharri...@aimg.com rharri...@aimg.com 
Main Office: 704-321-1234 ext.118 
Direct Line: 516-302-4345 
http://www.aimg.com/ www.aimg.com 











~|
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:360415
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


RE: Ajax Post Value on CF Side

2015-04-07 Thread Robert Harrison

Let me make this simpler.  The value being send via an ajax post is:

Object {name: rid, value: 1}

If I just want to dump that value/object how to I do it?   I have no idea
what name CF see that as.

Robert Harrison
Full Stack Developer
AIMG
rharri...@aimg.com
Main Office: 704-321-1234  ext.118
Direct Line: 516-302-4345
www.aimg.com



~|
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:360419
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax Post Value on CF Side

2015-04-07 Thread Phillip Vector

Looks like a basic JSON value. Just parse it and you should have it put
into a variable.

or am I not understanding the question? I have yet to have my morning
coffee.

On Tue, Apr 7, 2015 at 8:55 AM, Robert Harrison rharri...@aimg.com wrote:


 I'm sending an Ajax post to a CF page.  The post data looks like (below) in
 the counsel:



 Object {name: rid, value: 1}



 How in the heck to I get that value on the ColdFusion page?





 Robert Harrison
 Full Stack Developer
 AIMG
  mailto:rharri...@aimg.com rharri...@aimg.com
 Main Office: 704-321-1234 ext.118
 Direct Line: 516-302-4345
  http://www.aimg.com/ www.aimg.com









 

~|
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:360414
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


RE: Ajax Post Value on CF Side

2015-04-07 Thread Robert Harrison

Solved.  The problem was I was overcomplicating this and treating it like
JSON just like everyone else has been advising. 

With an AJAX post, the string: Object {name: rid, value: 1}

Appears to Coldfusion as form values.  The values #form.name# and
#form.value# give me rid and 1.

Too simple, so it confused me.  


Robert Harrison
Full Stack Developer
AIMG
rharri...@aimg.com
Main Office: 704-321-1234  ext.118
Direct Line: 516-302-4345
www.aimg.com




~|
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:360421
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax Post Value on CF Side

2015-04-07 Thread Dean Lawrence

You can very easily convert it to a structure using the deserializeJSON
function in CF. Here is a link with some examples of working with JSON in
ColdFusion. http://www.learncfinaweek.com/week1/JSON/

On Tue, Apr 7, 2015 at 11:55 AM Robert Harrison rharri...@aimg.com wrote:


 I'm sending an Ajax post to a CF page.  The post data looks like (below) in
 the counsel:



 Object {name: rid, value: 1}



 How in the heck to I get that value on the ColdFusion page?





 Robert Harrison
 Full Stack Developer
 AIMG
  mailto:rharri...@aimg.com rharri...@aimg.com
 Main Office: 704-321-1234  ext.118
 Direct Line: 516-302-4345
  http://www.aimg.com/ www.aimg.com









 

~|
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:360418
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


RE: AJAX request returning 304

2014-08-27 Thread David Phelan

Donnie,

I don't see a reason why a cfheader tag wouldn't work, and if it fails it's 
easy enough to add in the missing tags.  Personally, I would convert it to a 
function in a cfc.

David Phelan
Web Developer
IT Security  Web Technologies

Emerging Health
Montefiore Information Technology
3 Odell Plaza, Yonkers, NY 10701
914-457-6465 Office
dphe...@emerginghealthit.com
www.emerginghealthit.com
www.montefiore.org


From: Donnie Carvajal donnie.carva...@transformyx.com
Sent: Wednesday, August 27, 2014 1:00 PM
To: cf-talk
Subject: AJAX request returning 304

I have an ajax request calling a ColdFusion template.  Each time the ajax 
function is called, the ColdFusion template should return the next 20 rows of a 
query.  I am running into an issue where the browser thinks the ColdFusion 
template hasn't changed since a 304 http status code is returned.  I don't have 
an html or head tag in the CF template, so I don't believe a cfheader tag will 
work.  Does anyone know how to prevent a CF template from returning a 304 http 
status code?

Thanks,

Donnie Carvajal



~|
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:359202
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax tutorial or book

2013-03-21 Thread Cameron Childress

On Thu, Mar 21, 2013 at 7:26 AM, Huff, Jerome P (IS) jerome.h...@ngc.comwrote:

 I have been using CF for 8 years and now have a project that I think ajax
 will be great for, but I don't understand how to get started.  I have
 looked at some tutorials, but I don't understand where to place the CFC's
 that will return the ajax data...  Can anyone recommend a good book or
 tutorial  for a beginner.  We are running CF 9 if that matters.


This is a pretty broad question. Typically you'd put the CFCs in your
webroot, just like a cfm file. If you are using a framework. or need some
security, you might end up putting them elsewhere.

-Cameron

...


~|
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:355120
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax tutorial or book

2013-03-21 Thread Mike Chabot

If you are interested in the AJAX features built into ColdFusion then the
best place to start would be the free Adobe CF manuals.
http://help.adobe.com/en_US/ColdFusion/9.0/Developing/index.html
That is all that I used when learning how to use the features, along with
experimentation in code.

-Mike Chabot


On Thu, Mar 21, 2013 at 7:26 AM, Huff, Jerome P (IS) jerome.h...@ngc.comwrote:


 I have been using CF for 8 years and now have a project that I think ajax
 will be great for, but I don't understand how to get started.  I have
 looked at some tutorials, but I don't understand where to place the CFC's
 that will return the ajax data...  Can anyone recommend a good book or
 tutorial  for a beginner.  We are running CF 9 if that matters.

 Thanks

 Jerome Huff



 

~|
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:355121
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax tutorial or book

2013-03-21 Thread Gerald Guido

There is a bunch of stuff on Ray Camden's site.

http://www.raymondcamden.com/search.cfm?search=cfccategory=BDF5ED6A-19B9-E658-9D5AB2B5C94A6A95

It might take a bit to tease it out. You might want to take a look at Ben
Nadel's site and search for jQuery and CFC.

Here is one that I found. It might be a bit dense to get started but he
documents things nicely.
http://www.bennadel.com/blog/1515-Ask-Ben-Building-An-AJAX-jQuery-And-ColdFusion-Powered-Application.htm

That should get you going. Have fun!

G!


On Thu, Mar 21, 2013 at 7:26 AM, Huff, Jerome P (IS) jerome.h...@ngc.comwrote:


 I have been using CF for 8 years and now have a project that I think ajax
 will be great for, but I don't understand how to get started.  I have
 looked at some tutorials, but I don't understand where to place the CFC's
 that will return the ajax data...  Can anyone recommend a good book or
 tutorial  for a beginner.  We are running CF 9 if that matters.

 Thanks

 Jerome Huff



 

~|
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:355123
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax inserts / updates and CF

2013-01-10 Thread Larry Lyons

You don't necessarily have to turn it off. Just select dockable.cfm - that I 
believe allows you to have debugging on while using Ajax. 

That said, I've found it much better simply to use the firebug and web tools 
plugins in either FF or Chrome to debug Ajax requests.

 This is a great move and highly recommended for the reasons you 
 mention, but also if you plan to go mobile. Just a tip for you...make 
 sure you turn CF debugging OFF when testing your jquery ajax calls 
 because if you leave it on, it may appear that your ajax is not 
 working at all with no js errors. Also, I would recommend you use 
 firefox as a browser and firebug to debug your jquery code. Hope this 
 helps.
 
 Hi Folks,
 
 We're getting ready to implement some ajax code in our application to 
 enable
 queries (esp inserts and updates) to run without having to do a full 
 page
 refresh (the main goal being to just improve page load performance).
 There's obviously a lot of info out there on this topic and I'm 
 interested
 in getting a little feedback about what might be best or most 
 appropriate.
 For instance, are there any recommended examples / tutorials for 
 doing this
 with CF?  Would this sort of thing likely use jquery or just straight 
 custom
 javascript?
 
 Many thanks in advance.
 
 Nick 

~|
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:353822
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax inserts / updates and CF

2013-01-09 Thread Theresa Temple

This is a great move and highly recommended for the reasons you mention, but 
also if you plan to go mobile. Just a tip for you...make sure you turn CF 
debugging OFF when testing your jquery ajax calls because if you leave it on, 
it may appear that your ajax is not working at all with no js errors. Also, I 
would recommend you use firefox as a browser and firebug to debug your jquery 
code. Hope this helps.

Hi Folks,

We're getting ready to implement some ajax code in our application to enable
queries (esp inserts and updates) to run without having to do a full page
refresh (the main goal being to just improve page load performance).
There's obviously a lot of info out there on this topic and I'm interested
in getting a little feedback about what might be best or most appropriate.
For instance, are there any recommended examples / tutorials for doing this
with CF?  Would this sort of thing likely use jquery or just straight custom
javascript?

Many thanks in advance.

Nick 

~|
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:353817
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax inserts / updates and CF

2013-01-09 Thread Steve 'Cutter' Blades

If you are on a properly patched (and updated) version of CF 9.01 or 
higher, then CF Debugging will/should have no effect on your ajax calls, 
if you are directly calling a cfc.

Steve 'Cutter' Blades
Adobe Community Professional
Adobe Certified Expert
Advanced Macromedia ColdFusion MX 7 Developer

http://cutterscrossing.com


Co-Author Learning Ext JS 3.2 Packt Publishing 2010
https://www.packtpub.com/learning-ext-js-3-2-for-building-dynamic-desktop-style-user-interfaces/book

The best way to predict the future is to help create it

On 1/9/2013 2:15 PM, Theresa Temple wrote:
 This is a great move and highly recommended for the reasons you mention, but 
 also if you plan to go mobile. Just a tip for you...make sure you turn CF 
 debugging OFF when testing your jquery ajax calls because if you leave it on, 
 it may appear that your ajax is not working at all with no js errors. Also, I 
 would recommend you use firefox as a browser and firebug to debug your jquery 
 code. Hope this helps.

 Hi Folks,

 We're getting ready to implement some ajax code in our application to enable
 queries (esp inserts and updates) to run without having to do a full page
 refresh (the main goal being to just improve page load performance).
 There's obviously a lot of info out there on this topic and I'm interested
 in getting a little feedback about what might be best or most appropriate.
 For instance, are there any recommended examples / tutorials for doing this
 with CF?  Would this sort of thing likely use jquery or just straight custom
 javascript?

 Many thanks in advance.

 Nick
 

~|
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:353820
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax inserts / updates and CF

2013-01-08 Thread Russ Michaels

I would really suggest using the stuff built into CF.
Your better off using jquery, there are tons of tutorials out ther eon
jquery and jquery with CF.


On Mon, Jan 7, 2013 at 11:28 PM, Nick Gleason n.glea...@citysoft.comwrote:


 Hi Folks,

 We're getting ready to implement some ajax code in our application to
 enable
 queries (esp inserts and updates) to run without having to do a full page
 refresh (the main goal being to just improve page load performance).
 There's obviously a lot of info out there on this topic and I'm interested
 in getting a little feedback about what might be best or most appropriate.
 For instance, are there any recommended examples / tutorials for doing this
 with CF?  Would this sort of thing likely use jquery or just straight
 custom
 javascript?

 Many thanks in advance.

 Nick





 

~|
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:353807
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


RE: Ajax inserts / updates and CF

2013-01-08 Thread Rick Faircloth

Russ, were you advising Nick to not use the
stuff built into CF?

If so, I agree.  jQuery is the way to go. I tried
working with CF's functionality, jQuery was much
easier for me to learn.

Rick

-Original Message-
From: Russ Michaels [mailto:r...@michaels.me.uk] 
Sent: Tuesday, January 08, 2013 8:58 AM
To: cf-talk
Subject: Re: Ajax inserts / updates and CF


I would really suggest using the stuff built into CF.
Your better off using jquery, there are tons of tutorials out ther eon
jquery and jquery with CF.


On Mon, Jan 7, 2013 at 11:28 PM, Nick Gleason n.glea...@citysoft.comwrote:


 Hi Folks,

 We're getting ready to implement some ajax code in our application to
 enable
 queries (esp inserts and updates) to run without having to do a full page
 refresh (the main goal being to just improve page load performance).
 There's obviously a lot of info out there on this topic and I'm interested
 in getting a little feedback about what might be best or most appropriate.
 For instance, are there any recommended examples / tutorials for doing this
 with CF?  Would this sort of thing likely use jquery or just straight
 custom
 javascript?

 Many thanks in advance.

 Nick





 



~|
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:353813
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax inserts / updates and CF

2013-01-08 Thread Russ Michaels

yes, I mistyped, should have said I suggest NOT using :-)



On Tue, Jan 8, 2013 at 6:48 PM, Rick Faircloth r...@whitestonemedia.comwrote:


 Russ, were you advising Nick to not use the
 stuff built into CF?

 If so, I agree.  jQuery is the way to go. I tried
 working with CF's functionality, jQuery was much
 easier for me to learn.

 Rick

 -Original Message-
 From: Russ Michaels [mailto:r...@michaels.me.uk]
 Sent: Tuesday, January 08, 2013 8:58 AM
 To: cf-talk
 Subject: Re: Ajax inserts / updates and CF


 I would really suggest using the stuff built into CF.
 Your better off using jquery, there are tons of tutorials out ther eon
 jquery and jquery with CF.


 On Mon, Jan 7, 2013 at 11:28 PM, Nick Gleason n.glea...@citysoft.com
 wrote:

 
  Hi Folks,
 
  We're getting ready to implement some ajax code in our application to
  enable
  queries (esp inserts and updates) to run without having to do a full page
  refresh (the main goal being to just improve page load performance).
  There's obviously a lot of info out there on this topic and I'm
 interested
  in getting a little feedback about what might be best or most
 appropriate.
  For instance, are there any recommended examples / tutorials for doing
 this
  with CF?  Would this sort of thing likely use jquery or just straight
  custom
  javascript?
 
  Many thanks in advance.
 
  Nick
 
 
 
 
 
 



 

~|
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:353814
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax inserts / updates and CF

2013-01-08 Thread Raymond Camden

I would advise being a bit more careful about this. I agree - don't use the
stuff built in CF directly - but I think we are all talking about the CF
UI stuff. I consider the CFC/returnFormat=json as part of CF's Ajax
support and I'd definitely recommend using it.


On Tue, Jan 8, 2013 at 1:05 PM, Russ Michaels r...@michaels.me.uk wrote:


 yes, I mistyped, should have said I suggest NOT using :-)



 On Tue, Jan 8, 2013 at 6:48 PM, Rick Faircloth r...@whitestonemedia.com
 wrote:

 
  Russ, were you advising Nick to not use the
  stuff built into CF?
 
  If so, I agree.  jQuery is the way to go. I tried
  working with CF's functionality, jQuery was much
  easier for me to learn.
 
  Rick
 
  -Original Message-
  From: Russ Michaels [mailto:r...@michaels.me.uk]
  Sent: Tuesday, January 08, 2013 8:58 AM
  To: cf-talk
  Subject: Re: Ajax inserts / updates and CF
 
 
  I would really suggest using the stuff built into CF.
  Your better off using jquery, there are tons of tutorials out ther eon
  jquery and jquery with CF.
 
 
  On Mon, Jan 7, 2013 at 11:28 PM, Nick Gleason n.glea...@citysoft.com
  wrote:
 
  
   Hi Folks,
  
   We're getting ready to implement some ajax code in our application to
   enable
   queries (esp inserts and updates) to run without having to do a full
 page
   refresh (the main goal being to just improve page load performance).
   There's obviously a lot of info out there on this topic and I'm
  interested
   in getting a little feedback about what might be best or most
  appropriate.
   For instance, are there any recommended examples / tutorials for doing
  this
   with CF?  Would this sort of thing likely use jquery or just straight
   custom
   javascript?
  
   Many thanks in advance.
  
   Nick
  
  
  
  
  
  
 
 
 
 

 

~|
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:353815
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: AJAX Issue

2012-12-23 Thread Bruce Sorge

Thanks for the Video Ray. It was very helpful for debugging another part of 
this site. Finally finished it though bug free and functions the way I want.

Bruce
On Dec 20, 2012, at 9:55 PM, Raymond Camden raymondcam...@gmail.com wrote:

 
 Here is a video demonstrating chrome dev tools:
 
 http://www.raymondcamden.com/index.cfm/2011/6/15/Example-of-using-Chrome-Dev-tools-to-solve-Ajax-issues
 
 


~|
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:353652
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: AJAX Issue

2012-12-23 Thread Raymond Camden

You are most welcome.


On Sun, Dec 23, 2012 at 5:14 PM, Bruce Sorge sor...@gmail.com wrote:


 Thanks for the Video Ray. It was very helpful for debugging another part
 of this site. Finally finished it though bug free and functions the way I
 want.

 Bruce
 On Dec 20, 2012, at 9:55 PM, Raymond Camden raymondcam...@gmail.com
 wrote:

 
  Here is a video demonstrating chrome dev tools:
 
 
 http://www.raymondcamden.com/index.cfm/2011/6/15/Example-of-using-Chrome-Dev-tools-to-solve-Ajax-issues
 
 


 

~|
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:353658
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: AJAX Issue

2012-12-20 Thread Raymond Camden

I'll take a look, but I need to nitpick something. AJAX isn't a language.
It is simply the name of a technique used in JavaScript to communicate with
a server. Spry uses AJAX too. (But don't use Spry anymore. It's old like
Donkey Kong.)


On Thu, Dec 20, 2012 at 7:49 PM, Bruce Sorge sor...@gmail.com wrote:


 OK, so I gave up on the Spry version of the database validation and moved
 onto AJAX (a language I really don't know a lot about but I am slowly
 figuring it out). Anyway, I have the code working the way I want with the
 exception that when the validation is done, whether the code is valid or
 not, the page is reloading and showing an overlay or something of the page.
 If you go to http://www.makeaherodonations.com/themovement/ you'll see
 what I am talking about. It's weird and I have been trying to figure this
 out. Here is the script:

 script src=js/jquery.js type=text/javascript/script
 script type=text/javascript
 pic1 = new Image(16, 16);
 pic1.src = images/loader.gif;

 $(document).ready(function(){

 $(#orgname).change(function() {

 var usr = $(#orgname).val();

 if(usr.length = 2)
 {
 $(#status).html('img align=absmiddle src=images/loader.gif /
 Checking Code...');

 $.ajax({
 type: POST,
 url: checkcode.cfm,
 data: orgname=+ usr,
 success: function(msg){

 $(#status).ajaxComplete(function(event, request, settings){

 if(msg == 'OK')
 {
 $(#orgname).removeClass('object_error'); // if necessary
 $(#orgname).addClass(object_ok);
 $(this).html(' img align=absmiddle src=images/accepted.png / ');
 }
 else
 {
 $(#orgname).removeClass('object_ok'); // if necessary
 $(#orgname).addClass(object_error);
 $(this).html(msg);
 }});}});}
 else
 {
 $(#status).html('The Code should have at least 2 characters.');
 $(#orgname).removeClass('object_ok'); // if necessary
 $(#orgname).addClass(object_error);
 }});});

 //--

 /script

 I think that I'll have to head to the bookstore tomorrow and get me an
 AJAX book. It seems pretty cool and something that I can use in the future.

 Bruce

 

~|
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:353591
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: AJAX Issue

2012-12-20 Thread Raymond Camden

As to your error, it is very obvious if you use the Chrome Dev Tools. I
cannot stress this enough. You *need* to learn how to use your browser dev
tools as it makes this stuff a heck of a lot easier.

I opened it up in Chrome, went to the Network panel, filtered on XHR. I
then entered 88 in the first form field.

I then saw a big ole graphic load. Why? It's obvious if you look at the
result in the Network panel. Your server returned this:

!doctype html
html
head
meta charset=UTF-8
meta name=Keywords content=The Movement, Make A Hero, makeahero.org,
veterans, disabled american veterans, veterans of forign wars, Iraq
veteran, Afghanistan veteran, disabled veteran, disabilities, the movement
DVD/
meta name=Description content=For The Movement DVD Free Download/
link type=text/css
href=Styles/Movement.csshttp://www.makeaherodonations.com/themovement/Styles/Movement.css
 rel=stylesheet
link rel=shortcut icon type=image/x-icon
href=favicon.icohttp://www.makeaherodonations.com/themovement/favicon.ico




titleThe Movement DVD Download - Information/title
/head

header
div id=head
 /div
 DIV id=navbar
 /DIV
 /header



nav
img 
src=images/MAH-ski.jpeghttp://www.makeaherodonations.com/themovement/images/MAH-ski.jpeg
 alt=The Movement Movie Poster Image /
/nav span style=color: red;The Code b 88/b is an invalid code.
Please ree-enter your code./span footer
pa href=http://www.makeahero.org; target=newimg
src=images/logo.pnghttp://www.makeaherodonations.com/themovement/images/logo.png
 alt=Make A Hero Logo //aBR /
emHelping individuals with disabilities enjoy the freedom of sports and
recreation/em/p
p class=align
Thank you for your interest in Make A Hero's first film, The Movement! If
you would like to use this film as a fund-raiser please email a href=
mailto:i...@makeahero.orghttp://www.makeaherodonations.com/themovement/mailto:i...@makeahero.org
i...@makeahero.org/a. For more information about our organization or
ways that you can support our cause, please visit a href=
http://www.makeahero.org; target=newhttp://makeahero.org/a or email a
href=mailto:i...@makeahero.orghttp://www.makeaherodonations.com/themovement/mailto:i...@makeahero.org
i...@makeahero.org/a.
/footer

/body
/html

Most likely you ONLY wanted the The code... part. Most likely your CF
code is wrapping everything with a header and footer. You need to stop
doing that. :)



On Thu, Dec 20, 2012 at 8:51 PM, Raymond Camden raymondcam...@gmail.comwrote:

 I'll take a look, but I need to nitpick something. AJAX isn't a language.
 It is simply the name of a technique used in JavaScript to communicate with
 a server. Spry uses AJAX too. (But don't use Spry anymore. It's old like
 Donkey Kong.)


 On Thu, Dec 20, 2012 at 7:49 PM, Bruce Sorge sor...@gmail.com wrote:


 OK, so I gave up on the Spry version of the database validation and moved
 onto AJAX (a language I really don't know a lot about but I am slowly
 figuring it out). Anyway, I have the code working the way I want with the
 exception that when the validation is done, whether the code is valid or
 not, the page is reloading and showing an overlay or something of the page.
 If you go to http://www.makeaherodonations.com/themovement/ you'll see
 what I am talking about. It's weird and I have been trying to figure this
 out. Here is the script:

 script src=js/jquery.js type=text/javascript/script
 script type=text/javascript
 pic1 = new Image(16, 16);
 pic1.src = images/loader.gif;

 $(document).ready(function(){

 $(#orgname).change(function() {

 var usr = $(#orgname).val();

 if(usr.length = 2)
 {
 $(#status).html('img align=absmiddle src=images/loader.gif /
 Checking Code...');

 $.ajax({
 type: POST,
 url: checkcode.cfm,
 data: orgname=+ usr,
 success: function(msg){

 $(#status).ajaxComplete(function(event, request, settings){

 if(msg == 'OK')
 {
 $(#orgname).removeClass('object_error'); // if necessary
 $(#orgname).addClass(object_ok);
 $(this).html(' img align=absmiddle src=images/accepted.png / ');
 }
 else
 {
 $(#orgname).removeClass('object_ok'); // if necessary
 $(#orgname).addClass(object_error);
 $(this).html(msg);
 }});}});}
 else
 {
 $(#status).html('The Code should have at least 2 characters.');
 $(#orgname).removeClass('object_ok'); // if necessary
 $(#orgname).addClass(object_error);
 }});});

 //--

 /script

 I think that I'll have to head to the bookstore tomorrow and get me an
 AJAX book. It seems pretty cool and something that I can use in the future.

 Bruce

 

~|
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:353592
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: AJAX Issue

2012-12-20 Thread Raymond Camden

Here is a video demonstrating chrome dev tools:

http://www.raymondcamden.com/index.cfm/2011/6/15/Example-of-using-Chrome-Dev-tools-to-solve-Ajax-issues


On Thu, Dec 20, 2012 at 8:54 PM, Raymond Camden raymondcam...@gmail.comwrote:

 As to your error, it is very obvious if you use the Chrome Dev Tools. I
 cannot stress this enough. You *need* to learn how to use your browser dev
 tools as it makes this stuff a heck of a lot easier.

 I opened it up in Chrome, went to the Network panel, filtered on XHR. I
 then entered 88 in the first form field.

 I then saw a big ole graphic load. Why? It's obvious if you look at the
 result in the Network panel. Your server returned this:

 !doctype html
 html
 head
 meta charset=UTF-8
 meta name=Keywords content=The Movement, Make A Hero, makeahero.org,
 veterans, disabled american veterans, veterans of forign wars, Iraq
 veteran, Afghanistan veteran, disabled veteran, disabilities, the movement
 DVD/
 meta name=Description content=For The Movement DVD Free Download/
 link type=text/css 
 href=Styles/Movement.csshttp://www.makeaherodonations.com/themovement/Styles/Movement.css
  rel=stylesheet
 link rel=shortcut icon type=image/x-icon 
 href=favicon.icohttp://www.makeaherodonations.com/themovement/favicon.ico
 



 titleThe Movement DVD Download - Information/title
 /head

 header
 div id=head
  /div
  DIV id=navbar
  /DIV
  /header



 nav
  img 
 src=images/MAH-ski.jpeghttp://www.makeaherodonations.com/themovement/images/MAH-ski.jpeg
  alt=The Movement Movie Poster Image /
 /nav span style=color: red;The Code b 88/b is an invalid code.
 Please ree-enter your code./span footer
  pa href=http://www.makeahero.org; target=newimg src=
 images/logo.pnghttp://www.makeaherodonations.com/themovement/images/logo.png
  alt=Make A Hero Logo //aBR /
  emHelping individuals with disabilities enjoy the freedom of sports
 and recreation/em/p
  p class=align
  Thank you for your interest in Make A Hero's first film, The Movement! If
 you would like to use this film as a fund-raiser please email a href=
 mailto:i...@makeahero.orghttp://www.makeaherodonations.com/themovement/mailto:i...@makeahero.org
 i...@makeahero.org/a. For more information about our organization or
 ways that you can support our cause, please visit a href=
 http://www.makeahero.org; target=newhttp://makeahero.org/a or email 
 a 
 href=mailto:i...@makeahero.orghttp://www.makeaherodonations.com/themovement/mailto:i...@makeahero.org
 i...@makeahero.org/a.
 /footer

 /body
 /html

 Most likely you ONLY wanted the The code... part. Most likely your CF
 code is wrapping everything with a header and footer. You need to stop
 doing that. :)



 On Thu, Dec 20, 2012 at 8:51 PM, Raymond Camden 
 raymondcam...@gmail.comwrote:

 I'll take a look, but I need to nitpick something. AJAX isn't a language.
 It is simply the name of a technique used in JavaScript to communicate with
 a server. Spry uses AJAX too. (But don't use Spry anymore. It's old like
 Donkey Kong.)


 On Thu, Dec 20, 2012 at 7:49 PM, Bruce Sorge sor...@gmail.com wrote:


 OK, so I gave up on the Spry version of the database validation and
 moved onto AJAX (a language I really don't know a lot about but I am slowly
 figuring it out). Anyway, I have the code working the way I want with the
 exception that when the validation is done, whether the code is valid or
 not, the page is reloading and showing an overlay or something of the page.
 If you go to http://www.makeaherodonations.com/themovement/ you'll see
 what I am talking about. It's weird and I have been trying to figure this
 out. Here is the script:

 script src=js/jquery.js type=text/javascript/script
 script type=text/javascript
 pic1 = new Image(16, 16);
 pic1.src = images/loader.gif;

 $(document).ready(function(){

 $(#orgname).change(function() {

 var usr = $(#orgname).val();

 if(usr.length = 2)
 {
 $(#status).html('img align=absmiddle src=images/loader.gif /
 Checking Code...');

 $.ajax({
 type: POST,
 url: checkcode.cfm,
 data: orgname=+ usr,
 success: function(msg){

 $(#status).ajaxComplete(function(event, request, settings){

 if(msg == 'OK')
 {
 $(#orgname).removeClass('object_error'); // if necessary
 $(#orgname).addClass(object_ok);
 $(this).html(' img align=absmiddle src=images/accepted.png / ');
 }
 else
 {
 $(#orgname).removeClass('object_ok'); // if necessary
 $(#orgname).addClass(object_error);
 $(this).html(msg);
 }});}});}
 else
 {
 $(#status).html('The Code should have at least 2 characters.');
 $(#orgname).removeClass('object_ok'); // if necessary
 $(#orgname).addClass(object_error);
 }});});

 //--

 /script

 I think that I'll have to head to the bookstore tomorrow and get me an
 AJAX book. It seems pretty cool and something that I can use in the future.

 Bruce

 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 

Re: AJAX Issue

2012-12-20 Thread Bruce Sorge

Thanks Ray, I'll look into this for sure. And yeah, I am wrapping all the pages 
in a header, footer and nab in the application.cfc. I'll switch it to an 
include in the page instead. I've been out of web development for about 4 years 
and have obviously fallen behind the knowledge curve. Thanks for the input I'll 
work on this stuff tomorrow. 

Sent from my iPhone 4S. 

On Dec 20, 2012, at 9:55 PM, Raymond Camden raymondcam...@gmail.com wrote:

 
 Here is a video demonstrating chrome dev tools:
 
 http://www.raymondcamden.com/index.cfm/2011/6/15/Example-of-using-Chrome-Dev-tools-to-solve-Ajax-issues
 
 
 On Thu, Dec 20, 2012 at 8:54 PM, Raymond Camden 
 raymondcam...@gmail.comwrote:
 
 As to your error, it is very obvious if you use the Chrome Dev Tools. I
 cannot stress this enough. You *need* to learn how to use your browser dev
 tools as it makes this stuff a heck of a lot easier.
 
 I opened it up in Chrome, went to the Network panel, filtered on XHR. I
 then entered 88 in the first form field.
 
 I then saw a big ole graphic load. Why? It's obvious if you look at the
 result in the Network panel. Your server returned this:
 
 !doctype html
 html
 head
 meta charset=UTF-8
 meta name=Keywords content=The Movement, Make A Hero, makeahero.org,
 veterans, disabled american veterans, veterans of forign wars, Iraq
 veteran, Afghanistan veteran, disabled veteran, disabilities, the movement
 DVD/
 meta name=Description content=For The Movement DVD Free Download/
 link type=text/css 
 href=Styles/Movement.csshttp://www.makeaherodonations.com/themovement/Styles/Movement.css
  rel=stylesheet
 link rel=shortcut icon type=image/x-icon 
 href=favicon.icohttp://www.makeaherodonations.com/themovement/favicon.ico
 
 
 
 
 titleThe Movement DVD Download - Information/title
 /head
 
 header
 div id=head
 /div
 DIV id=navbar
 /DIV
 /header
 
 
 
 nav
 img 
 src=images/MAH-ski.jpeghttp://www.makeaherodonations.com/themovement/images/MAH-ski.jpeg
  alt=The Movement Movie Poster Image /
 /nav span style=color: red;The Code b 88/b is an invalid code.
 Please ree-enter your code./span footer
 pa href=http://www.makeahero.org; target=newimg src=
 images/logo.pnghttp://www.makeaherodonations.com/themovement/images/logo.png
  alt=Make A Hero Logo //aBR /
 emHelping individuals with disabilities enjoy the freedom of sports
 and recreation/em/p
 p class=align
 Thank you for your interest in Make A Hero's first film, The Movement! If
 you would like to use this film as a fund-raiser please email a href=
 mailto:i...@makeahero.orghttp://www.makeaherodonations.com/themovement/mailto:i...@makeahero.org
 i...@makeahero.org/a. For more information about our organization or
 ways that you can support our cause, please visit a href=
 http://www.makeahero.org; target=newhttp://makeahero.org/a or email 
 a 
 href=mailto:i...@makeahero.orghttp://www.makeaherodonations.com/themovement/mailto:i...@makeahero.org
 i...@makeahero.org/a.
 /footer
 
 /body
 /html
 
 Most likely you ONLY wanted the The code... part. Most likely your CF
 code is wrapping everything with a header and footer. You need to stop
 doing that. :)
 
 
 
 On Thu, Dec 20, 2012 at 8:51 PM, Raymond Camden 
 raymondcam...@gmail.comwrote:
 
 I'll take a look, but I need to nitpick something. AJAX isn't a language.
 It is simply the name of a technique used in JavaScript to communicate with
 a server. Spry uses AJAX too. (But don't use Spry anymore. It's old like
 Donkey Kong.)
 
 
 On Thu, Dec 20, 2012 at 7:49 PM, Bruce Sorge sor...@gmail.com wrote:
 
 
 OK, so I gave up on the Spry version of the database validation and
 moved onto AJAX (a language I really don't know a lot about but I am slowly
 figuring it out). Anyway, I have the code working the way I want with the
 exception that when the validation is done, whether the code is valid or
 not, the page is reloading and showing an overlay or something of the page.
 If you go to http://www.makeaherodonations.com/themovement/ you'll see
 what I am talking about. It's weird and I have been trying to figure this
 out. Here is the script:
 
 script src=js/jquery.js type=text/javascript/script
 script type=text/javascript
 pic1 = new Image(16, 16);
 pic1.src = images/loader.gif;
 
 $(document).ready(function(){
 
 $(#orgname).change(function() {
 
 var usr = $(#orgname).val();
 
 if(usr.length = 2)
 {
 $(#status).html('img align=absmiddle src=images/loader.gif /
 Checking Code...');
 
 $.ajax({
 type: POST,
 url: checkcode.cfm,
 data: orgname=+ usr,
 success: function(msg){
 
 $(#status).ajaxComplete(function(event, request, settings){
 
 if(msg == 'OK')
 {
 $(#orgname).removeClass('object_error'); // if necessary
 $(#orgname).addClass(object_ok);
 $(this).html(' img align=absmiddle src=images/accepted.png / ');
 }
 else
 {
 $(#orgname).removeClass('object_ok'); // if necessary
 $(#orgname).addClass(object_error);
 $(this).html(msg);
 }});}});}
 else
 {
 $(#status).html('The Code should have at least 2 characters.');
 

RE: ajax tutorials for form objects

2011-01-29 Thread Rick Faircloth

+1

-Original Message-
From: Michael Grant [mailto:mgr...@modus.bz] 
Sent: Friday, January 28, 2011 7:39 PM
To: cf-talk
Subject: Re: ajax tutorials for form objects


I generally prefer to use JQuery over CF's built in stuff. I find it to be
more steamlined. Plus I think you can probably find more tuts for the JQuery
approach.

This tut has a nice approach and actually explains ajax a bit. Might be a
good start: http://articles.sitepoint.com/article/ajax-jquery
Ofcourse the JQuery website has great api docs.



On Fri, Jan 28, 2011 at 2:21 PM, Teed Younger
teedyoun...@hotmail.comwrote:


 Hi, once again seeking some advice/help with a project. Can anyone direct
 me to a good ajax tutorial that covers how to take form inputs/values and
 then display results using an click event.

 What I have is a form with only two inputs. The user types in numeric
 values in each form field, then several mathmatical calculations are
 performed and the results are shown.

 Anyway, still very new to ajax, and not even sure I can do this with just
a
 simple ajax script, but any nudges in the right direction would be greatly
 appreciated.

 



~|
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:341694
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: ajax tutorials for form objects

2011-01-29 Thread Gerald Guido

+1 to Rick's +1 to Michael's suggestion.

One of the great things about CF is the cfc's can automatically return
arrays in JSON format that jQuery can consume.  Like so:

cffunction name=default returntype=Array returnformat=JSON 

I can tell you first hand that formatting JSON by hand from a data structure
like a query can be a total PITA. So in that respect, returnformat=JSON is
a Godsend for AJAX development.

As far as Ajax tutes go, the documentation on the jQuery site for it's AJAX
features is a great place to start

http://api.jquery.com/category/ajax/

Also, the docs on CFSelect and cfinput that use the bind attribute is also a
great place to start.

http://livedocs.adobe.com/coldfusion/8/htmldocs/help.html?content=Tags_r-s_14.html

CF takes a LOT of the grunt work out of working with AJAXish functionality.

HTH,
G!


On Sat, Jan 29, 2011 at 10:06 AM, Rick Faircloth
r...@whitestonemedia.comwrote:


 +1

 -Original Message-
 From: Michael Grant [mailto:mgr...@modus.bz]
 Sent: Friday, January 28, 2011 7:39 PM
 To: cf-talk
 Subject: Re: ajax tutorials for form objects


 I generally prefer to use JQuery over CF's built in stuff. I find it to be
 more steamlined. Plus I think you can probably find more tuts for the
 JQuery
 approach.

 This tut has a nice approach and actually explains ajax a bit. Might be a
 good start: http://articles.sitepoint.com/article/ajax-jquery
 Ofcourse the JQuery website has great api docs.



 On Fri, Jan 28, 2011 at 2:21 PM, Teed Younger
 teedyoun...@hotmail.comwrote:

 
  Hi, once again seeking some advice/help with a project. Can anyone direct
  me to a good ajax tutorial that covers how to take form inputs/values and
  then display results using an click event.
 
  What I have is a form with only two inputs. The user types in numeric
  values in each form field, then several mathmatical calculations are
  performed and the results are shown.
 
  Anyway, still very new to ajax, and not even sure I can do this with just
 a
  simple ajax script, but any nudges in the right direction would be
 greatly
  appreciated.
 
 



 

~|
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:341698
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


RE: ajax tutorials for form objects

2011-01-28 Thread Andrew Scott

So you want to use Ajax to go to the server and get some results?

Have a look at ColdFusions cfAjaxProxy tag.


Regards,
Andrew Scott
http://www.andyscott.id.au/


 -Original Message-
 From: Teed Younger [mailto:teedyoun...@hotmail.com]
 Sent: Saturday, 29 January 2011 6:22 AM
 To: cf-talk
 Subject: ajax tutorials for form objects
 
 
 Hi, once again seeking some advice/help with a project. Can anyone direct
 me to a good ajax tutorial that covers how to take form inputs/values and
 then display results using an click event.
 
 What I have is a form with only two inputs. The user types in numeric
values
 in each form field, then several mathmatical calculations are performed
and
 the results are shown.
 
 Anyway, still very new to ajax, and not even sure I can do this with just
a
 simple ajax script, but any nudges in the right direction would be greatly
 appreciated.
 
 ~~
 ~~~|
 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:341665
 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
 Unsubscribe: http://www.houseoffusion.com/groups/cf-
 talk/unsubscribe.cfm


~|
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:341669
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: ajax tutorials for form objects

2011-01-28 Thread Michael Grant

I generally prefer to use JQuery over CF's built in stuff. I find it to be
more steamlined. Plus I think you can probably find more tuts for the JQuery
approach.

This tut has a nice approach and actually explains ajax a bit. Might be a
good start: http://articles.sitepoint.com/article/ajax-jquery
Ofcourse the JQuery website has great api docs.



On Fri, Jan 28, 2011 at 2:21 PM, Teed Younger teedyoun...@hotmail.comwrote:


 Hi, once again seeking some advice/help with a project. Can anyone direct
 me to a good ajax tutorial that covers how to take form inputs/values and
 then display results using an click event.

 What I have is a form with only two inputs. The user types in numeric
 values in each form field, then several mathmatical calculations are
 performed and the results are shown.

 Anyway, still very new to ajax, and not even sure I can do this with just a
 simple ajax script, but any nudges in the right direction would be greatly
 appreciated.

 

~|
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:341678
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax + 2 functions = error

2010-11-10 Thread Jessica Kennedy

ok, tried this, it failed on the var scoped line instead of the structAppend 
line... same error message though.

I have an ajax handler method which instantiates all of my ajax calls-- also 
with an access=public.  very strange.  I am able to call other methods, but I 
have to create an object for the cfc and then call the method within it.  seems 
ridiculous to do this for the component my code is already in.


try replacing your failing line with these 2:

var stuctTest = getTest();
structAppend(returnData, structTest);

Azadi


On 10/11/2010 09:56 , Jessica Kennedy wrote:
 structAppend(returnData, getTest());//failing here! 

~|
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:339074
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax + 2 functions = error

2010-11-10 Thread Azadi Saryev

is your component cached in some persistent scope (session/application)?
it sounds like you have added the getTest() method after the component 
has been instantiated - and thus its instance has no idea about the 
getTest() method added later...

Azadi

On 10/11/2010 21:50 , Jessica Kennedy wrote:
 ok, tried this, it failed on the var scoped line instead of the structAppend 
 line... same error message though.

 I have an ajax handler method which instantiates all of my ajax calls-- also 
 with an access=public.  very strange.  I am able to call other methods, but 
 I have to create an object for the cfc and then call the method within it.  
 seems ridiculous to do this for the component my code is already in.


 try replacing your failing line with these 2:

 var stuctTest = getTest();
 structAppend(returnData, structTest);

 Azadi


 On 10/11/2010 09:56 , Jessica Kennedy wrote:
 structAppend(returnData, getTest());//failing here!
 

~|
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:339090
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax + 2 functions = error

2010-11-10 Thread Jessica Kennedy

I do cache my component, but since I'm testing, I'm forcing a reload on each 
page load, and I am istantiating the component I call via ajax on every 
request... still, I did a test to be sure-- I attempted to call getTest() via 
ajax-- worked perfectly.  then attempted to call the original method test() 
from getTest... failure.  I'm really scratching my head on this one!

is your component cached in some persistent scope (session/application)?
it sounds like you have added the getTest() method after the component 
has been instantiated - and thus its instance has no idea about the 
getTest() method added later...

Azadi

On 10/11/2010 21:50 , Jessica Kennedy wrote:
 

~|
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:339103
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax + 2 functions = error

2010-11-10 Thread Jessica Kennedy

correct.  I believe if you are calling it from the same root domain a public 
access will work
Confusing. Your access is public but you can call it via remote Ajax? 

~|
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:339104
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax + 2 functions = error

2010-11-09 Thread Tony Bentley

Confusing. Your access is public but you can call it via remote Ajax?


~|
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:339064
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax + 2 functions = error

2010-11-09 Thread Azadi Saryev

try replacing your failing line with these 2:

var stuctTest = getTest();
structAppend(returnData, structTest);

Azadi


On 10/11/2010 09:56 , Jessica Kennedy wrote:
 structAppend(returnData, getTest());//failing here!

~|
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:339069
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax file upload.

2010-09-06 Thread Michael Grant

You have it like this?

CFFORM NAME=foo ACTION=bar.cfc METHOD=POST enctype=multipart/form-data


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


Re: Ajax file upload.

2010-09-06 Thread Steve Sequenzia

No, I have action=formRes.cfm. Then on the formRes.cfm it does a file upload. 
Again, it works with a html form but not with a cfform. should I have the 
action be a .cfc file?

Thanks for the help.

You have it like this?

CFFORM NAME=foo ACTION=bar.cfc METHOD=POST enctype=multipart/form-data 

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


Re: Ajax file upload.

2010-09-06 Thread Michael Grant

The name and action are just there as example. What I'm asking is did you
include *enctype=multipart/form-data in your cfform tag?


On Mon, Sep 6, 2010 at 1:39 PM, Steve Sequenzia c...@thinksys.com wrote:


 No, I have action=formRes.cfm. Then on the formRes.cfm it does a file
 upload. Again, it works with a html form but not with a cfform. should I
 have the action be a .cfc file?

 Thanks for the help.

 You have it like this?
 
 CFFORM NAME=foo ACTION=bar.cfc METHOD=POST
 enctype=multipart/form-data

 

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


RE: Ajax file upload.

2010-09-06 Thread andy matthews

I'm more interested why it has to be cfform? Are you using the validation
for cfform? You know that once your form is finalized, you can just download
the JS that cfform outputs and ditch cfform for production?


andy

-Original Message-
From: Steve Sequenzia [mailto:c...@thinksys.com] 
Sent: Monday, September 06, 2010 12:12 PM
To: cf-talk
Subject: Ajax file upload.


I am trying to make this http://www.webtoolkit.info/ajax-file-upload.html
work in ColdFusion.

I can get it to work as long as I don't make the form a cfform. I need to
make it work with a cfform though.

When I change the form to cfform it just submits to the action page I
created but it loses the ajax functionality.

Any one know how to make it work with cfform?

Thanks 



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


Re: Ajax file upload.

2010-09-06 Thread Steve Sequenzia

 I am trying to make this http://www.webtoolkit.info/ajax-file-upload.
 html work in ColdFusion.
 
 I can get it to work as long as I don't make the form a cfform. I need 
 to make it work with a cfform though.
 
 When I change the form to cfform it just submits to the action page I 
 created but it loses the ajax functionality.
 
 Any one know how to make it work with cfform?
 
 Thanks 

Yes, enctype=multipart/form-data is in the cfform 

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


Re: Ajax, Json, and two clueless programmers

2010-03-28 Thread Tony Bentley


houseDetails = {address : 1970 ST CHESTER AURORA, 80010,  price :
45000,listingNum : 833553, office : 303-487-0777 };



The returned info (price, for example) displays great with ID numbers
in a table as such: td id=price/td or  like this p
id=price/p...  but how the heck do I use it in a URL and (most
importantly) pass other variables with it, for example: a
href=?from=doitprice=PRICEVARIABLEHERE and have that link info
change without refresh right along with the rest of the page?


Using javascript you can access the json as a structure; houseDetails.price 
returns 45000.
So basically once the dataset is returned you can use it to build your url 
string.It really helps to use a framework or library that is meant to work with 
json and ajax. Try prototype or jquery.

I can write the following:

document.createElement(a).href=index.cfm?price=+houseDetails.price;


You can also access elements by their id or relative position to other easily 
accessed elements in jQuery or Prototype

So really if your dev guy is a good client side developer, you should handle 
all of the cfc methods for him and have him do all of the javascript and client 
side development. Or are you trying to learn how to write javascript? 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:332396
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Ajax, Json, and two clueless programmers

2010-03-28 Thread Dave l

first I would use jquery to make it easier but if neither of you know it the 
first hurdle you will face is multiple clicks so you should put a div and class 
around each link and then use jquery's live property which will make this 
work right or else you'll be scratchin your head trying to get it.

then in the same function use jquery ajax function to grab info.

Also cfm returns json IN ALL CAPS, so propertyID becomes PROPERTYID in the 
returned json.

$(function() {
$('td.propertyInfo').live('click',

var PropertyID = this.id;
//the line below is used with a regex to help filter data faster by 
adding a
// longer more specific name to the link to speed it up and then the 
regex
// removes the additional text: example would be: the table row would 
be 
//property id but you shouldn't use that id if it's just a number so 
adding 
//property-#propertyID# separates the value from any other possible 
conflicts.
var getDataString = $(this).attr('id').replace(/property-/ig, '');
var dataString = id= + getDataString;
$.ajax({
type: post,
url: assets/cfc/process.cfc?method=getPTreturnFormat=json,
data: dataString,
dataType: json,
cache: false,
success: function(data) {
//success code here
} else {
$('#submitIt div').removeClass('btnSpin');
 //error code here  
}
}
});
return false;
});
return false;
}); 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:332398
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


RE: Ajax, Json, and two clueless programmers

2010-03-28 Thread andy matthews

Just to clarify that CF ONLY returns JSON in all caps if you use dot
notation. Try it out yourself.

Dot notation
VARIABLES.myStruct.myKey - VARIABLES.MYSTRUCT.MYKEY

Bracket notation
VARIABLES['myStruct']['myKey'] - VARIABLES.myStruct.myKey




-Original Message-
From: Dave l [mailto:cfl...@jamwerx.com] 
Sent: Sunday, March 28, 2010 7:30 PM
To: cf-talk
Subject: Re: Ajax, Json, and two clueless programmers


first I would use jquery to make it easier but if neither of you know it the
first hurdle you will face is multiple clicks so you should put a div and
class around each link and then use jquery's live property which will make
this work right or else you'll be scratchin your head trying to get it.

then in the same function use jquery ajax function to grab info.

Also cfm returns json IN ALL CAPS, so propertyID becomes PROPERTYID in the
returned json.

$(function() {
$('td.propertyInfo').live('click',

var PropertyID = this.id;
//the line below is used with a regex to help filter data faster by
adding a
// longer more specific name to the link to speed it up and then the
regex
// removes the additional text: example would be: the table row
would be 
//property id but you shouldn't use that id if it's just a number so
adding 
//property-#propertyID# separates the value from any other
possible conflicts.
var getDataString = $(this).attr('id').replace(/property-/ig, '');
var dataString = id= + getDataString;
$.ajax({
type: post,
url: assets/cfc/process.cfc?method=getPTreturnFormat=json,
data: dataString,
dataType: json,
cache: false,
success: function(data) {
//success code here
} else {
$('#submitIt div').removeClass('btnSpin');
 //error code here  
}
}
});
return false;
});
return false;
}); 



~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:332400
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: AJAX Question

2010-01-22 Thread Mike Chabot

The way you do that depends on which Ajax library you are using. You
insert data into the database the way you normally do using
ColdFusion. The JavaScript that you use pulls data from the form
fields, sends it to the server using any number of methods, then
ColdFusion takes it from there and send back a response to the browser
when it is done.

Which JavaScript framework were you going to use, if any? Which
version of CF are you using? Have you tried searching for examples on
the Web yet?

-Mike Chabot

On Fri, Jan 22, 2010 at 9:48 AM, Matthew Allen a.matthe...@yahoo.com wrote:

 Can anyone please give me pointers or real life example of how to insert 
 simple form field values into a database using AJAX.

 Many thanks.

 Matt

 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:330013
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: AJAX Question

2010-01-22 Thread Andy Matthews

Bear in mind that you do not insert values into a database with AJAX. AJAX
is merely  way to pass said values to the processing page of your choice
without page refresh.

So assuming you know how to do a database insert with ColdFusion, you'd just
need to know how to pass the values from your client code to your ColdFusion
page.

jQuery makes this very simple:

$.get(http://www.yoursite.com/path/to/coldfusion/file.cfm;, {
// here's the key value pairs you want to pass in your request
key1: 'value one',
key2: 'value two',
key3: 'value three'
},function(data){
// if your processing page will be passing data BACK to your client
page
// then you'd do something with that data here.
}); 

-Original Message-
From: Matthew Allen [mailto:a.matthe...@yahoo.com] 
Sent: Friday, January 22, 2010 8:48 AM
To: cf-talk
Subject: AJAX Question


Can anyone please give me pointers or real life example of how to insert
simple form field values into a database using AJAX.

Many thanks.

Matt 



~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:330014
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: AJAX Question

2010-01-22 Thread Andy Matthews

One thing I forgot to mention. If you use the below method, then you'd
reference the values on the ColdFusion page in the URL scope.

URL.key1
URL.key2
Etc.

If you need a POST then you'd just change the var references to the FORM
scope, and change $.get to $.post


andy

-Original Message-
From: Andy Matthews [mailto:li...@commadelimited.com] 
Sent: Friday, January 22, 2010 9:15 AM
To: cf-talk
Subject: RE: AJAX Question


Bear in mind that you do not insert values into a database with AJAX. AJAX
is merely  way to pass said values to the processing page of your choice
without page refresh.

So assuming you know how to do a database insert with ColdFusion, you'd just
need to know how to pass the values from your client code to your ColdFusion
page.

jQuery makes this very simple:

$.get(http://www.yoursite.com/path/to/coldfusion/file.cfm;, {
// here's the key value pairs you want to pass in your request
key1: 'value one',
key2: 'value two',
key3: 'value three'
},function(data){
// if your processing page will be passing data BACK to your client
page
// then you'd do something with that data here.
}); 

-Original Message-
From: Matthew Allen [mailto:a.matthe...@yahoo.com]
Sent: Friday, January 22, 2010 8:48 AM
To: cf-talk
Subject: AJAX Question


Can anyone please give me pointers or real life example of how to insert
simple form field values into a database using AJAX.

Many thanks.

Matt 





~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:330015
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: AJAX Question

2010-01-22 Thread Tom Chiverton

On Friday 22 Jan 2010, Matthew Allen wrote:
 Can anyone please give me pointers or real life example of how to insert
 simple form field values into a database using AJAX.

/your/path/to/A.cfc?returnFormat=jsonmethod='yourSaveMethodName'arg1='foo'arg2=23

-- 
Helping to evangelistically introduce web-enabled killer dynamic scalable 
applications as part of the IT team of the year 2010, '09 and '08



This email is sent for and on behalf of Halliwells LLP.

Halliwells LLP is a limited liability partnership registered in England and 
Wales under registered number OC307980 whose registered office address is at 
Halliwells LLP, 3 Hardman Square, Spinningfields, Manchester, M3 3EB.  A list 
of members is available for inspection at the registered office together with a 
list of those non members who are referred to as partners.  We use the word 
“partner” to refer to a member of the LLP, or an employee or consultant with 
equivalent standing and qualifications. Regulated by the Solicitors Regulation 
Authority.

CONFIDENTIALITY

This email is intended only for the use of the addressee named above and may be 
confidential or legally privileged.  If you are not the addressee you must not 
read it and must not use any information contained in nor copy it nor inform 
any person other than Halliwells LLP or the addressee of its existence or 
contents.  If you have received this email in error please delete it and notify 
Halliwells LLP IT Department on 0870 365 2500.

For more information about Halliwells LLP visit www.halliwells.co

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:330016
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: AJAX Question

2010-01-22 Thread Scott Stewart

Matt here's a quick one using JQuery:

First off, you need to load the JQuery libraries in the head of the page.

script type=text/javascript
$(document).ready(function() {
$(#button name).live(click, function(){
$.ajax({
type:post,
url:url of processing page,
data:$(#form name).serialize(),
cache:false,
success:
function(){$(#receiving div).load(page to load on sucess)},
error: function(){
error functionality here;
}
});
});
)}
/script

From the top, 

$(document).ready(function() {

This ensures that everything inside is as soon as the DOM is loaded, while
not as important here, if you're using JQuery for layout manipulation it's
critical, so make a habit of wrapping all JQuery code in it.

$(#button name).live(click, function(){

This script is triggered off of a button, make sure the button tag has an
id, this is what you'll trigger on. 

url:url of processing page,

this is url of whatever actions you're going to call, hijacks the action
attribute of the form tag

success: function(){$(#receiving div).load(page to load on sucess)},

The page that you want to load after processing, and the div that it should
be placed in

error: function(){error functionality here;}

error functionality, error pages etc.

This is quick and dirty, there's an entire form plugin for JQuery that may
be better suited to what you need.

To debug any AJAX stuff, if you haven't already downloaded Firefox, do it
and get the firebug plugin, along with the JQuery plugins that are
available. The NET tab in firebug will show you all of the behind the scenes
stuff going on.

Hope this helps

sas


-Original Message-
From: Matthew Allen [mailto:a.matthe...@yahoo.com] 
Sent: Friday, January 22, 2010 9:48 AM
To: cf-talk
Subject: AJAX Question


Can anyone please give me pointers or real life example of how to insert
simple form field values into a database using AJAX.

Many thanks.

Matt 



~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:330017
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: AJAX Question

2010-01-22 Thread Chris Dicamillo

Also, if you're using CF9's AJAX implementation, putting ?cfdebug at the end
of your URL will show the AJAX debugger (assuming that feature is enabled in
the CF Admin).

Chris

 -Original Message-
 From: Scott Stewart [mailto:sstwebwo...@bellsouth.net]
 Sent: Friday, January 22, 2010 8:21 AM
 To: cf-talk
 Subject: RE: AJAX Question
 
 
 Matt here's a quick one using JQuery:
 
 First off, you need to load the JQuery libraries in the head of the
 page.
 
 script type=text/javascript
   $(document).ready(function() {
   $(#button name).live(click, function(){
   $.ajax({
   type:post,
   url:url of processing page,
   data:$(#form name).serialize(),
   cache:false,
   success:
 function(){$(#receiving div).load(page to load on sucess)},
   error: function(){
   error functionality here;
   }
   });
   });
   )}
 /script
 
 From the top,
 
 $(document).ready(function() {
 
 This ensures that everything inside is as soon as the DOM is loaded,
 while
 not as important here, if you're using JQuery for layout manipulation
 it's
 critical, so make a habit of wrapping all JQuery code in it.
 
 $(#button name).live(click, function(){
 
 This script is triggered off of a button, make sure the button tag has
 an
 id, this is what you'll trigger on.
 
 url:url of processing page,
 
 this is url of whatever actions you're going to call, hijacks the
 action
 attribute of the form tag
 
 success: function(){$(#receiving div).load(page to load on
 sucess)},
 
 The page that you want to load after processing, and the div that it
 should
 be placed in
 
 error: function(){error functionality here;}
 
 error functionality, error pages etc.
 
 This is quick and dirty, there's an entire form plugin for JQuery that
 may
 be better suited to what you need.
 
 To debug any AJAX stuff, if you haven't already downloaded Firefox, do
 it
 and get the firebug plugin, along with the JQuery plugins that are
 available. The NET tab in firebug will show you all of the behind the
 scenes
 stuff going on.
 
 Hope this helps
 
 sas
 
 
 -Original Message-
 From: Matthew Allen [mailto:a.matthe...@yahoo.com]
 Sent: Friday, January 22, 2010 9:48 AM
 To: cf-talk
 Subject: AJAX Question
 
 
 Can anyone please give me pointers or real life example of how to
 insert
 simple form field values into a database using AJAX.
 
 Many thanks.
 
 Matt
 
 
 
 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:330018
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: AJAX Question

2010-01-22 Thread Scott Stewart

Chris, 

I'm not sure how well the debugger works with non cf ajax.. I've just stuck
with firebug.

-Original Message-
From: Chris Dicamillo [mailto:ch...@warnercnr.colostate.edu] 
Sent: Friday, January 22, 2010 10:38 AM
To: cf-talk
Subject: RE: AJAX Question


Also, if you're using CF9's AJAX implementation, putting ?cfdebug at the end
of your URL will show the AJAX debugger (assuming that feature is enabled in
the CF Admin).

Chris

 -Original Message-
 From: Scott Stewart [mailto:sstwebwo...@bellsouth.net]
 Sent: Friday, January 22, 2010 8:21 AM
 To: cf-talk
 Subject: RE: AJAX Question
 
 
 Matt here's a quick one using JQuery:
 
 First off, you need to load the JQuery libraries in the head of the
 page.
 
 script type=text/javascript
   $(document).ready(function() {
   $(#button name).live(click, function(){
   $.ajax({
   type:post,
   url:url of processing page,
   data:$(#form name).serialize(),
   cache:false,
   success:
 function(){$(#receiving div).load(page to load on sucess)},
   error: function(){
   error functionality here;
   }
   });
   });
   )}
 /script
 
 From the top,
 
 $(document).ready(function() {
 
 This ensures that everything inside is as soon as the DOM is loaded,
 while
 not as important here, if you're using JQuery for layout manipulation
 it's
 critical, so make a habit of wrapping all JQuery code in it.
 
 $(#button name).live(click, function(){
 
 This script is triggered off of a button, make sure the button tag has
 an
 id, this is what you'll trigger on.
 
 url:url of processing page,
 
 this is url of whatever actions you're going to call, hijacks the
 action
 attribute of the form tag
 
 success: function(){$(#receiving div).load(page to load on
 sucess)},
 
 The page that you want to load after processing, and the div that it
 should
 be placed in
 
 error: function(){error functionality here;}
 
 error functionality, error pages etc.
 
 This is quick and dirty, there's an entire form plugin for JQuery that
 may
 be better suited to what you need.
 
 To debug any AJAX stuff, if you haven't already downloaded Firefox, do
 it
 and get the firebug plugin, along with the JQuery plugins that are
 available. The NET tab in firebug will show you all of the behind the
 scenes
 stuff going on.
 
 Hope this helps
 
 sas
 
 
 -Original Message-
 From: Matthew Allen [mailto:a.matthe...@yahoo.com]
 Sent: Friday, January 22, 2010 9:48 AM
 To: cf-talk
 Subject: AJAX Question
 
 
 Can anyone please give me pointers or real life example of how to
 insert
 simple form field values into a database using AJAX.
 
 Many thanks.
 
 Matt
 
 
 
 



~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:330020
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: AJAX Question

2010-01-22 Thread Chris Dicamillo

You're probably right. Your note about using firebug reminded me of the
built in debugger with CF9, so I figured it would be worth letting Matthew
know about it if he was using cfajaxproxy.

Chris

 -Original Message-
 From: Scott Stewart [mailto:sstwebwo...@bellsouth.net]
 Sent: Friday, January 22, 2010 8:50 AM
 To: cf-talk
 Subject: RE: AJAX Question
 
 
 Chris,
 
 I'm not sure how well the debugger works with non cf ajax.. I've just
 stuck
 with firebug.
 
 -Original Message-
 From: Chris Dicamillo [mailto:ch...@warnercnr.colostate.edu]
 Sent: Friday, January 22, 2010 10:38 AM
 To: cf-talk
 Subject: RE: AJAX Question
 
 
 Also, if you're using CF9's AJAX implementation, putting ?cfdebug at
 the end
 of your URL will show the AJAX debugger (assuming that feature is
 enabled in
 the CF Admin).
 
 Chris
 
  -Original Message-
  From: Scott Stewart [mailto:sstwebwo...@bellsouth.net]
  Sent: Friday, January 22, 2010 8:21 AM
  To: cf-talk
  Subject: RE: AJAX Question



~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:330022
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: AJAX Question

2010-01-22 Thread Matthew Allen

Thanks all, I really appreciate all the input.

Now to go away and start working.

Matt. 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:330024
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: AJAX Question

2010-01-22 Thread brad

I appreciate everyone falling over themselves to give the obligatory
Use jQuery response :), but I'm kind of surprised no one mentioned the
super simple method of doing this that is built right in to CF8 and 9.

Click on this link (CF8 docs):
http://livedocs.adobe.com/coldfusion/8/htmldocs/ajaxui_5.html
and scroll down to Using the cfajaxproxy SetForm function.

There's a working code sample for you and everything.  Essentially, you
create a CFC on the server side and reference it with a cfajaxproxy tag.
 To borrow from Adobe's example, the magic happens in about 3 lines of
JavaScript code:

var auth = new AuthenticationSystem();
auth.setForm(loginForm);
auth.validateCredentials();

~Brad


 Original Message 
Subject: AJAX Question
From: Matthew Allen a.matthe...@yahoo.com
Date: Fri, January 22, 2010 8:48 am
To: cf-talk cf-talk@houseoffusion.com


Can anyone please give me pointers or real life example of how to insert
simple form field values into a database using AJAX.

Many thanks.

Matt 



~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:330035
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


RE: AJAX Question

2010-01-22 Thread Andy Matthews

It's mostly because I don't know of anyone actually using CF8's built in
implementation. It's highly unlikely that anyone is going to be building a
single AJAX call in a vacuum. Most developers are going to be using jQuery
for other aspects of the site's development. Better to stay consistent and
use jQuery for everything rather than drop into a different implementation
and syntax.


andy

-Original Message-
From: b...@bradwood.com [mailto:b...@bradwood.com] 
Sent: Friday, January 22, 2010 12:06 PM
To: cf-talk
Subject: RE: AJAX Question


I appreciate everyone falling over themselves to give the obligatory Use
jQuery response :), but I'm kind of surprised no one mentioned the super
simple method of doing this that is built right in to CF8 and 9.

Click on this link (CF8 docs):
http://livedocs.adobe.com/coldfusion/8/htmldocs/ajaxui_5.html
and scroll down to Using the cfajaxproxy SetForm function.

There's a working code sample for you and everything.  Essentially, you
create a CFC on the server side and reference it with a cfajaxproxy tag.
 To borrow from Adobe's example, the magic happens in about 3 lines of
JavaScript code:

var auth = new AuthenticationSystem();
auth.setForm(loginForm);
auth.validateCredentials();

~Brad


 Original Message 
Subject: AJAX Question
From: Matthew Allen a.matthe...@yahoo.com
Date: Fri, January 22, 2010 8:48 am
To: cf-talk cf-talk@houseoffusion.com


Can anyone please give me pointers or real life example of how to insert
simple form field values into a database using AJAX.

Many thanks.

Matt 





~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:330036
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: AJAX Question

2010-01-22 Thread brad

 Better to stay consistent and use jQuery for everything rather than drop into 
 a different implementation and syntax.

From the sound of his question I'd bet he's not using any Ajax
implementation and syntax right now.

 I don't know of anyone actually using CF8's built in implementation

That's too bad.  We use it, and we use it everywhere we do Ajax.  We
still use jQuery for pretty much all our other DOM manipulation and
stuff but we simply can't beat the ajax proxy stuff when it comes to
talking back to the server.  It's simple, it does everything we need
(like easy error-handling), and it works well.

 It's highly unlikely that anyone is going to be building a single AJAX call 
 in a vacuum.

I would agree, but the usage of any other JS framework (like jQuery)
doesn't automatically preclude the possibility of me mixing and matching
the best and easiest of all worlds.  The OP is obviously getting his
feet wet in Ajax right now.  I'm sure he'll drink the jQuery koolaid
like most of us in due time. In the mean time, he deserves to at least
know the viable options that he already purchased along with his CF
license.  :)

~Brad


 Original Message 
Subject: RE: AJAX Question
From: Andy Matthews li...@commadelimited.com
Date: Fri, January 22, 2010 12:13 pm
To: cf-talk cf-talk@houseoffusion.com


It's mostly because I don't know of anyone actually using CF8's built in
implementation. It's highly unlikely that anyone is going to be building
a
single AJAX call in a vacuum. Most developers are going to be using
jQuery
for other aspects of the site's development. Better to stay consistent
and
use jQuery for everything rather than drop into a different
implementation
and syntax.



~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:330038
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Ajax Query

2009-11-11 Thread Tony Bentley

Looks like everything is using Ext objects. Try building a function that grabs 
each set value and places it in a corresponding hidden input on your page.You 
need to store this collection somehow either in DOM or in form elements. 
Easiest way to see your results is by using form elements that are hidden to 
the user. I'm not sure how to grab the selected values but I'm sure Ext has 
something built into the API for each object. 

A universal function would look something like this:

//using jquery
function save(sourcevalue, elementIdToSaveTo){
$(#+elementIdToSaveTo).val(sourcevalue);
}
//standard js notation
function save(sourcevalue, elementIdToSaveTo){
document.getElementById(elementIdToSaveTo).value = sourcevalue;
}

You would run this for every item that you want to store.

I'm not sure if this helps. Without seeing what your client side looks like and 
being able to inspect the elements, it is a little tough to figure out a viable 
solution. 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328276
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Ajax Query

2009-11-11 Thread Arsalan Tariq Keen

thanks Tony :)

--
From: Tony Bentley t...@tonybentley.com
Sent: Thursday, November 12, 2009 12:03 AM
To: cf-talk cf-talk@houseoffusion.com
Subject: Re: Ajax Query


 Looks like everything is using Ext objects. Try building a function that 
 grabs each set value and places it in a corresponding hidden input on your 
 page.You need to store this collection somehow either in DOM or in form 
 elements. Easiest way to see your results is by using form elements that 
 are hidden to the user. I'm not sure how to grab the selected values but 
 I'm sure Ext has something built into the API for each object.

 A universal function would look something like this:

 //using jquery
 function save(sourcevalue, elementIdToSaveTo){
 $(#+elementIdToSaveTo).val(sourcevalue);
 }
 //standard js notation
 function save(sourcevalue, elementIdToSaveTo){
 document.getElementById(elementIdToSaveTo).value = sourcevalue;
 }

 You would run this for every item that you want to store.

 I'm not sure if this helps. Without seeing what your client side looks 
 like and being able to inspect the elements, it is a little tough to 
 figure out a viable solution.

 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328291
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Ajax Query

2009-11-10 Thread Tony Bentley

 I know this is not the place to post such queries, but I am very 
 stressed out now and can not find solution to my problem. Maybe 
 someone hase had similar experience while using ExtJS with ColdFusion.
 
 
 My scenario is simple. Upon clicking a menu item on my homepage, a 
 window opens. After filling out sertain textfields, when these fields 
 loose focus, another modal window is opened having a grid. Now I want 
 to the user to select one of the values listed in the grid and then 
 press 'Done' button. Once this 'done' button is hit, I want the child 
 window to close and the selected record in the grid of childWindow 
 must be passed to the initial parent window.
 
 How can this be achieved?
 
 Regards,
Arsalan

Window is pretty loosely described. Is it a browser window or a DIV? There 
would be different solutions for either situation. Modal window sounds like a 
div. If so, you use javascript to get the value of each element based on the 
id. Instead of using grid, can't you use something else that would be easier to 
get values from? Even an 'li' would suffice. Then use placeholders in your 
parent window, like hidden inputs to store the passed values. 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328227
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Ajax Query

2009-11-10 Thread Arsalan Tariq Keen

Tony,

Can you please provide me the code snippets of what you are talking about. I 
mean how will I set values of hidden fields... well actually I have visible 
ReadOnly TextFields in the parent window and upon the closure of the child 
window I need the values to be passed from the child window to these 
TextFields in the parent window.

Kindly plz help.

--
From: Tony Bentley t...@tonybentley.com
Sent: Wednesday, November 11, 2009 2:53 AM
To: cf-talk cf-talk@houseoffusion.com
Subject: Re: Ajax Query


 I know this is not the place to post such queries, but I am very
 stressed out now and can not find solution to my problem. Maybe
 someone hase had similar experience while using ExtJS with ColdFusion.


 My scenario is simple. Upon clicking a menu item on my homepage, a
 window opens. After filling out sertain textfields, when these fields
 loose focus, another modal window is opened having a grid. Now I want
 to the user to select one of the values listed in the grid and then
 press 'Done' button. Once this 'done' button is hit, I want the child
 window to close and the selected record in the grid of childWindow
 must be passed to the initial parent window.

 How can this be achieved?

 Regards,
 Arsalan

 Window is pretty loosely described. Is it a browser window or a DIV? There 
 would be different solutions for either situation. Modal window sounds 
 like a div. If so, you use javascript to get the value of each element 
 based on the id. Instead of using grid, can't you use something else that 
 would be easier to get values from? Even an 'li' would suffice. Then use 
 placeholders in your parent window, like hidden inputs to store the passed 
 values.

 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328236
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Ajax Query

2009-11-10 Thread Tony Bentley

Sure, please provide some code. 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328237
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Ajax Query

2009-11-10 Thread Arsalan Tariq Keen

Attached is my code for the Parent window (order_new_form.cfm) and the child 
window (order_new_gridPrice.cfm).

The code is lengthy and may seem filthy too...so I m summarising my goal
Initially a form is displayed in a parent window in which the user enters 
Article Number. The article number filed upon 'change' opens a child window 
in which I have to display a grid for further user selection. However to 
keep things simple for now I am just displaying a button which on click 
shall set the value of field quantity (to any arbitrary integer value for 
now) in the parent window and also then close the child form.

Many thanks in advance!

--
From: Tony Bentley t...@tonybentley.com
Sent: Wednesday, November 11, 2009 5:44 AM
To: cf-talk cf-talk@houseoffusion.com
Subject: Re: Ajax Query


 Sure, please provide some code.

 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328238
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Ajax Query

2009-11-10 Thread Arsalan Tariq Keen
allowBlank: true,
hideLabel: true,
name: article_name+row,
id: article_name+row,
readOnly: true,
width: 180,
dummy: true
});

d = new Ext.form.NumberField({  //Dynamic Quantity Field
allowBlank: false,
allowDecimals: false,
decimalPrecision: 0,
hideLabel: true,
name: quantity+row,
id: quantity+row,
width: 50,
dummy: true
});

e = new Ext.form.NumberField({  //Dynamic Price Field
allowBlank: false,
allowDecimals: true,
decimalPrecision: 2,
hideLabel: true,
name: price+row,
id: price+row,
width: 50,
dummy: true
});

f = new Ext.form.NumberField({  //Dynamic Total Price Field
allowBlank: false,
allowDecimals: true,
decimalPrecision: 2,
hideLabel: true,
name: t_price+row,
id: t_price+row,
width: 50,
dummy: true
});

Ext.getCmp(columnID).insert(row, a );
Ext.getCmp(columnArticleNumber).insert(row, b );
Ext.getCmp(columnArticleName).insert(row, c );
Ext.getCmp(columnQty).insert(row, d );
Ext.getCmp(columnPrice).insert(row, e );
Ext.getCmp(columnTPrice).insert(row, f );

Ext.getCmp(columnID).doLayout();
Ext.getCmp(columnArticleNumber).doLayout();
Ext.getCmp(columnArticleName).doLayout();
Ext.getCmp(columnQty).doLayout();
Ext.getCmp(columnPrice).doLayout();
Ext.getCmp(columnTPrice).doLayout();
//Ext.getCmp(new_order_form).getForm().add( a );
//Ext.getCmp(new_order_form).getForm
div id=test2/div


script type=text/javascript
Ext.onReady(function(){

var PANEL821 = new Ext.Panel({
autoHeight: true,
autoWidth: true,
id: myPanel,
renderTo: test2,
items: [
new Ext.Button({
handler: testHandler,
iconCls: icon-save,
text: Save Form,
dummy: true
})
],
dummy: true
});

function testHandler() {
//var b = document.getCmp('myWin');
var a = this.findParentByType('panel').id;
a = a.findParentByType('window').id;
Ext.Msg.alert('Test', a);
//new_order_form.form.findField('quantity2').setValue('12');
}

});
/script
().add( b );
//addAfter( a, c );
//Ext.getCmp(new_order_form).doLayout();
}
/script


--
From: Arsalan Tariq Keen arsalk...@hotmail.com
Sent: Wednesday, November 11, 2009 7:50 AM
To: cf-talk cf-talk@houseoffusion.com
Subject: Re: Ajax Query


 Attached is my code for the Parent window (order_new_form.cfm) and the 
 child
 window (order_new_gridPrice.cfm).

 The code is lengthy and may seem filthy too...so I m summarising my 
 goal
 Initially a form is displayed in a parent window in which the user enters
 Article Number. The article number filed upon 'change' opens a child 
 window
 in which I have to display a grid for further user selection. However to
 keep things simple for now I am just displaying a button which on click
 shall set the value of field quantity (to any arbitrary integer value for
 now) in the parent window and also then close the child form.

 Many thanks in advance!

 --
 From: Tony Bentley t...@tonybentley.com
 Sent: Wednesday, November 11, 2009 5:44 AM
 To: cf-talk cf-talk@houseoffusion.com
 Subject: Re: Ajax Query


 Sure, please provide some code.



 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328241
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: AJAX CFGRID will not sort by column?

2009-11-03 Thread Glyn Jackson

Found the issues on this line...

 ORDER BY cfqueryparam cfsqltype=cf_sql_varchar 
value=#ARGUMENTS.gridsortcolumn# cfqueryparam cfsqltype=cf_sql_varchar 
value=#ARGUMENTS.gridsortdir#

it seems to work without the cfqueryparam. can anyone tell me why this is the 
case? 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:327949
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: AJAX CFGRID will not sort by column?

2009-11-03 Thread Raymond Camden

You can't use QueryParams for the order by (or dir) parts of SQL. It
can only be used for values in WHERE clauses.

On Tue, Nov 3, 2009 at 5:30 AM, Glyn Jackson glyn.jack...@newebia.co.uk wrote:

 Found the issues on this line...

  ORDER BY cfqueryparam cfsqltype=cf_sql_varchar 
 value=#ARGUMENTS.gridsortcolumn# cfqueryparam cfsqltype=cf_sql_varchar 
 value=#ARGUMENTS.gridsortdir#

 it seems to work without the cfqueryparam. can anyone tell me why this is the 
 case?

 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:327950
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: AJAX CFGRID will not sort by column?

2009-11-03 Thread Glyn Jackson

Thanks Ray, seems strange, I did not know that. 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:327951
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: AJAX CFGRID will not sort by column?

2009-11-03 Thread brad

To be a bit more exact, you can only use cfqueryparam in a place where a
regular SQL parameter could be used.  For MSSQL server, this could be in
the WHERE clause, the SELECT clause, JOINs, etc.  However, SQL Server
doesn't allow you to do this:

DECLARE @orderBy varchar(50)
SET @orderBy = 'name'

SELECT name
FROM person
ORDER BY @orderBy

Therefore, you cannot parametrize that portion of a select with a
cfqueryparam either.

The important thing to come away from this with is that you still need
to prevent SQL Inject attacks!  Blindly outputting the values sent in
from an Ajax call could be hazardous to ones server.  One method is to
check the contents of ARGUMENTS.gridsortcolumn and ARGUMENTS.gridsortdir
against a list of known good values.  

cfif listfindnocase(firstName,lastName,age,argumentsgridsortcolumn)
ORDER BY #argumentsgridsortcolumn# cfif arguments.gridsortdir eq
DESCDESC/cfif
/cfif

~Brad

 Original Message 
Subject: Re: AJAX CFGRID will not sort by column?
From: Glyn Jackson glyn.jack...@newebia.co.uk
Date: Tue, November 03, 2009 5:50 am
To: cf-talk cf-talk@houseoffusion.com


Thanks Ray, seems strange, I did not know that. 



~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:327955
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: ajax cfc not working for Access DB -- odd stuff

2009-08-20 Thread Dominic Watson

If the cfc is being hit, and with the right data, you can absolutely rule
out the cfajaxproxy tag. Can we clarify that the data being returned from
the method is the problem? Try posting a form directly to the cfc method,
e.g.

form method=post action=pathtocfc.cfc?method=fubar!--- I think that's
right, have never done it ---
!--- your fields, etc ---
/form

From there, debugging should be more straight forward.

Dominic

2009/8/20 Don L do...@yahoo.com


  I've moved on to an open source cfml engine
 Don't ever do that.
 
 But seriously. First step of debugging ajax: install Firebug for Firefox
 if
 you haven't already. Next, enable all the firebug console options for your
 page and while viewing the console tab you should see your http post
 request
 made by your proxy js object (when you fire that event). You will then be
 able to examine the the data sent to your cfc and also the response.
 
 If there is no http request sent then the problem may well be with the
 cfajaxproxy code - if a request *is* sent, then we can safely move on from
 the client side code.
 
 With any luck, examining the http response will tell you exactly what's
 going wrong and will be a cf / railo error page.
 
 HTH
 
 Dominic

 Very ODD.

 The line of cfreturn #result# in the cfc should have been
 cfreturn true since we don't need data back from the cfc.

 and was previously cfreturn true.  I've enabled the feature in FF.

 case A, cfreturn true
 ajax http post succeeds, RESPONSE: the {data} instead of TRUE ?

 case B, in the cfc, cfset result=fielda, #fa#; fieldb, #fb#;
 memofield,#mf#
 cfreturn #result#
 (just for the heck of it),
 ajax http post succeeds, RESPONSE: just the #mf# instead of fielda, #fa#;
 fieldb, #fb#; memofield,#mf# ?


 FYI, the computer is totally offline and wireless device driver was turned
 off as well.



 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:325560
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: ajax cfc not working for Access DB -- odd stuff

2009-08-20 Thread Dominic Watson

Of course ;)

2009/8/20 Emmit Larson emmit.lar...@gmail.com

 't ever do that.
 Shirley, you jest?

 Kind Regards,
 Emmit


~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:325559
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: ajax cfc not working for Access DB -- odd stuff

2009-08-20 Thread Rick Root

On Wed, Aug 19, 2009 at 7:13 PM, Don Ldo...@yahoo.com wrote:

 Sorry, Dominic, I wasn't clear about the browser, the inline editing feature 
 is IE specific, that is, Firefox has a hell time with it, hence, it's IE 
 only, yes, I like Firefox's firebug and find it very helpful but not for this 
 case.  I have firebug lite set up for the IE7, but it didn't show http call 
 etc. from cfajaxproxy as in FF/FB... more thoughts? thanks.

use a different inline editor =)

Otherwise for something a little more helpful, download and install
Fiddler for Internet Explorer.

http://www.fiddler2.com/fiddler2/

Enable it, then hit your application.  You'll see the ajax call show
up in fiddler.. you can then see the raw response from your cfc using
the session inspector..

-- 
Rick Root
New Brian Vander Ark Album, songs in the music player and cool behind
the scenes video at www.myspace.com/brianvanderar

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:325564
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: ajax cfc not working for Access DB -- odd stuff

2009-08-20 Thread Don L

If the cfc is being hit, and with the right data, you can absolutely rule
out the cfajaxproxy tag. Can we clarify that the data being returned from
the method is the problem? Try posting a form directly to the cfc method,
e.g.

form method=post action=pathtocfc.cfc?method=fubar!--- I think that's
right, have never done it ---
!--- your fields, etc ---
/form

From there, debugging should be more straight forward.

Dominic

Forgot, I could simply use 
pathtocfc.cfc?method=fubarparam1=727param2='blablaText'
from URL to test it and did, it only returned these structures but action 
outcome.  But I've spent over 1.4 hours on it, there's another option, opted 
out... thanks though.


~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:325575
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: ajax cfc not working for Access DB -- odd stuff

2009-08-19 Thread Adrian Lynch

Railo or OpenBD? Do they support cfajaxproxy yet?

 -Original Message-
 From: Don L [mailto:do...@yahoo.com]
 Sent: 19 August 2009 22:42
 To: cf-talk
 Subject: ajax cfc not working for Access DB -- odd stuff
 
 
 I've moved on to an open source cfml engine, don't know what caused the
 following odd behavior, that is, my cfajaxproxy tag no longer works for
 an inline data editing function (meaning, it does not do database
 update for a set of data) while the same code works for ms sql server
 2005 express (db syntax are exactly same for such a simple query) and
 since I'm using sync mode I can't use the setCallbackHandler method
 to do debugging.  Thought, could use more heads here...
 
 caller line
 cfajaxproxy cfc=myCFC4inlineEdit jsclassname=UpdateObj2 /
 
 cfc code and js code below,
 
 cfcomponent output=false
 cfset THIS.dsn=myDS
 
   cffunction name=doUpdate access=remote
 
   cfloop item=i collection=#arguments#
  cfif Left(i,6) IS someID
  cfset someid = arguments.#i#
/cfif
cfif Left(i,4) IS uaid
  cfset uaid = arguments.#i#
/cfif
cfif Left(i,5) IS whats
  cfset whats = arguments.#i#
/cfif
   /cfloop
 
   cfif not isdefined(arguments.userID)
  cfset arguments.someID = 'dummyID728932'
   /cfif
 
   cfset fmtwhats = REreplace(Evaluate(whats),','',ALL)
   cfset fmwhats = REreplace(fmtwhats,'','',ALL)
 
   cfparam name=result default=success
   cftry
   cfquery datasource=#THIS.dsn#
 update blablaTBL
   set whats = '#fmwhats#'
   where uaid = cfqueryPARAM value =
#Evaluate(uaid)#
 
 cfsqltype=CF_SQL_INTEGER
   and sid = cfqueryPARAM
value =
 #Evaluate(someid)#
 
 cfsqltype=CF_SQL_VARCHAR
maxlength=128;
   /cfquery
   cfcatch type=databasecfset result=failed
   /cfcatch
   /cftry
 
   !---cfreturn #fmWhats#---
   cfreturn #result#
 
   /cffunction
 /cfcomponent
 
 
 // much credit goes to Sam Farmer for getting me started on this (JSON)
 approach
 function callUpdateJS2(frm,row) {
   rowUpdate(frm,row);
 }
 
 function handleResult(r) {
console.log(r);
 }
 
 function rowUpdate(frm,row){
   // var d = new DraftObj();
   var d = new UpdateObj2();
   d.setSyncMode(true);
   d.setForm(frm);
   d.setHTTPMethod('POST');
   // d.doUpdate();
 
   // expect  d.doUpdate() to return failed or success string
   // BUT it doesn't!
 
   // update {notes} field; 05/28/2008
   document.getElementById(row).innerHTML = d.doUpdate();
 }
 
 
 Forgive me about the formatting and typo if any.
 
 Thanks.
 
 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:325550
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: ajax cfc not working for Access DB -- odd stuff

2009-08-19 Thread Dominic Watson

  I've moved on to an open source cfml engine
Don't ever do that.

But seriously. First step of debugging ajax: install Firebug for Firefox if
you haven't already. Next, enable all the firebug console options for your
page and while viewing the console tab you should see your http post request
made by your proxy js object (when you fire that event). You will then be
able to examine the the data sent to your cfc and also the response.

If there is no http request sent then the problem may well be with the
cfajaxproxy code - if a request *is* sent, then we can safely move on from
the client side code.

With any luck, examining the http response will tell you exactly what's
going wrong and will be a cf / railo error page.

HTH

Dominic


~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:325551
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: ajax cfc not working for Access DB -- odd stuff

2009-08-19 Thread Don L

 I've moved on to an open source cfml engine
Don't ever do that.

But seriously. First step of debugging ajax: install Firebug for Firefox if
you haven't already. Next, enable all the firebug console options for your
page and while viewing the console tab you should see your http post request
made by your proxy js object (when you fire that event). You will then be
able to examine the the data sent to your cfc and also the response.

If there is no http request sent then the problem may well be with the
cfajaxproxy code - if a request *is* sent, then we can safely move on from
the client side code.

With any luck, examining the http response will tell you exactly what's
going wrong and will be a cf / railo error page.

HTH

Dominic

Sorry, Dominic, I wasn't clear about the browser, the inline editing feature is 
IE specific, that is, Firefox has a hell time with it, hence, it's IE only, 
yes, I like Firefox's firebug and find it very helpful but not for this case.  
I have firebug lite set up for the IE7, but it didn't show http call etc. from 
cfajaxproxy as in FF/FB... more thoughts? thanks. 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:325552
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: ajax cfc not working for Access DB -- odd stuff

2009-08-19 Thread Emmit Larson

  I've moved on to an open source cfml engine
 Don't ever do that.
Shirley, you jest?

Kind Regards,
Emmit

On Wed, Aug 19, 2009 at 6:29 PM, Dominic Watson 
watson.domi...@googlemail.com wrote:


   I've moved on to an open source cfml engine
 Don't ever do that.

 But seriously. First step of debugging ajax: install Firebug for Firefox if
 you haven't already. Next, enable all the firebug console options for your
 page and while viewing the console tab you should see your http post
 request
 made by your proxy js object (when you fire that event). You will then be
 able to examine the the data sent to your cfc and also the response.

 If there is no http request sent then the problem may well be with the
 cfajaxproxy code - if a request *is* sent, then we can safely move on from
 the client side code.

 With any luck, examining the http response will tell you exactly what's
 going wrong and will be a cf / railo error page.

 HTH

 Dominic


 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:32
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: ajax cfc not working for Access DB -- odd stuff

2009-08-19 Thread Don L

 I've moved on to an open source cfml engine
Don't ever do that.

But seriously. First step of debugging ajax: install Firebug for Firefox if
you haven't already. Next, enable all the firebug console options for your
page and while viewing the console tab you should see your http post request
made by your proxy js object (when you fire that event). You will then be
able to examine the the data sent to your cfc and also the response.

If there is no http request sent then the problem may well be with the
cfajaxproxy code - if a request *is* sent, then we can safely move on from
the client side code.

With any luck, examining the http response will tell you exactly what's
going wrong and will be a cf / railo error page.

HTH

Dominic

Very ODD.

The line of cfreturn #result# in the cfc should have been 
cfreturn true since we don't need data back from the cfc.

and was previously cfreturn true.  I've enabled the feature in FF.

case A, cfreturn true
ajax http post succeeds, RESPONSE: the {data} instead of TRUE ?

case B, in the cfc, cfset result=fielda, #fa#; fieldb, #fb#; memofield,#mf#
cfreturn #result#
(just for the heck of it),
ajax http post succeeds, RESPONSE: just the #mf# instead of fielda, #fa#; 
fieldb, #fb#; memofield,#mf# ?


FYI, the computer is totally offline and wireless device driver was turned off 
as well.



~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:325556
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: ajax cfc not working for Access DB -- odd stuff

2009-08-19 Thread Dave l

After looking at this code I am suddenly hungry for pound cake... dunno why???


~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:325558
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: AJAX

2009-07-02 Thread Andy Matthews

I'd avoid a book on AJAX and instead pick a book focusing on a specific
JavaScript framework such as jQuery, or ExtJS. If you just want AJAX then it
might be worth it to write your own code, but if you're wanting rich
internet apps then you'll be needing DOM manipulation and effects anyway.

My choice has, for the last 3 years, been jQuery. It's lightweight and super
easy to use. jQuery is to JavaScript like ColdFusion is to server side
languages. It makes it fast, easy, and good.

The Learning jQuery 1.3 book comes highly recommended. I'd also suggest you
jump on the official jQuery mailing list over at Google Groups:
http://groups.google.com/group/jquery-en


andy

-Original Message-
From: webmas...@pegweb.com [mailto:webmas...@pegweb.com] 
Sent: Thursday, July 02, 2009 12:56 PM
To: cf-talk
Subject: AJAX


Can anyone recommend a good book for AJAX? I want to start working on more
web 2.0 style apps and with the new CF server it seems to make it easier. I
just need to understand more about it and how it all works. I can JavaScript
and I can CF so I wouldn't think it would be too hard to pickup. Any
recommendations for reading material on the subject? Thanks in advance.

 

 

 





~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:324163
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: AJAX

2009-07-02 Thread webmaster

Thanks a lot Andy. I knew there were different frameworks out there but
wasn't sure how that fit in with AJAX. I assume they are all AJAX but
much like .NET they all have different built in functions etc?


-Original Message-
From: Andy Matthews [mailto:li...@commadelimited.com] 
Sent: Thursday, July 02, 2009 2:26 PM
To: cf-talk
Subject: RE: AJAX


I'd avoid a book on AJAX and instead pick a book focusing on a
specific
JavaScript framework such as jQuery, or ExtJS. If you just want AJAX
then it
might be worth it to write your own code, but if you're wanting rich
internet apps then you'll be needing DOM manipulation and effects
anyway.

My choice has, for the last 3 years, been jQuery. It's lightweight and
super
easy to use. jQuery is to JavaScript like ColdFusion is to server side
languages. It makes it fast, easy, and good.

The Learning jQuery 1.3 book comes highly recommended. I'd also suggest
you
jump on the official jQuery mailing list over at Google Groups:
http://groups.google.com/group/jquery-en


andy

-Original Message-
From: webmas...@pegweb.com [mailto:webmas...@pegweb.com] 
Sent: Thursday, July 02, 2009 12:56 PM
To: cf-talk
Subject: AJAX


Can anyone recommend a good book for AJAX? I want to start working on
more
web 2.0 style apps and with the new CF server it seems to make it
easier. I
just need to understand more about it and how it all works. I can
JavaScript
and I can CF so I wouldn't think it would be too hard to pickup. Any
recommendations for reading material on the subject? Thanks in advance.

 

 

 







~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:324164
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: AJAX

2009-07-02 Thread Nathan Strutz

Yes, the frameworks are different, but really, there is only a few that
matter, and only one of those that really actually matter.

jQuery is, by far, the best.

If you pay attention to most javascript questions people have these days,
it's something like this:

   Q: How do I do X in javascript?
   A: You don't. Just use jQuery.

If you want a whole widget ui framework, use ExtJs. Otherwise, just use
jQuery. It's unbelievably good.

jquery.com has a tutorial area http://docs.jquery.com/Tutorials which is
good. For me, it helps to have videos, so google it or hit up youtube for
them.

nathan strutz
[Blog and Family @ http://www.dopefly.com/]
[AZCFUG Manager @ http://www.azcfug.org/]
[Twitter @nathanstrutz]


On Thu, Jul 2, 2009 at 11:32 AM, webmas...@pegweb.com wrote:


 Thanks a lot Andy. I knew there were different frameworks out there but
 wasn't sure how that fit in with AJAX. I assume they are all AJAX but
 much like .NET they all have different built in functions etc?


 -Original Message-
 From: Andy Matthews [mailto:li...@commadelimited.com]
 Sent: Thursday, July 02, 2009 2:26 PM
 To: cf-talk
 Subject: RE: AJAX


 I'd avoid a book on AJAX and instead pick a book focusing on a
 specific
 JavaScript framework such as jQuery, or ExtJS. If you just want AJAX
 then it
 might be worth it to write your own code, but if you're wanting rich
 internet apps then you'll be needing DOM manipulation and effects
 anyway.

 My choice has, for the last 3 years, been jQuery. It's lightweight and
 super
 easy to use. jQuery is to JavaScript like ColdFusion is to server side
 languages. It makes it fast, easy, and good.

 The Learning jQuery 1.3 book comes highly recommended. I'd also suggest
 you
 jump on the official jQuery mailing list over at Google Groups:
 http://groups.google.com/group/jquery-en


 andy

 -Original Message-
 From: webmas...@pegweb.com [mailto:webmas...@pegweb.com]
 Sent: Thursday, July 02, 2009 12:56 PM
 To: cf-talk
 Subject: AJAX


 Can anyone recommend a good book for AJAX? I want to start working on
 more
 web 2.0 style apps and with the new CF server it seems to make it
 easier. I
 just need to understand more about it and how it all works. I can
 JavaScript
 and I can CF so I wouldn't think it would be too hard to pickup. Any
 recommendations for reading material on the subject? Thanks in advance.













 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:324165
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: AJAX

2009-07-02 Thread webmaster

Thanks a lot this is exactly what I needed.



-Original Message-
From: Nathan Strutz [mailto:str...@gmail.com] 
Sent: Thursday, July 02, 2009 2:54 PM
To: cf-talk
Subject: Re: AJAX


Yes, the frameworks are different, but really, there is only a few that
matter, and only one of those that really actually matter.

jQuery is, by far, the best.

If you pay attention to most javascript questions people have these
days,
it's something like this:

   Q: How do I do X in javascript?
   A: You don't. Just use jQuery.

If you want a whole widget ui framework, use ExtJs. Otherwise, just use
jQuery. It's unbelievably good.

jquery.com has a tutorial area http://docs.jquery.com/Tutorials which is
good. For me, it helps to have videos, so google it or hit up youtube
for
them.

nathan strutz
[Blog and Family @ http://www.dopefly.com/]
[AZCFUG Manager @ http://www.azcfug.org/]
[Twitter @nathanstrutz]


On Thu, Jul 2, 2009 at 11:32 AM, webmas...@pegweb.com wrote:


 Thanks a lot Andy. I knew there were different frameworks out there
but
 wasn't sure how that fit in with AJAX. I assume they are all AJAX but
 much like .NET they all have different built in functions etc?


 -Original Message-
 From: Andy Matthews [mailto:li...@commadelimited.com]
 Sent: Thursday, July 02, 2009 2:26 PM
 To: cf-talk
 Subject: RE: AJAX


 I'd avoid a book on AJAX and instead pick a book focusing on a
 specific
 JavaScript framework such as jQuery, or ExtJS. If you just want AJAX
 then it
 might be worth it to write your own code, but if you're wanting rich
 internet apps then you'll be needing DOM manipulation and effects
 anyway.

 My choice has, for the last 3 years, been jQuery. It's lightweight and
 super
 easy to use. jQuery is to JavaScript like ColdFusion is to server side
 languages. It makes it fast, easy, and good.

 The Learning jQuery 1.3 book comes highly recommended. I'd also
suggest
 you
 jump on the official jQuery mailing list over at Google Groups:
 http://groups.google.com/group/jquery-en


 andy

 -Original Message-
 From: webmas...@pegweb.com [mailto:webmas...@pegweb.com]
 Sent: Thursday, July 02, 2009 12:56 PM
 To: cf-talk
 Subject: AJAX


 Can anyone recommend a good book for AJAX? I want to start working on
 more
 web 2.0 style apps and with the new CF server it seems to make it
 easier. I
 just need to understand more about it and how it all works. I can
 JavaScript
 and I can CF so I wouldn't think it would be too hard to pickup. Any
 recommendations for reading material on the subject? Thanks in
advance.













 



~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:324166
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: AJAX

2009-07-02 Thread Cutter (ColdFusion)

Guys, I love JQuery too, for DOM manipulation. But, if you're needing 
ajaxified 'widgets' then Ext Js is a better choice. Not only do they 
have an extensive well polished and consistent library, but you can use 
the cfajax tags to rapid prototype an app, then build out final versions 
with something that looks exactly the same (since that's what they use 
under the hood).

Shameless Promotion: Good Book? (See the signature block)

Steve Cutter Blades
Adobe Certified Professional
Advanced Macromedia ColdFusion MX 7 Developer

Co-Author of Learning Ext JS
http://www.packtpub.com/learning-ext-js/book
_
http://blog.cutterscrossing.com



~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:324167
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


RE: AJAX

2009-07-02 Thread webmaster

Can you explain in more detail ajaxified widgets?

I'm looking to prefetch possible search keywords in a search field.
Get a different image from the database when a user clicks and display
it without refreshing the page.
Change search results without refreshing the page.

Stuff like that.



-Original Message-
From: Cutter (ColdFusion) [mailto:cold.fus...@cutterscrossing.com] 
Sent: Thursday, July 02, 2009 4:20 PM
To: cf-talk
Subject: Re: AJAX


Guys, I love JQuery too, for DOM manipulation. But, if you're needing 
ajaxified 'widgets' then Ext Js is a better choice. Not only do they 
have an extensive well polished and consistent library, but you can use 
the cfajax tags to rapid prototype an app, then build out final versions

with something that looks exactly the same (since that's what they use 
under the hood).

Shameless Promotion: Good Book? (See the signature block)

Steve Cutter Blades
Adobe Certified Professional
Advanced Macromedia ColdFusion MX 7 Developer

Co-Author of Learning Ext JS
http://www.packtpub.com/learning-ext-js/book
_
http://blog.cutterscrossing.com





~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:324168
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: AJAX

2009-07-02 Thread Cutter (ColdFusion)

widgets are the autosuggest combobox, the html data grid, border 
layouts, modal windows, etc., typically loaded by a remote source via 
Ajax. So, some of what you mention (the search field) falls under that 
category, while some of the other stuff is just pure Ajax, for which 
either JQuery or Ext Core are both well suited.

Steve Cutter Blades
Adobe Certified Professional
Advanced Macromedia ColdFusion MX 7 Developer

Co-Author of Learning Ext JS
http://www.packtpub.com/learning-ext-js/book
_
http://blog.cutterscrossing.com


On 7/2/2009 3:40 PM, webmas...@pegweb.com wrote:
 Can you explain in more detail ajaxified widgets?

 I'm looking to prefetch possible search keywords in a search field.
 Get a different image from the database when a user clicks and display
 it without refreshing the page.
 Change search results without refreshing the page.

 Stuff like that.



 -Original Message-
 From: Cutter (ColdFusion) [mailto:cold.fus...@cutterscrossing.com]
 Sent: Thursday, July 02, 2009 4:20 PM
 To: cf-talk
 Subject: Re: AJAX


 Guys, I love JQuery too, for DOM manipulation. But, if you're needing
 ajaxified 'widgets' then Ext Js is a better choice. Not only do they
 have an extensive well polished and consistent library, but you can use
 the cfajax tags to rapid prototype an app, then build out final versions

 with something that looks exactly the same (since that's what they use
 under the hood).

 Shameless Promotion: Good Book? (See the signature block)

 Steve Cutter Blades
 Adobe Certified Professional
 Advanced Macromedia ColdFusion MX 7 Developer

 Co-Author of Learning Ext JS
 http://www.packtpub.com/learning-ext-js/book
 _
 http://blog.cutterscrossing.com





 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:324172
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: AJAX Solution to Read database and load new Image

2009-03-29 Thread Dan Baughman

There are just a ton of ways to do exactly this, its a bit of general
question.
It sounds like maybe you are looking for some example code?  Are you using
any Javascript frameworks?

The general flow to the update is going to be this:

   1. A function is called via a page onload or something.
   2. This function creates an XMLHTTP request and sets the callback
   function that will get passed the data returned from the http request.
   3. The call back function receives this data, and does the javascript to
   set the image attributes appropriately, it then does a setTimeout back to
   the original function. (goto step 1)


Creating the functionality involves the server side programming. When I was
first learning Javascript and using the XMLHTTP request i was using a
serverside script that returned raw html or delimited strings that was
parsed as appropriate by the callback function. In this case the server side
script could simply return the relative path to the image which the callback
function could then document.getElementById('imageid').src = returnedText.

If you have time and are actually trying to learn JS, a better approach
would be to have the server side script generate a JSON object which would
make it easier to add more than one value to the data it returned to the
clientside JS, say the next step in improving this would be to return a
string that would serve as a caption below the image. JSON is a cake to
parse client side and is lighter weight that XML.

I have a ghetto xmlhttprequest object i use but I'd recommend you go get
jQuery and read 3 or 4 pages of documentation on their ajax object. It would
allow you very simply return the full img tag from the server side script,
and then periodically populate some arbitray div with the results.

HTH
Dan



On Sun, Mar 29, 2009 at 9:36 AM, Tom LaBatt tlab...@daybreakengineering.com
 wrote:


 I am starting out with AJAX and would like to create a simple app to use on
 my site.

 I have a database table setup (images) with image information in it of
 fields named: imageid, imagename, imageactive, and I want to have a
 client go to a url that displays the image using the img src= tag of the
 image in the database that is marked as imageactive. Then using AJAX to
 continuously check that database table from the clients page and when a new
 image it tagged as imageactive then I want the clients page to refresh,
 load and display the new image that is tagged in the database as
 imageactive without them having to click on anything.  The client just
 sits there and watching the screen while I am talking to them over the
 phone.

 As the presenter on the phone talking to them I am controling from my
 computer what image in the database table that is being tagged as
 imageactive, toggling that image and the clients machine reads that
 database, loads the new image and refreshes the screen if it was different
 from the one that is currently displayed on their screen.

 Is there a simple AJAX solution that can accomplish this for me?

 Please let me know if I am unclear as to what I am trying to accomplish.

 V/R,
 Tom

 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:321079
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: AJAX Solution to Read database and load new Image

2009-03-29 Thread Tony Bentley

The table would contain each parameter of the image; src=(col1) alt=(col2) 
title=(col3) etc. Use cfajaxproxy to do the call using a cfc to control the 
request and return the data set. Use javascript to replace the image attributes 
with the new result. 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:321081
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Ajax cfgrid bind problem

2009-03-04 Thread scott welker

hi there, 

was there an actual hot fix released for this issue? i'm experiencing the exact 
same problem. 

thanks.

scott
scott.wel...@gmail.com 


I am trying to use the cfgrid CFC binding feature in CF8 but I am
having trouble getting the CFC to populate the Ajax grid.

URL: http://site/
Folder: c:\inetpub\wwwroot

URL: http://site/projects/ (virtual directory)
Folder: c:\projects\
This folder has a cfc called myCFC

My bind attribute starts with cfc:projects.myCFC.function

The page gets compiled and sent to the browser successfully, meaning
ColdFusion finds the CFC initially. However, looking at the source
code I see that the Ajax request is looking for /myCFC.cfc instead
of /projects/myCFC.cfc. The predicable result is that the Ajax grid
doesn't get populated and a missing file error is logged in
Application.log.

What do I need to do to get this Ajax call to look in the correct location?

Thanks,
Mike 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:320113
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: ajax and special characters

2009-02-26 Thread Richard White

thanks to both of you for your comments we will look into these

in relation to the client side - when we want to send data to coldfusion do you 
only use the escape function in Javascript or do you use some other means?

thanks

In addition to Cutter's points about JSON encoding, look into the
URLEncodedFormat and URLDecode.

If, when making your Ajax calls, you pass the returnFormat = JSON 
attribute to your CFC method, then CF will automatically encode the result
when creating the JSON output. When passing a JSON value to ColdFusion,
inside your CFC method you can use the DeserializeJson() method to decode
the value.

Steve Cutter Blades
Adobe Certified Professional
Advanced Macromedia ColdFusion MX 7 Developer

Co-Author of Learning Ext JS
http://www.packtpub.com/learning-ext-js/book
_
http://blog.cutterscrossing.com

Richard White wrote:
 hi
 
 we are developing an Ajax based system using JavaScript and Coldfusion.
 
 we have only just started to realise the need for escaping / encoding
special characters. how do you guys deal with this, e.g:
there may be  to understand this.
 
 thanks
 
 richard
 
 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:319865
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: ajax and special characters

2009-02-25 Thread Cutter (CFRelated)

If, when making your Ajax calls, you pass the returnFormat = JSON 
attribute to your CFC method, then CF will automatically encode the 
result when creating the JSON output. When passing a JSON value to 
ColdFusion, inside your CFC method you can use the DeserializeJson() 
method to decode the value.

Steve Cutter Blades
Adobe Certified Professional
Advanced Macromedia ColdFusion MX 7 Developer

Co-Author of Learning Ext JS
http://www.packtpub.com/learning-ext-js/book
_
http://blog.cutterscrossing.com

Richard White wrote:
 hi
 
 we are developing an Ajax based system using JavaScript and Coldfusion.
 
 we have only just started to realise the need for escaping / encoding 
 special characters. how do you guys deal with this, e.g:
 
 1) how do we deal with the special characters in JavaScript to ensure that 
 Coldfusion receives them correctly
 2) how does Coldfusion decode them to read them exactly how they were sent
 3) how does Coldfusion send them back encoded to ensure JavaScript receives 
 them OK
 4) how does JavaScript then decode them when it receives them
 
 i would appreciate any advice on where to start looking and any tutorials 
 there may be  to understand this.
 
 thanks
 
 richard 
 
 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:319789
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


RE: ajax and special characters

2009-02-25 Thread Andy Matthews

In addition to Cutter's points about JSON encoding, look into the
URLEncodedFormat and URLDecode.

-Original Message-
From: Cutter (CFRelated) [mailto:cold.fus...@cutterscrossing.com] 
Sent: Wednesday, February 25, 2009 8:34 AM
To: cf-talk
Subject: Re: ajax and special characters


If, when making your Ajax calls, you pass the returnFormat = JSON 
attribute to your CFC method, then CF will automatically encode the result
when creating the JSON output. When passing a JSON value to ColdFusion,
inside your CFC method you can use the DeserializeJson() method to decode
the value.

Steve Cutter Blades
Adobe Certified Professional
Advanced Macromedia ColdFusion MX 7 Developer

Co-Author of Learning Ext JS
http://www.packtpub.com/learning-ext-js/book
_
http://blog.cutterscrossing.com

Richard White wrote:
 hi
 
 we are developing an Ajax based system using JavaScript and Coldfusion.
 
 we have only just started to realise the need for escaping / encoding
special characters. how do you guys deal with this, e.g:
 
 1) how do we deal with the special characters in JavaScript to ensure 
 that Coldfusion receives them correctly
 2) how does Coldfusion decode them to read them exactly how they were 
 sent
 3) how does Coldfusion send them back encoded to ensure JavaScript 
 receives them OK
 4) how does JavaScript then decode them when it receives them
 
 i would appreciate any advice on where to start looking and any tutorials
there may be  to understand this.
 
 thanks
 
 richard
 
 



~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:319794
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: ajax controls break after time interval, return 302

2008-11-24 Thread brad
Hmmm..

next ajax call fails, returning with a 302 (temporarily moved)
What is the value of the location header?

and non-ajax calls detect it appropriately
Do you mean loading it in a browser?  Are you saying that the browser
gets a 200, or the browser just follows the redirect?

~Brad


 Original Message 
Subject: ajax controls break after time interval, return 302
From: Phil Stone [EMAIL PROTECTED]
Date: Mon, November 24, 2008 1:29 pm
To: cf-talk cf-talk@houseoffusion.com

Hi,

First time poster here. I am using several ajax controls in a CF
application, and they work fine...mostly. I am seeing a time-interval
related problem; if a page w/ ajax controls is left inactive for about
30 minutes, the next ajax call fails, returning with a 302 (temporarily
moved) code.

The session is *not* timed out when this happens (I have set the session
timeout to 60 minutes, and non-ajax calls detect it appropriately). I
can't imagine what other time interval would match up to this ~30 min.
value. Does anybody have any ideas?

Thank you.


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:315837
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: ajax controls break after time interval, return 302

2008-11-24 Thread Wil Genovese
Are you this is not due to a login timing out? The 302 http error is a
redirect code which makes sense if your login expired and your code is then
trying to redirect the ajax call to the login page.  Can you determine which
page the redirect is attempting to load?

This could still be a session timing out depending on how your application
re-loads a users session. Do you have you application detecting users via a
cookie and auto re-logging them in and re-building the session?  If so does
the page the ajax call is referencing have the same ability to auto
re-login?

Usually this is what has happened when I've seen this error in the past.

Wil Genovese
Sr. Web Application Developer


On Mon, Nov 24, 2008 at 1:29 PM, Phil Stone [EMAIL PROTECTED] wrote:

 Hi,

 First time poster here. I am using several ajax controls in a CF
 application, and they work fine...mostly.  I am seeing a time-interval
 related problem; if a page w/ ajax controls is left inactive for about 30
 minutes, the next ajax call fails, returning with a 302 (temporarily moved)
 code.

 The session is *not* timed out when this happens (I have set the session
 timeout to 60 minutes, and non-ajax calls detect it appropriately).  I can't
 imagine what other time interval would match up to this ~30 min. value.
  Does anybody have any ideas?

 Thank you.


 Phil Stone

 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:315840
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: ajax controls break after time interval, return 302

2008-11-24 Thread Phil Stone
Wil Genovese wrote:
 Are you this is not due to a login timing out? The 302 http error is a
 redirect code which makes sense if your login expired and your code is then
 trying to redirect the ajax call to the login page.  

You may be on to something...there is CAS (single sign-on) 
authentication wrapping this application.  I will direct my energies 
that way and see what I can find.

 Can you determine which
 page the redirect is attempting to load?
   

I only see the 302 code and message 'Found' in the error handler for the 
ColdFusion.navigate() call.  I'll dig into some logs and see what I can 
find.


 This could still be a session timing out depending on how your application
 re-loads a users session. Do you have you application detecting users via a
 cookie and auto re-logging them in and re-building the session?  If so does
 the page the ajax call is referencing have the same ability to auto
 re-login?
   

Nothing fancy like that; when I said handling session timeout, I meant 
detecting it in application.cfm and putting up an error page.  The ajax 
error is appearing well before session timeout, though.

 Usually this is what has happened when I've seen this error in the past.

 Wil Genovese
 Sr. Web Application Developer
   

Thank you for the idea pointing to the authentication wrapper.


 On Mon, Nov 24, 2008 at 1:29 PM, Phil Stone [EMAIL PROTECTED] wrote:

   
 Hi,

 First time poster here. I am using several ajax controls in a CF
 application, and they work fine...mostly.  I am seeing a time-interval
 related problem; if a page w/ ajax controls is left inactive for about 30
 minutes, the next ajax call fails, returning with a 302 (temporarily moved)
 code.

 The session is *not* timed out when this happens (I have set the session
 timeout to 60 minutes, and non-ajax calls detect it appropriately).  I can't
 imagine what other time interval would match up to this ~30 min. value.
  Does anybody have any ideas?

 Thank you.


 Phil Stone


 

 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:315841
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: ajax controls break after time interval, return 302

2008-11-24 Thread Phil Stone
Pardon the reply to my own message, but Wil, you were right on...CAS had 
expired my authentication, and when an ajax call stumbled into this, the 
redirect wasn't handled properly (not sure it can be in the middle of 
say, ColdFusion.nagivate(), other than triggering the onError() 
callback).  For now, the CAS timeout has been set to just longer than 
the session timeout; while I'm not sure this will completely prevent the 
error, it should make it vanishingly improbable.

thanks,

Phil


Phil Stone wrote:
 Wil Genovese wrote:
   
 Are you this is not due to a login timing out? The 302 http error is a
 redirect code which makes sense if your login expired and your code is then
 trying to redirect the ajax call to the login page.  
 

 You may be on to something...there is CAS (single sign-on) 
 authentication wrapping this application.  I will direct my energies 
 that way and see what I can find.

   
 Can you determine which
 page the redirect is attempting to load?
   
 

 I only see the 302 code and message 'Found' in the error handler for the 
 ColdFusion.navigate() call.  I'll dig into some logs and see what I can 
 find.


   
 This could still be a session timing out depending on how your application
 re-loads a users session. Do you have you application detecting users via a
 cookie and auto re-logging them in and re-building the session?  If so does
 the page the ajax call is referencing have the same ability to auto
 re-login?
   
 

 Nothing fancy like that; when I said handling session timeout, I meant 
 detecting it in application.cfm and putting up an error page.  The ajax 
 error is appearing well before session timeout, though.

   
 Usually this is what has happened when I've seen this error in the past.

 Wil Genovese
 Sr. Web Application Developer
   
 

 Thank you for the idea pointing to the authentication wrapper.

   
 On Mon, Nov 24, 2008 at 1:29 PM, Phil Stone [EMAIL PROTECTED] wrote:

   
 
 Hi,

 First time poster here. I am using several ajax controls in a CF
 application, and they work fine...mostly.  I am seeing a time-interval
 related problem; if a page w/ ajax controls is left inactive for about 30
 minutes, the next ajax call fails, returning with a 302 (temporarily moved)
 code.

 The session is *not* timed out when this happens (I have set the session
 timeout to 60 minutes, and non-ajax calls detect it appropriately).  I can't
 imagine what other time interval would match up to this ~30 min. value.
  Does anybody have any ideas?

 Thank you.


 Phil Stone


 
   
 

 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:315843
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


RE: Ajax: Who's into Ajax and Business Cases

2008-04-21 Thread Steve Brownlee
Don:

If you want to ask questions about AJAX, there are a vast number of other
resources available to you.  Each of the major libraries has their own
message board or Google group.

Here's some URLs to get you started...
http://www.adobe.com/cfusion/webforums/forum/categories.cfm?forumid=72catid
=602
http://groups.google.com/group/jquery-en/
http://forum.mootools.net/
http://extjs.com/forum/
http://tech.groups.yahoo.com/group/ydn-javascript/
http://www.prototypejs.org/discuss


-Original Message-
From: Don L [mailto:[EMAIL PROTECTED] 
Sent: Friday, April 18, 2008 5:35 PM
To: CF-Talk
Subject: Ajax: Who's into Ajax and Business Cases

First of all, the Ajax list activitity is not high, hence, I'm posting it to
this one for more readership (it's also cf-related).

The main purpose of this post to find out who in this community are Much
Into Ajax (I wish I could make them bold, to stand out), and equally
important, you know how to make business cases with ajax features and
functions.

Secondly, about Ajax resource (even cf-specific ajax resources) sharing.
Let me start with one, I find www.ajaxian.com useful.

Thanks.

P.S. 1) It would be nice if people post Ajax related topic with prefix of
Ajax:  for future reference.
P.S. 2) I propose to the list owner, to consider to expand the ColdFusion
Talk to Web App Development Talk centered on ColdFusion, I know a bit
long ...



~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:303852
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Ajax: Who's into Ajax and Business Cases

2008-04-21 Thread Don L
Don:

If you want to ask questions about AJAX, there are a vast number of other
resources available to you.  Each of the major libraries has their own
message board or Google group.

Here's some URLs to get you started...
http://www.adobe.com/cfusion/webforums/forum/categories.cfm?forumid=72catid
=602
http://groups.google.com/group/jquery-en/
http://forum.mootools.net/
http://extjs.com/forum/
http://tech.groups.yahoo.com/group/ydn-javascript/
http://www.prototypejs.org/discuss

Great, Steve, thank you very much.  Don 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:303923
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Ajax: Who's into Ajax and Business Cases

2008-04-18 Thread James Holmes
It would also be nice if people posted ajax topics in the ajax list
and OT threads in CF-OT but history shows that's not likely either.

On Sat, Apr 19, 2008 at 6:34 AM, Don L [EMAIL PROTECTED] wrote:

  P.S. 1) It would be nice if people post Ajax related topic with prefix of 
 Ajax:  for future reference.
  P.S. 2) I propose to the list owner, to consider to expand the ColdFusion 
 Talk to Web App Development Talk centered on ColdFusion, I know a bit long 
 ...


-- 
mxAjax / CFAjax docs and other useful articles:
http://www.bifrost.com.au/blog/

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:303789
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: Ajax: Who's into Ajax and Business Cases

2008-04-18 Thread Bobby Hartsfield
If everyone wanted to talk about Ajax enough to expand the list, they'd be
on the Ajax list. 'the list owner' has worked hard to make this list what it
is and continues to work hard keeping off-topic traffic off of it for a
reason. Why willingly open up the flood gates now just because you have some
off topic questions that don't get answered somewhere else?

  P.S. 2) I propose to the list owner, to consider to expand the
ColdFusion Talk to Web App Development Talk centered on ColdFusion, I
know a bit long ...


-- 
mxAjax / CFAjax docs and other useful articles:
http://www.bifrost.com.au/blog/



~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:303791
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: ajax submit form

2008-04-17 Thread Matt Williams
On Thu, Apr 17, 2008 at 9:18 AM, Chad Gray [EMAIL PROTECTED] wrote:
 There are so many options it seems to use Ajax now in CF8.

  Here is what I want to do, what is the best way to achieve it?

  I have a search form that submits to an action page and displays results out 
 of a database.

  I don't want to re-write my pages, I just want the submit to not refresh the 
 page and return the results on the same page as the search form.

Hold a magic AJAX wand over your code and say the magic spell:
Bawitdaba da bang a dang diggy diggy diggy said the boogy said up
jump the boogy

Sorry. You will have some rewrite to do and unfortunately there is not
a best way. You need to look at cfajaxproxy. There are many other
ways to do this without using CF8's ajax abilities too but using a
javascript library such as scriptaculous, prototype or jQuery.

-- 
Matt Williams
It's the question that drives us.

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:303670
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


RE: ajax submit form

2008-04-17 Thread Chad Gray
Does amazon stock these magic AJAX wands?  :)

Sorry for the ambiguous question.


I looked up CFDivs and binding and there are possibilities here.  I just need 
to do some more reading.

cfform
cfinput name=queryString type=text value=plates white
/cfform

h3Results/h3
cfdiv bind=url:searchTest.cfm?query={queryString} id=theDiv





-Original Message-
From: Matt Williams [mailto:[EMAIL PROTECTED] 
Sent: Thursday, April 17, 2008 10:45 AM
To: CF-Talk
Subject: Re: ajax submit form

On Thu, Apr 17, 2008 at 9:18 AM, Chad Gray [EMAIL PROTECTED] wrote:
 There are so many options it seems to use Ajax now in CF8.

  Here is what I want to do, what is the best way to achieve it?

  I have a search form that submits to an action page and displays results out 
 of a database.

  I don't want to re-write my pages, I just want the submit to not refresh the 
 page and return the results on the same page as the search form.

Hold a magic AJAX wand over your code and say the magic spell:
Bawitdaba da bang a dang diggy diggy diggy said the boogy said up
jump the boogy

Sorry. You will have some rewrite to do and unfortunately there is not
a best way. You need to look at cfajaxproxy. There are many other
ways to do this without using CF8's ajax abilities too but using a
javascript library such as scriptaculous, prototype or jQuery.

-- 
Matt Williams
It's the question that drives us.



~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:303671
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: ajax submit form

2008-04-17 Thread Kay Smoljak
On Thu, Apr 17, 2008 at 10:44 PM, Matt Williams [EMAIL PROTECTED] wrote:
  Sorry. You will have some rewrite to do and unfortunately there is not
  a best way. You need to look at cfajaxproxy. There are many other
  ways to do this without using CF8's ajax abilities too but using a
  javascript library such as scriptaculous, prototype or jQuery.

And most importantly, decide before you spend a lot of time if it's
appropriate for the application. Ajaxified search results might look
sexy, but there could be accessibility issues, especially if it's a
public facing site. Unless you take a lot of care, they won't be
search engine indexable (may or may not be an issue) or bookmarkable.
And don't forget to look at what happens when a user agent doesn't
have JavaScript - like many mobile device browsers.

Just because you can, doesn't mean you should...

-- 
Kay Smoljak
business: www.cleverstarfish.com
coldfusion: kay.smoljak.com
personal: goatlady.wordpress.com | heapsbad.com

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:303672
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: ajax submit form

2008-04-17 Thread Rey Bango
Hi Chad,

You'll hear some good advice about properly using Ajax-based 
technologies and the advice I can give you is to look at progressive 
enhancement. It's ensuring that your application works as expected 
using traditional development methods and then gradually enhancing it to 
leverage JavaScript, DHTML and Ajax. In your case, it appears that 
you're halfway there since you already have a working search form. The 
next step is to begin adding the JavaScript, DHTML and Ajax gradually 
until you get the desired effect that you, all the while ensuring that 
your page still functions when JS is not enabled.

I would urge you to look up the topic before wandering too far into 
making substantial updates:

http://en.wikipedia.org/wiki/Progressive_Enhancement

Rey...

Chad Gray wrote:
 Does amazon stock these magic AJAX wands?  :)
 
 Sorry for the ambiguous question.
 
 
 I looked up CFDivs and binding and there are possibilities here.  I just need 
 to do some more reading.
 
 cfform
   cfinput name=queryString type=text value=plates white
 /cfform
 
 h3Results/h3
 cfdiv bind=url:searchTest.cfm?query={queryString} id=theDiv
 
 
 
 
 
 -Original Message-
 From: Matt Williams [mailto:[EMAIL PROTECTED] 
 Sent: Thursday, April 17, 2008 10:45 AM
 To: CF-Talk
 Subject: Re: ajax submit form
 
 On Thu, Apr 17, 2008 at 9:18 AM, Chad Gray [EMAIL PROTECTED] wrote:
 There are so many options it seems to use Ajax now in CF8.

  Here is what I want to do, what is the best way to achieve it?

  I have a search form that submits to an action page and displays results 
 out of a database.

  I don't want to re-write my pages, I just want the submit to not refresh 
 the page and return the results on the same page as the search form.
 
 Hold a magic AJAX wand over your code and say the magic spell:
 Bawitdaba da bang a dang diggy diggy diggy said the boogy said up
 jump the boogy
 
 Sorry. You will have some rewrite to do and unfortunately there is not
 a best way. You need to look at cfajaxproxy. There are many other
 ways to do this without using CF8's ajax abilities too but using a
 javascript library such as scriptaculous, prototype or jQuery.
 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:303678
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: ajax submit form

2008-04-17 Thread Chad Gray
Guess I should have explained since the topic is shifting this direction.

I don't have to worry about whether their JS is turned on.  It is for a 
Intranet web site that I have control over what browsers and browser settings 
are being used.

I just need to find the best functions in CF8 to accomplish my goal.  So far it 
looks like I have to brush up on my javascript to get CF8 to do what I want.

I will check out the link you sent.

So far I have the following,  but I need to switch it to a form instead of a 
hyperlink and somehow get the text input into the ColdFusion.navigate function. 
 I think I can do this with javascript.



html
head
!--- The Callback handler puts text in the window.cfm callback div. ---
script language=javascript
var mycallBack = function(){
document.getElementById(callback).innerHTML = brbrbThis is 
printed by the callback handler./b;
} 

!--- The error handler pops an alert with the error code and message. ---
var myerrorhandler = function(errorCode,errorMessage){
alert([In Error Handler] + \n\n + Error Code:  + errorCode + 
\n\n + Error Message:  + errorMessage);
} 
/script
/head

body
cfdiv id=w1
This is a cfwindow control.brbr
a href=javascript:ColdFusion.navigate('searchTest.cfm?query=White 
Plates','w2',
mycallBack,myerrorhandler);Click/a to navigate Window 2/a
/cfdiv

cfdiv id=w2
This is a second cfwindow control.
/cfdiv

/body
/html



-Original Message-
From: Rey Bango [mailto:[EMAIL PROTECTED] 
Sent: Thursday, April 17, 2008 12:23 PM
To: CF-Talk
Subject: Re: ajax submit form

Hi Chad,

You'll hear some good advice about properly using Ajax-based 
technologies and the advice I can give you is to look at progressive 
enhancement. It's ensuring that your application works as expected 
using traditional development methods and then gradually enhancing it to 
leverage JavaScript, DHTML and Ajax. In your case, it appears that 
you're halfway there since you already have a working search form. The 
next step is to begin adding the JavaScript, DHTML and Ajax gradually 
until you get the desired effect that you, all the while ensuring that 
your page still functions when JS is not enabled.

I would urge you to look up the topic before wandering too far into 
making substantial updates:

http://en.wikipedia.org/wiki/Progressive_Enhancement

Rey...

Chad Gray wrote:
 Does amazon stock these magic AJAX wands?  :)
 
 Sorry for the ambiguous question.
 
 
 I looked up CFDivs and binding and there are possibilities here.  I just need 
 to do some more reading.
 
 cfform
   cfinput name=queryString type=text value=plates white
 /cfform
 
 h3Results/h3
 cfdiv bind=url:searchTest.cfm?query={queryString} id=theDiv
 
 
 
 
 
 -Original Message-
 From: Matt Williams [mailto:[EMAIL PROTECTED] 
 Sent: Thursday, April 17, 2008 10:45 AM
 To: CF-Talk
 Subject: Re: ajax submit form
 
 On Thu, Apr 17, 2008 at 9:18 AM, Chad Gray [EMAIL PROTECTED] wrote:
 There are so many options it seems to use Ajax now in CF8.

  Here is what I want to do, what is the best way to achieve it?

  I have a search form that submits to an action page and displays results 
 out of a database.

  I don't want to re-write my pages, I just want the submit to not refresh 
 the page and return the results on the same page as the search form.
 
 Hold a magic AJAX wand over your code and say the magic spell:
 Bawitdaba da bang a dang diggy diggy diggy said the boogy said up
 jump the boogy
 
 Sorry. You will have some rewrite to do and unfortunately there is not
 a best way. You need to look at cfajaxproxy. There are many other
 ways to do this without using CF8's ajax abilities too but using a
 javascript library such as scriptaculous, prototype or jQuery.
 



~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:303679
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


  1   2   3   4   5   6   7   >