Kurt 1 Posted April 11, 2010 Report Share Posted April 11, 2010 Hi Everyone, I'm having trouble downloading images from Morguefile. I don't want to use the download link, but rather save the picture that is being displayed on the page:http://morguefile.com/archive/display/214082 Here's the problem, I can download the image correctly if I give the image a static name like:c:\documents\pic.jpg But if a new image is downloaded is just overwrites the previous image instead of adding the new image. However, if I try to change the file name to a varible like the following, the image doesn't download:c:\documents\pic{1}.jpg where {1} is a variable to add a random number. In other words, when naming the image to be downloaded, c:\documents\pic.jpg - worksc:\documents\pic{1}.jpg - doesn't work Quote Link to post Share on other sites
alcr 135 Posted April 11, 2010 Report Share Posted April 11, 2010 Set #counter 0loop x timesscrape image with the searchway as c:\documents\filename{1} where 1 points to #counterinc #counter Quote Link to post Share on other sites
Aaron Nimocks 19 Posted April 11, 2010 Report Share Posted April 11, 2010 I would make sure your {1} is actually outputting the right thing. Just put a UI Status of that variable so you can see what the output is. Biggest issue I always had is if the variable didnt have a value it wouldnt save. If the filename had any of the characters that arent allowed \ / : * ? " < > | it wouldnt save. Quote Link to post Share on other sites
Kurt 1 Posted April 11, 2010 Author Report Share Posted April 11, 2010 Set #counter 0loop x timesscrape image with the searchway as c:\documents\filename{1} where 1 points to #counterinc #counter Thanks Alcr for the quick reply. I give it a try. Quote Link to post Share on other sites
Kurt 1 Posted April 11, 2010 Author Report Share Posted April 11, 2010 I would make sure your {1} is actually outputting the right thing. Just put a UI Status of that variable so you can see what the output is. Biggest issue I always had is if the variable didnt have a value it wouldnt save. If the filename had any of the characters that arent allowed \ / : * ? " < > | it wouldnt save. Thanks Aaron, Right now the script requires the user to navigate to the page itself then play the script, which at this point merely downloads the image by pressing the script's start button. The entire script right now is really:select image (by position)Download image I'm using the file name just as posted:c:\documents\pic{1}.jpg The {1} is set to:$rand = 1 - 99999 One note: Ubot doesn't want to place the {1} in the correct spot, and I have to type it in the proper place after adding the $rand function. Does anyone have the time to simply have the bot select and download an image at Morguefile? (again, the image displayed on page, not the download link) Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.