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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T16:53:38+00:00 2026-06-12T16:53:38+00:00

I am using JavaScript with FileReader and readAsDataURL so I can convert images to

  • 0

I am using JavaScript with FileReader and readAsDataURL so I can convert images to base64 code and then store and display the base64 image code at a later time. I have a button that works fine when I select a file with it, but my question is: How can I use only a url to a local file (something like C:\folder\image.gif) (without using the file input button) and create an image object from that local image file url to use with the FileReader readAsDataURL functions? If this is not possible with FileReader, is there another way to automatically convert a local file to base64 code within the script?

  • 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-06-12T16:53:39+00:00Added an answer on June 12, 2026 at 4:53 pm

    You can’t. Allowing a web site to open arbitrary local files would be a serious, serious security concern. There would be nothing to prevent things like grabbing password files or other sensitive information without the user knowing. There have also been strict restrictions on the file input for that reason and to clearly communicate the intent.

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

Sidebar

Related Questions

Using javascript, How can I convert a human time string like Wed Jun 20
Using JavaScript, how can I determine the size of an image which is not
Using javascript, how can we auto insert the current DATE and TIME into a
I'm using javascript FileReader class to preview the image prior to uploading it to
Using JavaScript, how do I create an HTML table that can "accept" numeric matrix
I have been successfully using my code with the javascript library in the ANTLR
Using Javascript I would like to show a working/loading image once a user hits
Using Javascript or jQuery, how can I check if an external link is available?
Using Javascript, how can I access a specific child of a row? Javascript (not
Using JavaScript, how can i open a new window (loading, say, http://www.google.com in the

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.