User Profile

Collapse

Profile Sidebar

Collapse
svenni
svenni
Last Activity: Mar 14 '08, 01:39 PM
Joined: Jan 22 '08
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • svenni
    replied to Get folder name
    in PHP
    I think listing all the files in a database might be a good idea, but it depends on the amount of files. It shouldn't be a big problem for PHP to loop through lets say 100 files and return the ones which match your criteria, but if you have more than 1000 files I guess it would be best to use the indexing features in MySQL to search faster. The problem would though be the fact that the database needs to be updated once in a while, and I'm not quite...
    See more | Go to post

    Leave a comment:


  • svenni
    replied to Get folder name
    in PHP
    scandir is PHP5, so to do the same in PHP4 you would need a different approach, which means a couple more lines of code.

    I've done this some time ago, but I couldn't find my own code at the moment, so I found a similar code here :
    [PHP]
    <?php
    // declare the folder
    $ourDir = "/home/public_html/folderName";

    // prepare to read directory contents
    $ourDirList = @opendir($ourDi r);...
    See more | Go to post

    Leave a comment:


  • svenni
    replied to Traversing through $_FILES array
    in PHP
    Yup. MarkoKlacar is correct. I think you should write something like this instead:

    [PHP]
    foreach ($_FILES as $_key => $_value)
    {
    echo $_FILES[$_key]['name'] . " was uploaded successfully.<b r />";
    echo $_FILES[$_key]['name'] . " is in " . $_FILES[$_key]['type'] . " format<br />";
    }
    [/PHP]
    I'm not quite sure if it will work since I...
    See more | Go to post

    Leave a comment:


  • Saving a new version of your C++ solution in Visual Studio

    I've come to the point in the creation of one of my applications where I've decided it's about time to give it a fresh version number. Then I realized that I've never been in this situation before, and thought I should ask before I move on.

    What's the best way to save different versions of an application in Visual Studio? Should I copy the whole solution to a new folder and name it with the new version number? Or is there any built...
    See more | Go to post
No activity results to display
Show More
Working...