Jump to content

kamranki

New Members
  • Posts

    5
  • Joined

  • Last visited

    Never

Posts posted by kamranki

  1. Hello all,

     

    It's been while since I have written something here! One more thing; my knowledge about PHP is almost zero. Though I can understand syntax somewhat if explained.

     

    OK, I have my own photography site (http://kamranki.com:1300/images/photography/index.html) here. I want visitors to be able to leave their comments on photos page (something like comments on blog articles). My webserver setup is as follows:

     

    - Windows XP Professional SP3

    - Abyss Web Server

    - PHP 5.2 for Windows

     

    Since port 80 is blocked by my ISP, I have to resort to using port 1300.

     

    Photo thumbnails link to separate HTML files:

    index01.html

    index02.html

    index03.html

    index04.html

    .

    .

    .

    and so on

     

    Since I'm looking for a simple setup, I don't mind having comments stored in a text file (I think that setting up a database could complicate things so not really interested in going that way). The text file could be a common text file for all photos (with sections dividing comments for each photo) or a separate text file for each photo.

     

    Something like:

     

    index01.html >> index01.txt

    index02.html >> index02.txt

    index03.html >> index03.txt

    index04.html >> index04.txt

    .

    .

    .

    and so on

     

     

    Managing comments from a separate console or panel is not really a priority as I can always edit the text file(s) by hand. I could look into that later.

     

    Any pinpointers would be really appreciated. Thanks a bunch!

  2. Here's what I was able to manage; a simple listing of contents of c:\temp on the PC. But how can I make these files downloadable? I tried looking at some other sample scripts from around the web but was unable to get anything working.  :-[

    Following are the contents of download.php:

    [hr]
    [font=Courier]
    <font face="Tahoma" size="2" color="black">

    <?php

    if ($handle = opendir('c:\\temp'))
    {
    while (false !== ($file = readdir($handle)))
    {
    if ($file != "." && $file != "..")
    {
    echo "$file <br>";


    }
    }
    }
    ?>
    [/font]

    [hr]

    It can be accessed at:

    [url=http://www.kamranki.com:1300/download/files/download.php]http://www.kamranki.com:1300/download/files/download.php[/url]
  3. Hello everyone,

    Since I'm a complete beginner, please excuse any errors or mistakes. I don't have any scripting experience to speak of but I mostly manage by copy and pasting. In most conditions, I am able to understand the syntax.

    I have set up a simple webserver for uploading files. It can be accessed at:

    [url=http://www.kamranki.com:1300/upload/user/upload.php]http://www.kamranki.com:1300/upload/user/upload.php[/url]

    The webserver machine uses the following:

    - Windows XP Professional SP2
    - Abyss Web Server X1
    - PHP

    I would like to list local folders and their contents on the webpage so that I can access my files from anywhere. I already have an FTP server running but I would also like to access my files through HTTP. I don't need a complex setup but rather a very simple listing of files from a specific folder on the hard drive. I should be able to download the file by clicking on it's name.

    I would like to know if there's a function for listing files from local folders. Any examples will do just fine. Any help would be greatly appreciated.

    Thanks and regards,
    Kamran
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.