Ok, I see what is being sent. If I dump them to a pdf, I can see them fine. 

        <cfdocument format="PDF" overwrite="yes" filename="whatyousee.pdf">
              FORM:
            <cfdump var="#form#" />
             <cfoutput>
            #form.duration#
             #form.action#
            #form.source#
            </cfoutput>
        </cfdocument>

But when I just submit them to a page with just an insert Query, using the 
form.variable, I get an error! This is making NO sense.

        <cfquery name="create" datasource="webstatistics-test">
            INSERT INTO tracker(clickCount, duration, action, dept, videoFile, 
datePlayed)
                VALUES(1, #form.duration#, '#form.action#', 'PRMC', 
'#form.source#', #Now()#)
        </cfquery>

Is Flex waiting for something else? Do I need to send something back. I just 
want to insert a counter into the database each time the user leaves the page 
or clicks the stop button.....

----------------------------------------
From: "valdhor" <[EMAIL PROTECTED]>
Sent: Monday, December 08, 2008 12:50 PM
To: [email protected]
Subject: [flexcoders] Re: Desperate Times...Desprate Messures: What is sent by 
HTTPRequest? 

Grab a copy of Charles (http://www.charlesproxy.com). This will show

you exactly what is being sent to your server.

--- In [email protected], "wkolcz" <[EMAIL PROTECTED]> wrote:

>

> I am just trying to send 4 parameters over to a CFC or CFM page to

insert into the database and both WebService and HTTPRequest are

giving me fits. 

> 

> Ok here is the scenerio:

> When the user watches a video, it starts a timer, when the user

either exits the page or clicks the 'stop' button it triggers a

function that sends out 3 pieces of info: what video, how long, and

whether they clicked stop or left. I am packaging that information

into an Object and sending it to a .cfm page with a query on it, ready

to insert.

> 

> What exactly is my .cfm page 'seeing' sent to it? Are they form.,

url., or just the stuct name?

> 

> Here is my AS code:

> trackInfo.duration =  myTimer.currentCount;

> trackInfo.action = "Video Stopped";    

> trackInfo.source = source;

> var service:HTTPService = new HTTPService();

> service.url =

"https://ummciisdevweb22.med.umich.edu/videotracking/tracker.cfm";;

> service.method = "POST";

> service.addEventListener(ResultEvent.RESULT, countHandler);

> service.addEventListener(FaultEvent.FAULT, alertFault);

> service.send(trackInfo);

> 

> How should I constuct the query on the tracker.cfm page? Something like:

> 

>         <cfquery name="countIt" datasource="#request.dsn#">

>             Insert Into tracker (clickCount, duration, action,

videoFile, datePlayed)

>                 VALUES(1, #trackInfo.duration#,

'#trackInfo.action#', '#trackInfo.source#', #Now()#)

>         </cfquery>

>



Reply via email to