# Import/Exporting

If you attend a family party, a company meeting, a conference, or any other event where other &kphotoalbum; users may be present, you may wish to share your images with those people. You may of course choose to generate &HTML; pages for them to browse, but given you already have spent time classifying all images (Who is on the images, where were they taken etc), there are no reason for them to redo all that work.

&kphotoalbum; allows you to export a set of your images into a `.kim` file, which other people may import into their database, to get your classification for these images.

Two different kind of `.kim` files exists, inlines or externals, referring to whether the images them self are located in the file or at some other location. Placing the images in the file has the obvious advantage that the file is self contained, while it has the equally obvious disadvantage of the file being rather big.

There are two places from which you may generate a `.kim` file, namely directly from File Export..., or along with &HTML; pages (see chp-generating-html). Creating a `.kim` file during &HTML; export will create an external `.kim` file.

External `.kim` files will search for images in one of two ways. First it will try to look for the images next to the `.kim` file, and if not found, it will search for them at the URL specified when the `.kim` file was created. Notice the later is only possible for `.kim` files created during &HTML; export.

## Export Dialog

This section will tell you about the export dialog which you get to from File Export....

The most important part of this dialog is specifying whether the `.kim` file should be internal or external (see description above). You have the following three options:

- Include in `.kim` file - this will be an internal file

- Manual copy next to .kim file - Here you must copy the images yourself next to the .kim file

- Automatically copy next to .kim file - here &kphotoalbum; will copy the images for you.

Between you and me, `.kim` files are really just zip files. Normally it is not worth bothering compressing the files because images normally are compressed JPEG already, and the XML file itself are really tiny. If you really want to squish out the last few bytes, you may still do so, by checking Compress Export File

The final option on the page are Limit maximum image dimension. When sending some images to some friends, you may not want to send images in full size, as the `.kim` file might be huge. For this, you may specify that the maximum dimension of images should be say maximum 800 pixels in each direction.

## Import Dialog

When you select a `.kim` file from a web browser, or choose File Import..., &kphotoalbum; will import the database exported with the functionality described in chp-importExport.

The import wizard consist of four steps. First you must specify which images you want to import. Next you must specify in which directory to put the imported images.

Chances are that you call the people category personen (if you are German), while I in Danish might call this category personer. In the third step of the import dialog, you must specify which category from the import file to import, plus which categories in your database they match.

I might call myself in my databases for me, while in your database I'm called Jesper K. Pedersen. Step four let you set up matching for each of the imported categories. This can be see in fig-import-dialog.

### Matching People in the Import Dialog

In the screen shot you may see that Donna is the same in both the .kim file and in my database - the name is shown in black to indicate a perfect match in the database. The other three names was not found in the database, though both Jesper and Anne Helene was found matching as substring, so these are suggested. Finally in my database I didn't have Spiff (or I might have named it quite differently), so &kphotoalbum; simply suggest Spiff for the import name.