Solved

Silly question I think but....

Posted on 2001-06-20
4
163 Views
Last Modified: 2013-12-24


I have a form which submits a few controls to an action
page.


This page calls cfhttp and I wanna see exactly what is being passed to the cfhttp tag.

Unfortunately I can't pop up a javascript alert showing what the action template converts the form input to
just before the call to cfhttp...as the whole page must be produced first.....is that correct?
0
Comment
Question by:theworpler
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 4

Expert Comment

by:CF_Spike
ID: 6209555
You can't use Javascript to show what the form is sending if you want to stop processing of the page before the CFHTTP tag. If you don't mind the cfhttp being fired then you can do the following:

<CFSET formdata = "">
<CFLOOP list="#form.fieldnames#" index="i">
<CFSET formdata = formdata & i & ' - ' & Evaluate('form.' & i) & '\n'>
</CFLOOP>

<SCRIPT>
alert('#formdata#');
</SCRIPT>

If you want to see exactly what is being passed to the action page without firing the cfhttp tag you can do the following:

<CFOUTPUT>
Form data:
<CFLOOP LIST="#form.fieldnames#" index="i">
#i# - #Evaluate('form.' & i)#<BR>
</CFLOOP>
<CFOUTPUT>
<CFABORT>

<CFHTTP...

Spike
0
 
LVL 5

Accepted Solution

by:
Yog earned 50 total points
ID: 6209661
Otherwise you can try executing the other page (cfhttp page from this page , return some parameter if your condition is met, and alert them in the same page

0
 

Author Comment

by:theworpler
ID: 6209728
Thanks
I'll try those.

I was just being lazy and wanted to bung some js
at the head of the action page.....
0
 

Author Comment

by:theworpler
ID: 6211118
Thanks all!!
0

Featured Post

Enroll in May's Course of the Month

May’s Course of the Month is now available! Experts Exchange’s Premium Members and Team Accounts have access to a complimentary course each month as part of their membership—an extra way to increase training and boost professional development.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

If you don't have the right permissions set for your WordPress location in IIS, you won't be able to perform automatic updates. Here's how to fix the problem.
Lease-to-own eliminates the expenditure of hardware replacement and allows you to pay off the server over time. Usually, this is much cheaper than leasing servers. Think of lease-to-own as credit without interest.
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…
Attackers love to prey on accounts that have privileges. Reducing privileged accounts and protecting privileged accounts therefore is paramount. Users, groups, and service accounts need to be protected to help protect the entire Active Directory …

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question