LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 12-17-2009, 08:51 AM   #1
fawcaz
LQ Newbie
 
Registered: Dec 2009
Posts: 12

Rep: Reputation: 0
wget and php redirects


hi, not sure if this is the right board or maybe linux general?

for a question about a linux command.

I was on a linux machine a while back..

wget -i myfile

The file was just a file with this link in it
http://www.htmlgoodies.com/primers/primer_3.html


So wget -i myfile, that should download that file.. I wanted the resultant local saved file to be called primer_3.html but it wasn't, it got called 3478161

I see that link to primer_3.html doesn't exist, saving it manually in the browser gives a page with a 404. But when the browser goes to it, the browser is redirected to
http://www.htmlgoodies.com/primers/h...le.php/3478161
wget is going there.. but the file also gets that number name. So I see why it's happening. But

I have, say, 10 files, I could put in myfile, and do wget -i on them, but i'd want them to retain their lettered names.

TIA
 
Old 12-17-2009, 09:39 AM   #2
rweaver
Senior Member
 
Registered: Dec 2008
Location: Louisville, OH
Distribution: Debian, CentOS, Slackware, RHEL, Gentoo
Posts: 1,833

Rep: Reputation: 167Reputation: 167
The -O option will let you specify an output file. If you need more specific processing you might look towards curl as it has a bit more extensive features than wget.
 
1 members found this post helpful.
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
wget and php urls Orangutanklaus Linux - Software 4 10-02-2009 11:06 AM
wget recursive with additional php arguments Geneset Linux - Networking 0 01-28-2009 11:57 AM
setting up a php cron using wget Roosta21 Linux - Software 1 04-18-2007 06:29 AM
Urgent!!!!! Help with wget and php exec command ?? rajnair0278 Linux - Software 6 03-21-2006 03:19 AM
Configure Php for wget.....Anybody????? rajnair0278 Linux - Software 2 03-21-2006 02:30 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:44 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration