Normally php includes are not parsed within a page with a .html extension. You will need to add the following lines of code to your .htaccess file in order to tell your server to have it parse .html pages as php:
If anyone wants to only show the latest x-images from a specific collection instead of the whole gallery just change this: $q = "SELECT * from plogger_pictures order by `id` DESC LIMIT $amount"; with: $q = "SELECT * from plogger_pictures WHERE `parent_collection` = 2 order by `id` DESC LIMIT $amount"; and change the `parent_collection` = X to match the number of the collection you want the pictures to be displayed from.