Hi,
i have a TEXTAREA which has a name value of "CodeData" as part of a form. When i press a submit button, the text in the textarea is passed along in the URL using GET, i.e. Form.php?CodeData=***
The problem is that the data i will be passing will be several hundred characters from a Java file which forms an URL which is far too big and can cause problems.
The processing instructions simply create a file based on the CodeData and other variables passed in the URL.
Are there any Variables which i could use to hold the value of CodeData instead of passing it in the URL, which can then be accessed by my processing script?
Thanks
Richard.
Saving Contents of TEXTAREA to File
Moderator: General Moderators
-
richardstan
- Forum Newbie
- Posts: 3
- Joined: Thu Oct 23, 2008 12:03 pm
- aceconcepts
- DevNet Resident
- Posts: 1424
- Joined: Mon Feb 06, 2006 11:26 am
- Location: London
Re: Saving Contents of TEXTAREA to File
Why don't you use POST?
Re: Saving Contents of TEXTAREA to File
What the guy above said, or if you want to you could write it to a .txt file..
-
richardstan
- Forum Newbie
- Posts: 3
- Joined: Thu Oct 23, 2008 12:03 pm
Re: Saving Contents of TEXTAREA to File
Hi,
I have tried using POST to transfer the information from the form to the Processing function, but it adds lots of backslashes to the text which i dont need. Is it possible to reference a PHP function from a HTML form so it runs when a the submit button is pressed?
Richard.
I have tried using POST to transfer the information from the form to the Processing function, but it adds lots of backslashes to the text which i dont need. Is it possible to reference a PHP function from a HTML form so it runs when a the submit button is pressed?
Richard.
- aceconcepts
- DevNet Resident
- Posts: 1424
- Joined: Mon Feb 06, 2006 11:26 am
- Location: London
Re: Saving Contents of TEXTAREA to File
PHP needs to somehow get the form data (POST or GET).
Try using POST to submit the data and use stripslashes() (http://uk3.php.net/stripslashes) to remove the slashes.
Try using POST to submit the data and use stripslashes() (http://uk3.php.net/stripslashes) to remove the slashes.