This control allows someone to include a photo album browser on their website with the minimum of fuss.Image filters can be plugged in to enhance images during album generation, adding watermarking, logos etc. It is implemented as a web control that can be sited within a parent ASP.NET page. It automatically generates a treeview of navigable albums, the album pages themselves and all the navigation elements. To see a live running example go to Background New albums can be uploaded by just uploading a directory containing the source images to a specific folder on the server. Previous to writing this web control I was using JAlbum to create static HTML pages for all the photos that I wanted to host on my website. Eventually the number of photos I was putting online was becoming unmanageable and I was finding it a chore to write the HMTL to link all of the albums together. I therefore decided to write an application that allowed me to simply upload the photos to the server and get ASP.NET to do the hard work of producing the pages. My first attempt worked but was a bit clunky due to me not knowing ASP.NET particularly well. What is presented here is my second version which I think is much improved. The control will render the album treeview, which is based on the file structure under a specified ‘photos’ directory. As the user navigates around the photos, the web control produces thumbnail pages for each album. This can be navigated through via the usual forward and back buttons. The code is comprised of three Visual Studio 2003 projects The user can examine photos in greater detail by clicking on each thumbnail, at which point they are also able to add comments. The PhotoBrowser project is an ASP.NET web application that contains the control that renders the HTML.The PhotoBrowserLibrary class project that encapsulates the photo directory file structure.And the squishyTREE project which contains the treeview control that is used to display the album list.Note that this project is copy of the one released by In order to use the photo browser in your web application you'll need to SquishyWARE, modified by adding a parent property to the TreeNode class. Import the PhotoBrowser.ascx file and the PhotoBrowserRes directory.PhotoBrowser.ascx is the web control itself and the PhotoBrowserRes directory contains the images it requires. Add a reference to the PhotoBrowserLibrary DLL and the squishyTREE DLL.Add the following line to you page, just before the closing tag.Then simply drag the web control on to your. The treeview is implemented using the excellent squishyTREE control from. I used some code from here to help me sort out getting the date the photo was taken from the embedded EXIF data (apologies if this is the wrong link but I can’t honestly remember where it came from).Īpplication currently only detects changes in the photos contained within aĭirectory when the number stored in the database and the number on the file The comment popups were implemented using the excellent overLib. Like to make this cleverer so that it can detect when an image has been #JALBUM IMPORT PAGES FROM ANOTHER ALBUM CODE# Hyperlink to externally link to a single album (although you can use a link for individual photos).
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |