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 4043694
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T13:09:34+00:00 2026-05-20T13:09:34+00:00

Image Thumbnails and Etc. Connection to database for the filename and details The table

  • 0

Image Thumbnails and Etc.

Connection to database for the filename and details
The table contains all the real file information. Mimetype, extensions and etc.

The physical images are located on a hdd in a folder path and are renamed as follow:
s:\onlinemedia\files\1\2241.dat

[Type pjpeg]
[Mime image/jpeg]

I can get all of that information however, when I set header to image/jpg I get the output of my string to the path.

s:\onlinemedia\files\1\2241.dat

$fileid = $passcode = '';
$fileid     = (isset($_GET['fileid']) ? $_GET['fileid'] : '');
$passcode   = (isset($_GET['passcode']) ? $_GET['passcode'] :'');
$filename = $frw->source->img($fileid,$passcode);
$thumb = PhpThumbFactory::create($filename);
$thumb->adaptiveResize(16,16);
$thumb->save($filename);
$thumb->show($filename);

What is really happening here?

  • 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-20T13:09:34+00:00Added an answer on May 20, 2026 at 1:09 pm

    One thing I see in the posted code is this:

    $thumb = PhpThumbFactory::create($filename);
    $thumb->adaptiveResize(16,16);
    $thumb->save($filename);
    $thumb->show($filename);
    

    When doing $thumb-save(); you need to pass the path to a new file to save it as. How you have it now will overwrite the original if you actually want to do that. Also, $thumb->show(); shouldn’t need a parameter, it goes off the path parameter you used to create the object to begin with. I’m also not sure if you need to mess with the headers using PhpThumbFactory, as the show() method handles that I think.

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

Sidebar

Related Questions

How do I generate circular image thumbnails using PIL? The space outside the circle
I have a form with image thumbnails to select with checkboxes for downloading. I
I will work on a search box with inspiration from Facebook where image thumbnails
Imagine you have a classifieds website... When searching ads you want image thumbnails of
I have an image uploader and cropper which creates thumbnails and I occasionally get
I am wondering if including image thumbnail information in the model makes sense. Like
I have 2 large XML files: Car data (id, name, image, etc). Deals (car_id,
Calling image = Image.open(data) image.thumbnail((36,36), Image.NEAREST) will maintain the aspect ratio. But I need
I have a thumbnail image inside a div. I use another image as the
I want to display a thumbnail image in a cell of tableViewController , this

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.