Open dirkroorda opened 3 years ago
Thank you for your feedback.
Indeed, it would be a good idea to be able to pass a path to a HTML template for the content. It might contain references to some of the fields that come from the Flickr API, like the image URL, the title, description or datetaken. I will transform the gearth
and mymaps
format into templates to use as sample (essentially, those names will be shorthands for predefined templates) and you could use them as a starting point for defining your own format then pass it to the --template
argument like you propose.
I will try to do it this week. It should not take too much development.
I have made a new release (version 4). You can upgrade with:
pip install flickr2kml --upgrade
I have added 2 samples that may fit what you want. They can be downloaded from the sample
folder: https://github.com/gvellut/flickr2kml/tree/master/sample
If they don't fit, you can modify them or ask me. They use the Jinja2 syntax so it may not be super user-friendly but it should probably be enough to do what you want.
This is what they look like in Google Earth:
To run flickr2kml
with those templates, you can download them and use the following command:
flickr2kml -f <album URL> -a SIZE=350 -t <path to>/description_alternate.html -n <path to>/name_datetaken.txt album_photos.kml
Great, I will try it out as soon as I can, probably this week.
Thanks for this nice piece of work. It worked really well. I used it to generate a KML out of 450 historical photos of my village. But I would like to get more information next to the photo. Now only the title ends up below the photo. What I would like is the description below the photo. Another thing: the name element of a placemark is not used. I would like to fill it with the date taken. I think I can modify your code to make this. Probably I will make it so that you can write your own template, put it in a file, and pass it on the commandline like
--template ttt.xml
. What do you think?