Create a photoblog on Drupal 6

    Why is it still Drupal? - Initially, I opted for Wordpress, since the multi-user CMS does not interest me, I decided to try Wordpress. It was in 2008. But at that moment (maybe something has changed now) I could not find a single module or several modules that would satisfy the following simple requirements (in order of importance):
    1. grouping photos by albums, with the ability to add a description to the album
    2. upload multiple photos to an album with a minimum number of clicks
    3. grouping albums into categories
    4. showing albums in the form of topics with a description and preview of several photos on the main page
    5. direct link to any album
    6. comments of visitors for an album and a separate photo (with moderation)
    7. control of the size of the given format

    But with Drupal we managed to implement all this, and this is the topic.



    At first I settled on the Brilliant Gallery module , which is still used for old albums. The module allows you to display all photos located in a specific folder on the server in the body of the note. The module allows you to sort the picture alphabetically or in random order. It is possible to cache images using Drupal. In addition, you can control the size of the icons and full-size images, the choice of Ajax plug-in for viewing.
    The note itself consists of a small line with data for the module:
    [bg | girls / bonya ||||| black || no]

    As you can see, the options are formed for each album separately and when changing the theme, changing the background color will not be so easy, you need to edit each album individually.
    Other module disadvantages:
    • no web interface for creating the corresponding folder, uploading photos to it
    • impossible to comment on a single photo
    • the inability to sort photos by popularity

    As you can see, the module does not solve all the tasks.

    Continued the search, and installed Image , which allows you to upload individual photos to the appropriate categories (one picture can belong to several categories). But he does not know how to group photos into albums. A useful feature was the appearance of the "random picture" block. I note that for anonymous, the picture is the same all the time, if you enable block caching. If you enable only page caching, the picture will be the same for when updating the same page, but different for different pages.
    This module also did not solve the tasks.

    And finally, I got to the most powerful album photos module , which can do everything necessary and other useful things.
    There was an opportunity to vote for each individual photo (like / dislike), but for this, a Voting API was needed , with which you can also organize polls of visitors.
    Module features:
    • Options for displaying images separately for the main and separately for the album itself
    • Adding an album to the site menu directly when creating
    • Album description can be in html format
    • Manage images directly from the album menu
    • Turn on / off comments for an individual album
    • The ability to put / not put the album on the main


    The problem is solved and you can go to the site improvements for yourself.

    For displaying full-size pictures from the main page and album pages, Lightbox2 was installed (in the album photos settings, you can select other ajax viewers)

    For comments, I installed Ajax and Ajax Comments DHTML Menu

    came in handy to simplify and speed up navigation. The most difficult task was to choose the interface theme. For a long time I used this nice and high-quality theme, editing CSS and Deco pictures a little. But photos look better on a black background (in my subjective opinion), so I recently switched to Decayed

    . The theme had problems with the menu and a large skull in the upper right corner. After a little editing of CSS and background themes, the problems were fixed.

    I took photos for one resource about the iPhone and received more than 3,000 visitors from there per day. The hoster began to complain about the high consumption of resources and at times disabled access to the site. I thought about caching and stopped on boost , since the main (almost all) traffic to the site is generated by anonymous users. The module is very powerful, but requires access to .htaccess - it is necessary that the hosting support this and cron, otherwise the cache will not be automatically cleared. If hosting does not support creating tasks for cron, then you can use a little trick - sitename / cron.php can be pulled from any server.

    UPD: the goal of the article is to show a possible solution to the problem with Drupal tools and discuss the pros / cons of the approach outlined with the habro-community, learn about other options for
    UPD2 solution : in the comments there are other interesting
    UPD3 solutions : You can see the result here bb.org.ua (topic Decayed) and here mike.pp.ua (the old version with the Deco theme, is hosted on the burned-up hosting.ua, but as you can see, they restored the shared hosting and everything works)

    Also popular now: