Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Page 1 of 2 1 2 LastLast
Results 1 to 10 of 12
  1. #1
    Junior Member
    Join Date
    Jul 2006
    Location
    Welwyn, England
    Posts
    6
    Member #
    13506
    Hi!
    Could someone please explain how image libraries work? I believe the images are linked to a database, a free search on that database is done via a search form and this pulls the images up. Is this best done with Access or MYSQL? I would like to create something fairly simple but am struggling a little with exactly how it is done.
    Thanks

    Brian A.

  2.  

  3. #2
    Senior Member
    Join Date
    May 2003
    Location
    UK
    Posts
    2,354
    Member #
    1326
    I am not sure what you mean by image library.

    However how you describe it sounds like you mean that the image filenames are stored in a database table.

    And these are then extracted and used to generate <img> code.

    What you would need to do is

    1: create a database and a table. That table should have a field for the image filename, and an id field. Also maybe a field for when a row was added, of type timestamp.

    Then you would need a technology such as PHP or ASP to extract the values from the database table, and output the result.

  4. #3
    Junior Member
    Join Date
    Jul 2006
    Location
    Welwyn, England
    Posts
    6
    Member #
    13506
    Thanks for that! Sorry for the confusion - I mean an on-line stock image library where the interested party can type in a keyword and it comes up with the images requested eg type in London and all the images of London come up.
    Is it best to create the table in MYSQL or Access?
    If you want to do a free search on the database - and had fields labelled ID, type, country, location, description and a field for the image - what you put into the "query" to search on these fields but just display the image?
    Thanks & Regds

  5. #4
    Senior Member
    Join Date
    May 2003
    Location
    UK
    Posts
    2,354
    Member #
    1326
    I would say MySQL.

    And in this type of situation, you are searching against a column, either the description, or the image filename.

    The description would be better.

    Do you know any server side languages?

    You would need to create a HTML form that sends the description they are seeking, get that value (set a variable to it) and your query would be something like

    Code:
    select img_filename from table where description LIKE '%what-they-entered%'
    ^ That meaning if what they entered is in the description column that filename would be extracted.

    Until we know what language you plan to use we cannot really help further.

  6. #5
    Junior Member
    Join Date
    Jul 2006
    Location
    Welwyn, England
    Posts
    6
    Member #
    13506
    I can create a form in Dreamweaver and I guess PHP is the companion to MYSQL.
    Where you type '%what-they-entered%' - is that what you actually put in the query such that if say Ireland was typed into the form the '%what-they-entered%' would understand that?
    select img_filename from table - presumably the table would have to be defined eg IMAGE DATABASE?

    Regds

  7. #6
    Senior Member filburt1's Avatar
    Join Date
    Jul 2002
    Location
    Maryland, US
    Posts
    11,774
    Member #
    3
    Liked
    21 times
    It's more likely that searches are made against metadata rather than the actual filename. For example, each image would have a user-defined group of keywords and the search engine matches against that.
    filburt1, Web Design Forums.net founder
    Site of the Month contest: submit your site or vote for the winner!

  8. #7
    Junior Member
    Join Date
    Jul 2006
    Location
    Welwyn, England
    Posts
    6
    Member #
    13506
    If I am going to use Photoshop CS - how to I attach keywords to the thumbnail or is it done via a second database?

  9. #8
    Senior Member
    Join Date
    May 2003
    Location
    UK
    Posts
    2,354
    Member #
    1326
    You would have a field for the image filename and a field full of keywords.

    Your PHP code would look something like

    PHP Code:

    <?php

    if($_POST['submit'])
    {
      
    // connect to db here
      
    $search $_POST['search'];
      
    $query "SELECT * FROM table_name WHERE description = '%$search%'";
      
    $result mysql_query($query) or die("error in select - " mysql_error();
    }
    Assuming the column names and table names match.

  10. #9
    Junior Member
    Join Date
    Jul 2006
    Location
    Welwyn, England
    Posts
    6
    Member #
    13506
    Thanks! Think the light is gradually beginning to dawn ...
    Just went into photoshop and found that going into "file info" allows you to attach keywords to an image - now I guess if the search works on the database field in which the path to the image is stored and you search on that field it will pick up the keywords and display the image.

  11. #10
    Senior Member
    Join Date
    Jun 2005
    Location
    Atlanta, GA
    Posts
    4,146
    Member #
    10263
    Liked
    1 times
    Don't confuse Photoshop's keywords with the ones that you have to store in the database. The keywords in Photoshop are stored directly in the image, and thus difficult to access (and slow). Keywords stored in a database, on the other hand, are stored in the database and are searched very very quickly. They're separate, and you won't be associating keywords in the database through Photoshop; you'll have to do it some other way.


Page 1 of 2 1 2 LastLast

Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 02:49 PM.
Powered by vBulletin® Version 4.2.3
Copyright © 2019 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com