Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - Copying Files (http)
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Copying Files (http)

 Post Reply Post Reply Page  12>
Author
neotrix View Drop Down
Mod Builder Group
Mod Builder Group
Avatar

Joined: 09 November 2003
Location: Pakistan
Status: Offline
Points: 433
Post Options Post Options   Thanks (0) Thanks(0)   Quote neotrix Quote  Post ReplyReply Direct Link To This Post Topic: Copying Files (http)
    Posted: 19 December 2003 at 9:37pm

Hi,

I wanted to know is there a way i can grab a file from my old site instead of reuploading it? there are about 100 Songs in my old site, i want to know if there is a code or something in asp which can directly copy those files form that site to my new site? is it possible ? Long time a ago i saw this feature in the Freeservers CP, it had this option to copy a complete site to the free server account, but i need a code which may do such thing for me. If any one of you knows any thing about it, please do help!

Back to Top
Semikolon View Drop Down
Senior Member
Senior Member


Joined: 09 September 2003
Location: Norway
Status: Offline
Points: 1718
Post Options Post Options   Thanks (0) Thanks(0)   Quote Semikolon Quote  Post ReplyReply Direct Link To This Post Posted: 21 December 2003 at 1:02pm
try search for any examples @ aspin.com or pscode.com
Back to Top
fernan82 View Drop Down
Mod Builder Group
Mod Builder Group
Avatar

Joined: 17 November 2002
Location: United States
Status: Offline
Points: 362
Post Options Post Options   Thanks (0) Thanks(0)   Quote fernan82 Quote  Post ReplyReply Direct Link To This Post Posted: 22 December 2003 at 2:37am
Response.ScriptTimeout = 60 * 60
D
im objStream
Set objStream = CreateObject("ADODB.Stream")
objStream.Type = 1
objStream.Open ("URL=http://youroldsite.com/song.mp3")
objStream.SaveToFile Server.MapPath(".") & "song.mp3", 2
objStream.Close()
Set objStream = Nothing

First problem is unless you're old site has directory browsing enabled you can't get a list of the files (I don't think Freeservers could doit neither), and even if you do it won't be that easy to get the list... Second problem is that it most likely will timeout on you if you're host has a timeout set....


Edited by fernan82
FeRnAN
Back to Top
neotrix View Drop Down
Mod Builder Group
Mod Builder Group
Avatar

Joined: 09 November 2003
Location: Pakistan
Status: Offline
Points: 433
Post Options Post Options   Thanks (0) Thanks(0)   Quote neotrix Quote  Post ReplyReply Direct Link To This Post Posted: 29 December 2003 at 10:39pm
should i just make a new asp file and put this code there ? and it'll copy it ?
Back to Top
neotrix View Drop Down
Mod Builder Group
Mod Builder Group
Avatar

Joined: 09 November 2003
Location: Pakistan
Status: Offline
Points: 433
Post Options Post Options   Thanks (0) Thanks(0)   Quote neotrix Quote  Post ReplyReply Direct Link To This Post Posted: 29 December 2003 at 11:14pm
it says 500 Internal Server Error
Back to Top
Mart View Drop Down
Senior Member
Senior Member
Avatar

Joined: 30 November 2002
Status: Offline
Points: 2304
Post Options Post Options   Thanks (0) Thanks(0)   Quote Mart Quote  Post ReplyReply Direct Link To This Post Posted: 30 December 2003 at 6:36am
try putting server.ScriptTimeout = 10000000 thats assuming it was a timeout error, please post the full error.
Back to Top
neotrix View Drop Down
Mod Builder Group
Mod Builder Group
Avatar

Joined: 09 November 2003
Location: Pakistan
Status: Offline
Points: 433
Post Options Post Options   Thanks (0) Thanks(0)   Quote neotrix Quote  Post ReplyReply Direct Link To This Post Posted: 01 January 2004 at 2:19am
500 Internal Server Error ??
what can be more details of 500 ?
Back to Top
Mart View Drop Down
Senior Member
Senior Member
Avatar

Joined: 30 November 2002
Status: Offline
Points: 2304
Post Options Post Options   Thanks (0) Thanks(0)   Quote Mart Quote  Post ReplyReply Direct Link To This Post Posted: 01 January 2004 at 6:27am
What line it occured on etc. Paste the whole error in we are not phsycic we cannot look at your code magically and guess where/what the error is.

Edited by Mart
Back to Top
 Post Reply Post Reply Page  12>

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.