Uploading

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

    Uploading

    I have a folder called x-tract and in that folder i have a folder called
    admin and music.
    while in the admin folder i want to upload a file to the music file. i;ve
    tried
    copy($_FILES['musicfile']['tmp_name'],
    "../music/".$_FILES['musicfile']['name']); ?> this does not work.
    any ideas?

    thanks
    --
    Kathryn (Fire Juggler)




  • Markus L.

    #2
    Re: Uploading

    Am Fri, 01 Jul 2005 19:43:01 +0100 schrieb Fire Juggler:
    [color=blue]
    > I have a folder called x-tract and in that folder i have a folder called
    > admin and music.
    > while in the admin folder i want to upload a file to the music file. i;ve
    > tried
    > copy($_FILES['musicfile']['tmp_name'],
    > "../music/".$_FILES['musicfile']['name']); ?> this does not work.
    > any ideas?
    >
    > thanks[/color]

    Use absolute path names:

    copy($_FILES['musicfile']['tmp_name'],"/tmp/x-tract/music/".$_FILES['musicfile']['name']);

    --
    -------------------------------------------------------
    Try this: SCA the Smart Class Archive for PHP

    -------------------------------------------------------

    Comment

    • Fire Juggler

      #3
      Re: Uploading

      Hi, Thanks for the help, i tried what you said, but still no luck. why
      /tmp/x-tract/music/ ?
      Thanks

      --
      Kathryn (Fire Juggler)



      "Markus L." <nobody@proje ct-sca.org> wrote in message
      news:pan.2005.0 7.01.21.09.20.8 27284@project-sca.org...[color=blue]
      > Am Fri, 01 Jul 2005 19:43:01 +0100 schrieb Fire Juggler:
      >[color=green]
      > > I have a folder called x-tract and in that folder i have a folder called
      > > admin and music.
      > > while in the admin folder i want to upload a file to the music file.[/color][/color]
      i;ve[color=blue][color=green]
      > > tried
      > > copy($_FILES['musicfile']['tmp_name'],
      > > "../music/".$_FILES['musicfile']['name']); ?> this does not work.
      > > any ideas?
      > >
      > > thanks[/color]
      >
      > Use absolute path names:
      >
      >[/color]
      copy($_FILES['musicfile']['tmp_name'],"/tmp/x-tract/music/".$_FILES['musicfi
      le']['name']);[color=blue]
      >
      > --
      > -------------------------------------------------------
      > Try this: SCA the Smart Class Archive for PHP
      > http://www.project-sca.org
      > -------------------------------------------------------
      >[/color]


      Comment

      • Fire Juggler

        #4
        Re: Uploading

        My file x-tract is not in a tmp folder it;s in httpdocs, so i replaced tmp
        with httpdocs in the code you gave me. But it is still not working. any more
        ideas?
        Thanks

        --
        Kathryn (Fire Juggler)




        "Fire Juggler" <firejuggler@fi rejugglers.34sp .com> wrote in message
        news:da42rk$34b $1@news8.svr.po l.co.uk...[color=blue]
        > I have a folder called x-tract and in that folder i have a folder called
        > admin and music.
        > while in the admin folder i want to upload a file to the music file. i;ve
        > tried
        > copy($_FILES['musicfile']['tmp_name'],
        > "../music/".$_FILES['musicfile']['name']); ?> this does not work.
        > any ideas?
        >
        > thanks
        > --
        > Kathryn (Fire Juggler)
        > http://www.firejugglers.34sp.com
        > http://www.cornwalljugglers.co.uk
        >
        >[/color]


        Comment

        Working...