Google Answers Logo
View Question
 
Q: form script ( No Answer,   0 Comments )
Question  
Subject: form script
Category: Computers > Programming
Asked by: rayzuntheterrible-ga
List Price: $10.00
Posted: 02 Mar 2004 22:15 PST
Expires: 01 Apr 2004 22:15 PST
Question ID: 312859
Im looking for an script that will take an form input text field...,
to create an folder on my server with that entered text, copy the
contents of an seperate folder to that new folder, and set chmod 777
to several text files located in the new folder.

Searching around I found script that can copy folders from one server
to another, but renaming, and setting chmod is something also needed.

Request for Question Clarification by majortom-ga on 03 Mar 2004 08:18 PST
I would be happy to tackle this for you but I need to understand
exactly what you want, and what programming language you will accept
for the answer.

First, as to what you want, this page should:

1. Accept a text input field;

2. Create a folder with the name the user enters in that field, within
a special parent folder for this purpose I assume, without allowing
the user to hack the system by entering ../ or similar paths that
would access the rest of the file system;

3. Copy the contents of a separate folder (what separate folder?
Specified how? By the user? Or always the same one, hard-coded in the
script?) into this new folder;

4. Set "chmod 777" on all files copied to the new folder.

Second, as to what you will accept, you haven't specified whether you
require a specific programming language to be used. I could do this
job for $10 as a Perl CGI program, because I can work quickly in that
language.

Thank you for the clarification!

Clarification of Question by rayzuntheterrible-ga on 03 Mar 2004 17:45 PST
Perl CGI program is fine and would be accepted
wow if you can complete the scriptplus to do the following:

points you mentioned 
1. - yes
2. - yes
3. always the same one, hard-coded in the script.
example: http://domain.com/text-field-input-here/
4. chmod 777 to all text files in one specific folder.
example: http://domain.com/text-field-input-here/update/text/
---done----
Although not mentioned in original post, I need to request actions. 
I would have added this in the initial question however, describing it
did not make much sense to me. My perl knowledge is limited to posting
to an .txt file and retrieving.
And I will surely repost my question adding 10 to the list price.
So here it goes...

The text field entered from the form, I would like it place inside an
cookie (php),
this cookie script is in the html of index.php file of the new folder.
example:
http://domain.com/text-field-input-here/index.php
the cookie...
<?php
   // This cookie expire at midnight, May 15, 2007
   setcookie( "testcookie", "text-field-input-here", mktime(0, 0, 0,
5, 15, 2007) );
 setcookie( "testcookie-email", "text-field-input-here@domain.com",
mktime(0, 0, 0, 5, 15, 2007) );
?>

placing cookie...
<?php
echo "$HTTP_COOKIE_VARS[testcookie]";
echo "$HTTP_COOKIE_VARS[testcookie-email]";
?>

###
note
The text field.
I have an ecommerce website, and my customer does initially name this new folder.
The name is input as an product option before adding item to the shopping cart.
Our shopping cart is made in cgi.
example:
shop/USA/cart.cgi
shop/USA/cartconfig.cgi
Is it at all possible to start here?
Answer  
There is no answer at this time.

Comments  
There are no comments at this time.

Important Disclaimer: Answers and comments provided on Google Answers are general information, and are not intended to substitute for informed professional medical, psychiatric, psychological, tax, legal, investment, accounting, or other professional advice. Google does not endorse, and expressly disclaims liability for any product, manufacturer, distributor, service or service provider mentioned or any opinion expressed in answers or comments. Please read carefully the Google Answers Terms of Service.

If you feel that you have found inappropriate content, please let us know by emailing us at answers-support@google.com with the question ID listed above. Thank you.
Search Google Answers for
Google Answers  


Google Home - Answers FAQ - Terms of Service - Privacy Policy