upload

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Shelly

    upload

    I want to give the user a "Browse" button to locate the file on his system
    that he wants to upload to the server. Where is a good example of how to do
    this?

    Shelly


  • Jerry Stuckle

    #2
    Re: upload

    Shelly wrote:[color=blue]
    > I want to give the user a "Browse" button to locate the file on his system
    > that he wants to upload to the server. Where is a good example of how to do
    > this?
    >
    > Shelly
    >
    >[/color]

    You need to use javascript. PHP runs on the server and doesn't have
    access to the user's file system (thank goodness!).

    --
    =============== ===
    Remove the "x" from my email address
    Jerry Stuckle
    JDS Computer Training Corp.
    jstucklex@attgl obal.net
    =============== ===

    Comment

    • Ivan Omelchenko 608308824

      #3
      Re: upload

      Shelly ÐÉÛÅÔ:[color=blue]
      > I want to give the user a "Browse" button to locate the file on his system
      > that he wants to upload to the server. Where is a good example of how to do
      > this?
      >
      > Shelly
      >
      >[/color]
      HTML tag:
      <input type="file" name="userfile" >
      that's all you need.
      Try

      Comment

      • Shelly

        #4
        Re: upload


        "Ivan Omelchenko 608308824" <news@omelchenk o.com> wrote in message
        news:42B95608.1 040004@omelchen ko.com...[color=blue]
        > Shelly ÐÉÛÅÔ:[color=green]
        >> I want to give the user a "Browse" button to locate the file on his
        >> system that he wants to upload to the server. Where is a good example of
        >> how to do this?
        >>
        >> Shelly[/color]
        > HTML tag:
        > <input type="file" name="userfile" >
        > that's all you need.
        > Try[/color]

        No, I want to have a "Browse" button on the web page that the user clicks
        and uses to locate the file he wants. He would then click "OK" and I would
        have the full file path for "userfile" in order to use the upload function
        in php.

        Shelly


        Comment

        • Shelly

          #5
          Re: upload


          "Jerry Stuckle" <jstucklex@attg lobal.net> wrote in message
          news:q6GdnV7C0u yUyCTfRVn-uw@comcast.com. ..[color=blue]
          > Shelly wrote:[color=green]
          >> I want to give the user a "Browse" button to locate the file on his
          >> system that he wants to upload to the server. Where is a good example of
          >> how to do this?
          >>
          >> Shelly[/color]
          >
          > You need to use javascript. PHP runs on the server and doesn't have
          > access to the user's file system (thank goodness!).[/color]

          Do you have an example anywhere and can I mix and match with php files?

          Shelly



          Comment

          • Aidan

            #6
            Re: upload

            Shelly wrote:[color=blue]
            > "Ivan Omelchenko 608308824" <news@omelchenk o.com> wrote in message
            > news:42B95608.1 040004@omelchen ko.com...
            >[color=green]
            >>Shelly ÐÉÛÅÔ:
            >>[color=darkred]
            >>>I want to give the user a "Browse" button to locate the file on his
            >>>system that he wants to upload to the server. Where is a good example of
            >>>how to do this?
            >>>
            >>>Shelly[/color]
            >>
            >>HTML tag:
            >><input type="file" name="userfile" >
            >>that's all you need.
            >>Try[/color]
            >
            >
            > No, I want to have a "Browse" button on the web page that the user clicks
            > and uses to locate the file he wants. He would then click "OK" and I would
            > have the full file path for "userfile" in order to use the upload function
            > in php.
            >
            > Shelly
            >[/color]

            Google is your friend:



            or


            Comment

            • Michel

              #7
              Re: upload

              Don't listen to that. It's not true.
              partially HTML and partly php will do fine.
              read the tutorial, plz

              "Shelly" <sheldonlg.news @asap-consult.com> wrote in message
              news:C4GdnRVfr4 HlxCTfRVn-rg@comcast.com. ..[color=blue]
              >
              > "Jerry Stuckle" <jstucklex@attg lobal.net> wrote in message
              > news:q6GdnV7C0u yUyCTfRVn-uw@comcast.com. ..[color=green]
              > > Shelly wrote:[color=darkred]
              > >> I want to give the user a "Browse" button to locate the file on his
              > >> system that he wants to upload to the server. Where is a good example[/color][/color][/color]
              of[color=blue][color=green][color=darkred]
              > >> how to do this?
              > >>
              > >> Shelly[/color]
              > >
              > > You need to use javascript. PHP runs on the server and doesn't have
              > > access to the user's file system (thank goodness!).[/color]
              >
              > Do you have an example anywhere and can I mix and match with php files?
              >
              > Shelly
              >
              >
              >[/color]


              Comment

              • Jerry Stuckle

                #8
                Re: upload

                Michel wrote:[color=blue]
                > Don't listen to that. It's not true.
                > partially HTML and partly php will do fine.
                > read the tutorial, plz
                >
                > "Shelly" <sheldonlg.news @asap-consult.com> wrote in message
                > news:C4GdnRVfr4 HlxCTfRVn-rg@comcast.com. ..
                >[color=green]
                >>"Jerry Stuckle" <jstucklex@attg lobal.net> wrote in message
                >>news:q6GdnV7C 0uyUyCTfRVn-uw@comcast.com. ..
                >>[color=darkred]
                >>>Shelly wrote:
                >>>
                >>>>I want to give the user a "Browse" button to locate the file on his
                >>>>system that he wants to upload to the server. Where is a good example[/color][/color]
                >
                > of
                >[color=green][color=darkred]
                >>>>how to do this?
                >>>>
                >>>>Shelly
                >>>
                >>>You need to use javascript. PHP runs on the server and doesn't have
                >>>access to the user's file system (thank goodness!).[/color]
                >>
                >>Do you have an example anywhere and can I mix and match with php files?
                >>
                >>Shelly
                >>
                >>
                >>[/color]
                >
                >
                >[/color]

                Please tell me - how can you list files on the user's computer via PHP?
                That would be a HUGE security risk!

                --
                =============== ===
                Remove the "x" from my email address
                Jerry Stuckle
                JDS Computer Training Corp.
                jstucklex@attgl obal.net
                =============== ===

                Comment

                • craig

                  #9
                  Re: upload

                  Shelly wrote:[color=blue]
                  > "Ivan Omelchenko 608308824" <news@omelchenk o.com> wrote in message
                  > news:42B95608.1 040004@omelchen ko.com...
                  >[color=green]
                  >>Shelly ÐÉÛÅÔ:
                  >>[color=darkred]
                  >>>I want to give the user a "Browse" button to locate the file on his
                  >>>system that he wants to upload to the server. Where is a good example of
                  >>>how to do this?
                  >>>
                  >>>Shelly[/color]
                  >>
                  >>HTML tag:
                  >><input type="file" name="userfile" >
                  >>that's all you need.
                  >>Try[/color]
                  >
                  >
                  > No, I want to have a "Browse" button on the web page that the user clicks
                  > and uses to locate the file he wants. He would then click "OK" and I would
                  > have the full file path for "userfile" in order to use the upload function
                  > in php.
                  >
                  > Shelly
                  >
                  >[/color]
                  If you want Browse....

                  <input type="file" name="Browse">

                  But the PHPfreaks tutorial will show you how to handle the file upload.

                  Comment

                  • Shelly

                    #10
                    Re: upload


                    "Jerry Stuckle" <jstucklex@attg lobal.net> wrote in message
                    news:rLqdnVzNEZ syMyTfRVn-ow@comcast.com. ..[color=blue]
                    > Please tell me - how can you list files on the user's computer via PHP?
                    > That would be a HUGE security risk![/color]

                    As I have just learned, it is HTML and not PHP. An HTML input type of
                    "files" brings up the browse button. This is run on the user's machine, not
                    the server, so only the user sees his own files. The submit button simply
                    activates sending only the ONE chosen file (fully specified), and since this
                    is the one he wants to send anyway, who cares?

                    Shelly


                    Comment

                    • Jerry Stuckle

                      #11
                      Re: upload

                      Shelly wrote:[color=blue]
                      > "Jerry Stuckle" <jstucklex@attg lobal.net> wrote in message
                      > news:rLqdnVzNEZ syMyTfRVn-ow@comcast.com. ..
                      >[color=green]
                      >>Please tell me - how can you list files on the user's computer via PHP?
                      >>That would be a HUGE security risk![/color]
                      >
                      >
                      > As I have just learned, it is HTML and not PHP. An HTML input type of
                      > "files" brings up the browse button. This is run on the user's machine, not
                      > the server, so only the user sees his own files. The submit button simply
                      > activates sending only the ONE chosen file (fully specified), and since this
                      > is the one he wants to send anyway, who cares?
                      >
                      > Shelly
                      >
                      >[/color]

                      That's true. However, I thought you wanted a separate "browse" button
                      to be able to select files - not the one with the "files" input.

                      --
                      =============== ===
                      Remove the "x" from my email address
                      Jerry Stuckle
                      JDS Computer Training Corp.
                      jstucklex@attgl obal.net
                      =============== ===

                      Comment

                      Working...