Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6038603
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T06:14:45+00:00 2026-05-23T06:14:45+00:00

Ive got an assignment to create an image gallery using flickr – this has

  • 0

Ive got an assignment to create an image gallery using flickr – this has to be done using keyword(s) entered by a user in a form, and the image gallery returned must be paginated and display a certain number of results per page. Each image in the gallery must also be a thumbnail.

Im graded based on how efficient, maintainable, consise and clear the code is..

Ive finished the assignment but i think it could be optimised alot better, these are the points that i might be lacking.

  • All my code is in a single file (the form and the gallery code) – should i separate this?
  • Im not using oo at all, is there someway i can make use of it here?
  • Im resizing the thumbnails using html length and width

thanks for any help

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T06:14:45+00:00Added an answer on May 23, 2026 at 6:14 am

    This question is really broad, and it seems like you want someone to write the code for you, which I won’t do but I’ll help point in the right direction.

    First, Flickr has an API, I would reccomend checking that out.

    http://www.flickr.com/services/api/

    You are going to need a library to make thumbnails, you can do that quickly with GD

    http://php.net/manual/en/book.image.php

    As far as separating the code, it probably wouldn’t be a bad idea. One file is great if its a few hundred lines, but if you have a lot going on, it doesnt hurt to separate files by their function (ex: scrape.php, resize.php etc.). That’s mostly personal preference. Since you’re being graded on maintainability and clarity I would suggest breaking it up.

    At the risk of starting a flamewar, I would suggest making it OOP. If you want it to be clear and readable this will help a lot. Break it into classes and functions and group them in a logical manner so someone knows if they need to change something they have a good idea where to start. Document it well and this will help also.

    My suggestion would be to create a class for each of these functions:

    • Grab images from Flickr
    • Store the metadata related to the images
    • Resize the images
    • Pull the information from the database
    • Display the pages.

    Try to keep the data functions separate from the presentation. Use a class to build your pages, and call another class to get the data. This is pretty general advise, but it’s something you’ll need to know when building future apps. This doesn’t necessarily need to be full MVC, but separation of these tasks will make the code make more sense.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Ruby has this very interesting functionality in which when you create a class with
ive got an assignment which requires me to set default language to a win
Ive got a question to Spring Security 3.0.5. When using Spring Security to secure
Hey all. Ive got a headache trying to get my head around this. I
I've got an assignment which requires me to update the northwind database, I've done
I've got a menu in Python. That part was easy. I'm using raw_input() to
I've got a group of inter-related classes that are all overridden together to create
I've got a JavaScript object, built this way: function foo() { this.length = 0;
I've got two entities, one called Site and the other called Assignment. A Site
We just got our first major Perl CGI assignment in my CS class. Our

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.