How do I display a file c:\MYDIR\A.jpg ?

Discussion in 'HTML' started by PHPBABY3, May 3, 2008.

  1. PHPBABY3

    PHPBABY3 Guest

    How do I display a file c:\MYDIR\A.jpg ?

    These don't work:

    <img src="c:\MYDIR\A.jpg">

    <img src="c:/MYDIR/A.jpg">

    <img src="c:MYDIR\A.jpg">

    <img src="c:MYDIR/A.jpg">


    P -
    PHPBABY3, May 3, 2008
    #1
    1. Advertising

  2. PHPBABY3

    PHPBABY3 Guest

    On May 3, 5:12 pm, SAZ <> wrote:
    > In article <2d4f9806-ee3d-46d3-9fb9-6a4316dcc933
    > @m45g2000hsb.googlegroups.com>, says...
    >
    > > How do I display a file c:\MYDIR\A.jpg ?

    >
    > > These don't work:

    >
    > > <img src="c:\MYDIR\A.jpg">

    >
    > > <img src="c:/MYDIR/A.jpg">

    >
    > > <img src="c:MYDIR\A.jpg">

    >
    > > <img src="c:MYDIR/A.jpg">

    >
    > > P -

    >
    > Do you mean you are trying to build a web page, post it, and grab an
    > image from your personal computer to display on the site?  If so, you
    > must upload the image to the site and correct the path to the image.


    The user identifies a bunch of JPG files on their computer. My
    program takes them and displays them all on one page. How?
    PHPBABY3, May 3, 2008
    #2
    1. Advertising

  3. PHPBABY3 wrote:
    > On May 3, 5:12 pm, SAZ <> wrote:
    >> In article <2d4f9806-ee3d-46d3-9fb9-6a4316dcc933
    >> @m45g2000hsb.googlegroups.com>, says...
    >>
    >>> How do I display a file c:\MYDIR\A.jpg ?
    >>> These don't work:
    >>> <img src="c:\MYDIR\A.jpg">
    >>> <img src="c:/MYDIR/A.jpg">
    >>> <img src="c:MYDIR\A.jpg">
    >>> <img src="c:MYDIR/A.jpg">
    >>> P -

    >> Do you mean you are trying to build a web page, post it, and grab an
    >> image from your personal computer to display on the site? If so, you
    >> must upload the image to the site and correct the path to the image.

    >
    > The user identifies a bunch of JPG files on their computer. My
    > program takes them and displays them all on one page. How?


    If the webpage is in "c:\MYDIR" then just put <img src="A.jpg"... else
    you have to use relative paths, remember for webpage path separators are "/"

    so for:

    HTMLfolder
    HTMLfolder/IMGfolder

    <img src="IMGfolder/A.jpg">

    or for

    SomeFolder/HTMLfolder
    SomeFolder/IMGfolder

    <img src="../IMGfolder/A.jpg">

    --
    Take care,

    Jonathan
    -------------------
    LITTLE WORKS STUDIO
    http://www.LittleWorksStudio.com
    Jonathan N. Little, May 3, 2008
    #3
  4. Gazing into my crystal ball I observed PHPBABY3 <>
    writing in news:a40690e3-8920-43af-82b9-
    :

    >>
    >> Do you mean you are trying to build a web page, post it, and grab an
    >> image from your personal computer to display on the site? ÿIf so, you
    >> must upload the image to the site and correct the path to the image.

    >
    > The user identifies a bunch of JPG files on their computer. My
    > program takes them and displays them all on one page. How?
    >


    You will have to use some kind of upload script on your page to get the
    images and save them to your server. If you are thinking of putting the
    images into a database, I would highly recommend you do not do so --
    only store the path to the image in the db.

    Once you have the images on your server, simply use the path to the
    images on your server.

    --
    Adrienne Boswell at Home
    Arbpen Web Site Design Services
    http://www.cavalcade-of-coding.info
    Please respond to the group so others can share
    Adrienne Boswell, May 4, 2008
    #4
  5. PHPBABY3

    Guest


    > The user identifies a bunch of JPG files on their computer.  My
    > program takes them and displays them all on one page.  How?


    So come on - if you can write a program like ICQ personal Web server
    you should know what to do.

    Jan
    , May 4, 2008
    #5
  6. PHPBABY3

    PHPBABY3 Guest

    On May 4, 4:22 pm, wrote:
    > > The user identifies a bunch of JPG files on their computer.  My
    > > program takes them and displays them all on one page.  How?

    >
    > So come on - if you can write a program like ICQ personal Web server
    > you should know what to do.
    >
    > Jan


    Ok for the lesson in logic. Now how do I do what I want to do?

    P -
    PHPBABY3, May 4, 2008
    #6
  7. frank wrote:
    > On Sat, 03 May 2008 14:04:41 -0700, PHPBABY3 wrote:
    >
    >> How do I display a file c:\MYDIR\A.jpg ?
    >>
    >> These don't work:
    >>
    >> <img src="c:\MYDIR\A.jpg">
    >>
    >> <img src="c:/MYDIR/A.jpg">
    >>
    >> <img src="c:MYDIR\A.jpg">
    >>
    >> <img src="c:MYDIR/A.jpg">
    >>
    >>
    >> P -

    >
    > decided to write it up.
    > ..................
    > <html>
    > <head><title>The Window</title>
    > <script type='text/javascript' language='javascript'>
    > var newwindow;
    > function poptastic(url)
    > {
    > newwindow=window.open(url,'name','height=400,width=200');
    > if (window.focus) {newwindow.focus()}
    > }
    > </script>
    > </head>
    > <body>
    > This links to a window<p>
    > <a href="javascript:poptastic('c:/myFile/whatever.html');">the literal</a>


    Don't expect that to work in Firefox. The above is bad in so many ways...

    To OP is is unclear of what you wish. Is this an HTML page on a local
    system to display images also on the local system or are your trying to
    display images from a local system in a web page online?

    --
    Take care,

    Jonathan
    -------------------
    LITTLE WORKS STUDIO
    http://www.LittleWorksStudio.com
    Jonathan N. Little, May 5, 2008
    #7
  8. SAZ wrote:

    > But still, the OP has not yet answered the first question:
    >
    > Do you mean you are trying to build a web page, post it, and grab an
    > image from your personal computer to display on the site?


    Been asking too. Not sure OP knows at all what (s)he is doing. Trying to
    guess is just a waste of time.

    --
    Take care,

    Jonathan
    -------------------
    LITTLE WORKS STUDIO
    http://www.LittleWorksStudio.com
    Jonathan N. Little, May 5, 2008
    #8
  9. PHPBABY3

    richard Guest

    On Sun, 04 May 2008 18:54:51 -0500, frank <>
    wrote:

    >On Sat, 03 May 2008 14:04:41 -0700, PHPBABY3 wrote:
    >
    >> How do I display a file c:\MYDIR\A.jpg ?
    >>
    >> These don't work:
    >>
    >> <img src="c:\MYDIR\A.jpg">
    >>
    >> <img src="c:/MYDIR/A.jpg">
    >>
    >> <img src="c:MYDIR\A.jpg">
    >>
    >> <img src="c:MYDIR/A.jpg">
    >>
    >>
    >> P -

    >
    >I think what you really want is a link to a javascript that generates a
    >window that contains the specific image. Google javascript + windows.
    >These will provide scripts that will generate a window that can
    >- by virtue of the javascript - size the window to a specific size and
    >appear in a specific location. This window can contain the img
    >tag detail that will display the image.
    >
    >A decent tutorial on this is :
    >
    >http://www.howtocreate.co.uk/tutorials/javascript/browserwindow
    >
    >Go to it!


    Totlaly frickin wrong!
    He has the wright approach.
    richard, May 6, 2008
    #9
  10. PHPBABY3

    richard Guest

    On Sat, 3 May 2008 14:04:41 -0700 (PDT), PHPBABY3
    <> wrote:

    >How do I display a file c:\MYDIR\A.jpg ?
    >
    >These don't work:
    >
    ><img src="c:\MYDIR\A.jpg">
    >
    ><img src="c:/MYDIR/A.jpg">
    >
    ><img src="c:MYDIR\A.jpg">
    >
    ><img src="c:MYDIR/A.jpg">
    >
    >
    >P -



    <img src="MYDIR/A.jpg">

    Assuming that the host file is in the same directory as "MYDIR".

    You do not need the "C:" unless the src file is in another drive.
    richard, May 6, 2008
    #10
  11. PHPBABY3

    rf Guest

    richard <> wrote in
    news::

    > On Sat, 3 May 2008 14:04:41 -0700 (PDT), PHPBABY3
    > <> wrote:
    >
    >>How do I display a file c:\MYDIR\A.jpg ?
    >>
    >>These don't work:
    >>
    >><img src="c:\MYDIR\A.jpg">
    >>
    >><img src="c:/MYDIR/A.jpg">
    >>
    >><img src="c:MYDIR\A.jpg">
    >>
    >><img src="c:MYDIR/A.jpg">
    >>
    >>
    >>P -

    >
    >
    > <img src="MYDIR/A.jpg">
    >
    > Assuming that the host file is in the same directory as "MYDIR".
    >
    > You do not need the "C:" unless the src file is in another drive.
    >


    Totlaly frickin wrong! :)

    The OP is talking about files on *the users* computer, not the host in
    which case src="c:/MYDIR/A.jpg" but, OP, don't expect it to work in
    secure (that is non-IE) browsers.

    --
    Richard
    Killing all google groups posts
    The Usenet Improvement Project: http://improve-usenet.org
    rf, May 6, 2008
    #11
  12. On Tue, 06 May 2008 04:09:41 GMT, rf <> wrote:

    >richard <> wrote in
    >news::
    >
    >> On Sat, 3 May 2008 14:04:41 -0700 (PDT), PHPBABY3
    >> <> wrote:
    >>
    >>>How do I display a file c:\MYDIR\A.jpg ?
    >>>
    >>>These don't work:
    >>>
    >>><img src="c:\MYDIR\A.jpg">
    >>>
    >>><img src="c:/MYDIR/A.jpg">
    >>>
    >>><img src="c:MYDIR\A.jpg">
    >>>
    >>><img src="c:MYDIR/A.jpg">
    >>>
    >>>
    >>>P -

    >>
    >>
    >> <img src="MYDIR/A.jpg">
    >>
    >> Assuming that the host file is in the same directory as "MYDIR".
    >>
    >> You do not need the "C:" unless the src file is in another drive.
    >>

    >
    >Totlaly frickin wrong! :)
    >
    >The OP is talking about files on *the users* computer, not the host in
    >which case src="c:/MYDIR/A.jpg" but, OP, don't expect it to work in
    >secure (that is non-IE) browsers.


    Correct ! *But* ... i cannot understand the interest of this.
    If the end-user did not have the file c:\MYDIR\A.jpg" on his computer
    - the picture will never appear. Nobody have this file on his computer
    ! (except may be the creator of the html code :)
    Raymond SCHMIT, May 7, 2008
    #12
  13. Raymond SCHMIT wrote:

    > Correct ! *But* ... i cannot understand the interest of this.
    > If the end-user did not have the file c:\MYDIR\A.jpg" on his computer
    > - the picture will never appear. Nobody have this file on his computer
    > ! (except may be the creator of the html code :)


    So what's your point? Fact is "c:\MYDIR\A.jpg" is not a valid path for a
    web page. It is a valid path for a local Windows system. Of course is it
    really clear what you *really* are trying to accomplish.

    --
    Take care,

    Jonathan
    -------------------
    LITTLE WORKS STUDIO
    http://www.LittleWorksStudio.com
    Jonathan N. Little, May 7, 2008
    #13
  14. On Tue, 06 May 2008 22:48:17 -0400, "Jonathan N. Little"
    <> wrote:

    >Raymond SCHMIT wrote:
    >
    >> Correct ! *But* ... i cannot understand the interest of this.
    >> If the end-user did not have the file c:\MYDIR\A.jpg" on his computer
    >> - the picture will never appear. Nobody have this file on his computer
    >> ! (except may be the creator of the html code :)

    >
    >So what's your point? Fact is "c:\MYDIR\A.jpg" is not a valid path for a
    >web page. It is a valid path for a local Windows system. Of course is it
    >really clear what you *really* are trying to accomplish.


    I am not trying to accomplish something, i just don't understand what
    interest someone can have with that possibility.
    Normally the http philosophy is based on a virtual directory placed on
    a physical disk at the server side. All files miust come from this
    server or from another server.....never from a physical disk of the
    end-user.
    Raymond SCHMIT, May 8, 2008
    #14
  15. Raymond SCHMIT wrote:
    > On Tue, 06 May 2008 22:48:17 -0400, "Jonathan N. Little"
    > <> wrote:
    >
    >> Raymond SCHMIT wrote:
    >>
    >>> Correct ! *But* ... i cannot understand the interest of this.
    >>> If the end-user did not have the file c:\MYDIR\A.jpg" on his computer
    >>> - the picture will never appear. Nobody have this file on his computer
    >>> ! (except may be the creator of the html code :)

    >> So what's your point? Fact is "c:\MYDIR\A.jpg" is not a valid path for a
    >> web page. It is a valid path for a local Windows system. Of course is it
    >> really clear what you *really* are trying to accomplish.

    >
    > I am not trying to accomplish something, i just don't understand what
    > interest someone can have with that possibility.
    > Normally the http philosophy is based on a virtual directory placed on
    > a physical disk at the server side. All files miust come from this
    > server or from another server.....never from a physical disk of the
    > end-user.


    Okay so what's with the "c:\" ... If it ids coming from a server, even
    MS's IIS the url will be to a document root of the webserver not the
    local filesystem of the server...


    --
    Take care,

    Jonathan
    -------------------
    LITTLE WORKS STUDIO
    http://www.LittleWorksStudio.com
    Jonathan N. Little, May 8, 2008
    #15
  16. On Thu, 08 May 2008 11:26:53 -0400, "Jonathan N. Little"
    <> wrote:

    >Raymond SCHMIT wrote:
    >> On Tue, 06 May 2008 22:48:17 -0400, "Jonathan N. Little"
    >> <> wrote:
    >>
    >>> Raymond SCHMIT wrote:
    >>>
    >>>> Correct ! *But* ... i cannot understand the interest of this.
    >>>> If the end-user did not have the file c:\MYDIR\A.jpg" on his computer
    >>>> - the picture will never appear. Nobody have this file on his computer
    >>>> ! (except may be the creator of the html code :)
    >>> So what's your point? Fact is "c:\MYDIR\A.jpg" is not a valid path for a
    >>> web page. It is a valid path for a local Windows system. Of course is it
    >>> really clear what you *really* are trying to accomplish.

    >>
    >> I am not trying to accomplish something, i just don't understand what
    >> interest someone can have with that possibility.
    >> Normally the http philosophy is based on a virtual directory placed on
    >> a physical disk at the server side. All files miust come from this
    >> server or from another server.....never from a physical disk of the
    >> end-user.

    >
    >Okay so what's with the "c:\" ... If it ids coming from a server, even
    >MS's IIS the url will be to a document root of the webserver not the
    >local filesystem of the server...


    I did not agree with you - The root of the files on the server *is
    not* a physical adress "C:\" ......The root of the server is the
    Virtual directory....this will permit tou have more than one website
    on the same server.
    Raymond SCHMIT, May 9, 2008
    #16
  17. PHPBABY3

    freemont Guest

    On Fri, 09 May 2008 09:03:10 +0000, Raymond SCHMIT writ:

    > On Thu, 08 May 2008 11:26:53 -0400, "Jonathan N. Little"
    > <> wrote:
    >
    >>Raymond SCHMIT wrote:
    >>> On Tue, 06 May 2008 22:48:17 -0400, "Jonathan N. Little"
    >>> <> wrote:
    >>>
    >>>> Raymond SCHMIT wrote:
    >>>>
    >>>>> Correct ! *But* ... i cannot understand the interest of this.
    >>>>> If the end-user did not have the file c:\MYDIR\A.jpg" on his computer
    >>>>> - the picture will never appear. Nobody have this file on his computer
    >>>>> ! (except may be the creator of the html code :)
    >>>> So what's your point? Fact is "c:\MYDIR\A.jpg" is not a valid path for a
    >>>> web page. It is a valid path for a local Windows system. Of course is it
    >>>> really clear what you *really* are trying to accomplish.
    >>>
    >>> I am not trying to accomplish something, i just don't understand what
    >>> interest someone can have with that possibility.
    >>> Normally the http philosophy is based on a virtual directory placed on
    >>> a physical disk at the server side. All files miust come from this
    >>> server or from another server.....never from a physical disk of the
    >>> end-user.

    >>
    >>Okay so what's with the "c:\" ... If it ids coming from a server, even
    >>MS's IIS the url will be to a document root of the webserver not the
    >>local filesystem of the server...

    >
    > I did not agree with you - The root of the files on the server *is
    > not* a physical adress "C:\" ......The root of the server is the
    > Virtual directory....this will permit tou have more than one website
    > on the same server.


    "What we got here is..."

    http://www.americanrhetoric.com/images/coolhandluke4.JPG

    "... failure to communicate."

    --
    "Because all you of Earth are idiots!"
    ¯`·.¸¸.·´¯`·-> freemont© <-·´¯`·.¸¸.·´¯
    freemont, May 9, 2008
    #17
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Roland
    Replies:
    0
    Views:
    1,042
    Roland
    May 12, 2004
  2. Replies:
    4
    Views:
    208
    Gabriel Genellina
    May 25, 2008
  3. W. eWatson
    Replies:
    3
    Views:
    281
    W. eWatson
    Jan 17, 2010
  4. \A_Michigan_User\
    Replies:
    6
    Views:
    151
    Bob Barrows [MVP]
    Jan 29, 2005
  5. opendir mydir/??/??/??

    , Nov 25, 2007, in forum: Perl Misc
    Replies:
    2
    Views:
    105
    John W. Krahn
    Nov 25, 2007
Loading...

Share This Page