Stupid question of the day (Editing text file in $HOME via web)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I have a text file on a server that I want someone to be able to edit via the web. I need it to have some modicum of security, but it's nothing particularly important and security is not the main concern. I am perfectly willing to simply http-auth it, if need be.

But it need to be easily editable using some sort of simple web form.

The file is unlikely to be much more than 20-100 lines of simple text, but there are a couple of things that are important.

1) it has to preserve spacing and 'extended' characters
2) it has to be kept readable to the uid of the directory it is in, and not just the webserver, however it can't be world readable without some authentication via the web. 3) the file is in $HOME and not in DocumentRoot, though it _could_ be moved.

I don't want to install some fancy word-processing sort of engine just to give a user access to this file, nor does the file need to be html-ized or anything. It is a very simple file:

(AAA) XXX-NNN, some descriptive text
(AAA) XXX-NNN, some other descriptive text
(AAA) XXX-NNN, some different descriptive text
(AAA) XXX-NNN, John Smith

etc.

So, do I whack up something where I just load the file into a HTML Textarea and then write it back (simple enough, though possibly rather dangerous), or is there something straightforward I should go ahead and use that might find use elsewhere on the server?

--
"Oh damn", said Maladict.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux