RE: [flexcoders] Re: POST not working

2007-01-10 Thread Merrill, Jason
Locally?  Security restrictions won't allow you to do that.  To do it on
the web, you would have to use something like .NET or PHP, and then
download the file to the local system. That would be pretty easy.
 

Jason Merrill 
Bank of America
Learning  Organizational Effectiveness 
  
  
  
  
  

 




From: flexcoders@yahoogroups.com
[mailto:[EMAIL PROTECTED] On Behalf Of danj520
Sent: Wednesday, January 10, 2007 12:24 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: POST not working



Thanks for the reply...

As you can tell, I'm trying to write the results of my simple
form to
a file, can be any format, i.e., text, XML, etc. to preferably
an
email address or to a text file. What I'd like to see in the
file
would look like this

Name: John Smith
Address1: 234 Main St
Address2: Suite 100
City: Los Angeles
State: CA
Zip: 90028
Email: [EMAIL PROTECTED] mailto:jsmith%40company.com 

Is there a way to do this? Can't seem to find any info in the
Flex
docs...thanks again...

--- In flexcoders@yahoogroups.com
mailto:flexcoders%40yahoogroups.com , Tracy Spratt [EMAIL PROTECTED]
wrote:

 I don't think you can post to a .txt file. That would be way
too easy.
 I mean, you need some server-side program to accept the url
and write
 the file. Have you ever posted to a .txt file in any other
language?
 What are you expecting such a file to look like?
 
 
 
 Tracy
 
 
 
 
 
 From: flexcoders@yahoogroups.com
mailto:flexcoders%40yahoogroups.com
[mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
] On
 Behalf Of danj520
 Sent: Tuesday, January 09, 2007 3:34 PM
 To: flexcoders@yahoogroups.com
mailto:flexcoders%40yahoogroups.com 
 Subject: [flexcoders] POST not working
 
 
 
 Anyone know why this isn't working? When run, nothing is
posted..all
 form fields exist and are valid...thanks in advance...
 
 mx:HTTPService id=userRequest
 url=data/forms/contact.txt useProxy=false
 method=POST
 mx:request xmlns=
 username{nameInput.text}/username
 address1{address1.text}/address1
 address2{address2.text}/address2
 city{city.text}/city
 state{state.text}/state
 zip{zip.text}/zip
 country{country.text}/country
 emailaddress{emailInput.text}/emailaddress
 /mx:request
 /mx:HTTPService




 



RE: [flexcoders] Re: POST not working

2007-01-10 Thread Mike Weiland
You'll need logic on the server to handle the creation of the text file. So 
Flex takes the form input and POSTs it to your server page set up to handle it, 
something like a PHP, ASP, CFM, etc. This page on the server takes the input 
fields sent to it from Flex and formats it to your liking and writes out the 
file. So find out what middleware is on your server and go from there. I might 
suggest that you are going to want to store your information in a database 
though.

Good luck,

Mike Weiland

Original Message ---
Thanks for the reply...

As you can tell, I'm trying to write the results of my simple form to
a file, can be any format, i.e., text, XML, etc. to preferably an
email address or to a text file. What I'd like to see in the file
would look like this

Name: John Smith
Address1: 234 Main St
Address2: Suite 100
City: Los Angeles
State: CA
Zip: 90028
Email: [EMAIL PROTECTED]

Is there a way to do this? Can't seem to find any info in the Flex
docs...thanks again...


--- In flexcoders@yahoogroups.com, Tracy Spratt [EMAIL PROTECTED] wrote:

 I don't think you can post to a .txt file. That would be way too easy.
 I mean, you need some server-side program to accept the url and write
 the file.  Have you ever posted to a .txt file in any other language?
 What are you expecting such a file to look like?
 
  
 
 Tracy
 
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of danj520
 Sent: Tuesday, January 09, 2007 3:34 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] POST not working
 
  
 
 Anyone know why this isn't working? When run, nothing is posted..all
 form fields exist and are valid...thanks in advance...
 
 mx:HTTPService id=userRequest
 url=data/forms/contact.txt useProxy=false
 method=POST
 mx:request xmlns=
 username{nameInput.text}/username
 address1{address1.text}/address1
 address2{address2.text}/address2
 city{city.text}/city
 state{state.text}/state
 zip{zip.text}/zip
 country{country.text}/country
 emailaddress{emailInput.text}/emailaddress
 /mx:request
 /mx:HTTPService




RE: [flexcoders] Re: POST not working

2007-01-10 Thread Tracy Spratt
Here is an example that uses either ASP.NET or JSP to retrieve and save
a file.  It also is an xml editor, so there is more code than you need,
but you will see how the file manipulation is done pretty easily.

 

http://www.cflex.net/showfiledetails.cfm?ChannelID=1Object=FileobjectI
D=544

 

Tracy

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Mike Weiland
Sent: Wednesday, January 10, 2007 9:54 AM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] Re: POST not working

 

You'll need logic on the server to handle the creation of the text file.
So Flex takes the form input and POSTs it to your server page set up to
handle it, something like a PHP, ASP, CFM, etc. This page on the server
takes the input fields sent to it from Flex and formats it to your
liking and writes out the file. So find out what middleware is on your
server and go from there. I might suggest that you are going to want to
store your information in a database though.

Good luck,

Mike Weiland

Original Message ---
Thanks for the reply...

As you can tell, I'm trying to write the results of my simple form to
a file, can be any format, i.e., text, XML, etc. to preferably an
email address or to a text file. What I'd like to see in the file
would look like this

Name: John Smith
Address1: 234 Main St
Address2: Suite 100
City: Los Angeles
State: CA
Zip: 90028
Email: [EMAIL PROTECTED] mailto:jsmith%40company.com 

Is there a way to do this? Can't seem to find any info in the Flex
docs...thanks again...

--- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
, Tracy Spratt [EMAIL PROTECTED] wrote:

 I don't think you can post to a .txt file. That would be way too easy.
 I mean, you need some server-side program to accept the url and write
 the file. Have you ever posted to a .txt file in any other language?
 What are you expecting such a file to look like?
 
 
 
 Tracy
 
 
 
 
 
 From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
[mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
] On
 Behalf Of danj520
 Sent: Tuesday, January 09, 2007 3:34 PM
 To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com 
 Subject: [flexcoders] POST not working
 
 
 
 Anyone know why this isn't working? When run, nothing is posted..all
 form fields exist and are valid...thanks in advance...
 
 mx:HTTPService id=userRequest
 url=data/forms/contact.txt useProxy=false
 method=POST
 mx:request xmlns=
 username{nameInput.text}/username
 address1{address1.text}/address1
 address2{address2.text}/address2
 city{city.text}/city
 state{state.text}/state
 zip{zip.text}/zip
 country{country.text}/country
 emailaddress{emailInput.text}/emailaddress
 /mx:request
 /mx:HTTPService