On Do, 2009-06-18 at 16:14 -0700, Jindan Zhou wrote: > I am a bash beginner, just started to build a script that does: > > 1. Check if a BBS type site has any new posts, the new thread URL pattern is > http://www.example.com/bbsviewer.php?trd_id=123456 > > 2. If 1 is true, go into that URL, find a file link of the pattern > http://www.example.com/upload_music/4153216.mp3 > > 3. If the link in 2 exist, download it to a directory.
Actually, this has very little to do with bash. bash is a UNIX shell and provides the glue between other tools. In your case, the tool is probably something like GNU wget, which can be driven from bash. > Can someone kindly point me to a direction to accomplish this? Is there > better way to do, like PHP? PHP is best known for server-side web programming, and I don't think it would be better suited for your problem than any other programming language. -- Best Regards, | Hi! I'm a .signature virus. Copy me into Sebastian | your ~/.signature to help me spread!