Sorry for the poor subject line. My brain is fried from trying to find an answer to my problem and I just couldnt think of a short way of putting this.
Basically, I am attempting to write code that a download manager can understand, so to speak. My links on my site are as such...
I have never had a need for one so all I can do is point you to google. I looked at the one by "Chipmunks". Seemed ok, but I am no expert on topsites.
http://www.google.com/search?hl=en&q=free+php+scripts+topsites
IamStang
Assuming the username is being passed by a field named "username" in a submitted form:
<?php
$username = $_POST['username'];
$path = "/var/www/html/userz/".$username."/";
if(isset($username)){
echo "The path to the directory is ".$path; }
?>
<FORM METHOD="POST" ACTION="test.php">
<input...
Have a look at this page of the manual. Specifically the part on "getcwd". If your still having trouble after reading that, let us know. Someone will help ya out.
The Page:
http://www.phpbuilder.com/manual/ref.dir.php
Later!
IamStang
If I am understanding you correctly, this is what I would do. As was stated above by kenrbnsn, using a text box and letting the individual decide what to insert is a bad idea (IMHO).
I would use an option pulldown. Use something like this near the begining of your script.
$domain =...
I have a problem that I hope someone can help me out with. I need to write a variable like the one below to a file. Currently, I am trying to do this similar to as shown below, to no avail:
$dirPath = "C:\script_pages\myPHPscript\";
$userName = "Bob"; //Could be anything.
$EmpHTMLFile =...
For crying out loud! Why didnt it occur to me to use a foreach statement? After all, I just got through coding another part of my script using it. LOL
Thanks DRJ478 for hooking the truck up and pulling my head out.
Thanks for the reply.
The file I am working with should never be more than 20 or so lines, so I dont believe size will be an issue.
And, as it always seems to work out, I have found information, just a few minutes ago, regarding this. It never fails. I spend days trying to figure it out on my...
I know it is possible but I am finding very little information pertaining to my question.
Everything tells one how to read/write/append to a txt file. I dont know, maybe I am just not looking in the right places.
What I am trying to accomplish is this: I have a txt file. It is formatted...
I have a problem with a cgi script not being allowed to create/write to a txt file.
The Scenario:
A Linux/Apache server with SeLinux disabled (temporarily)
A cgi script that creates a new txt file containing info submitted by a visitor (ipaddy_data.txt)
When I load the cgi in my browser, I get...
mobajwa
Before you install awstats, do a google for information concerning a hack/bacdoor that uses awstats. I have noticed several entries in my error logs reporting people trying to exploit this on my server. I do not use awstats, so no worries for me...
Hello all,
I figured out what the problem is. The error "Can't open perl script "\r": no such file or directory" is telling me that the script I am trying to load has carriage returns in it. This is caused by the fact that the script was composed on a windows machine. I re-wrote the file using...
OK, before I just give up and go back to a WinBlows system, I am going to, once again, ask you folks for help.
After a clean install of Fedora 3, what in the world do I need to do to get CGI to work?
I have tried several different things mentioned in other threads on this forum and others...
Thank you folks very much!
I have posted, what some would consider, "lamer questions" on other boards and have been treated as such. This board seems to be the place to get help regardless of one's cgi coding experience.
I learn internet related coding on my own and will be sure to frequent...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.