Jump to content
UBot Underground

Recommended Posts

  • 3 weeks later...

Have you tried to disable javascript?

I don't think javascript has anything to do with this.

 

I think that UBot browser tries to look for pdf viewer, but for some reason it doesn't work, that's why I think we get a blank page.

Link to post
Share on other sites

I've looked at a similar thing before. What I ended up doing was taking a screenshot of a page and uploading it to an OCR website. Then it would email me the content of the text that appeared in the screenshot. Would this work as a temporary workaround?

Link to post
Share on other sites

I've looked at a similar thing before. What I ended up doing was taking a screenshot of a page and uploading it to an OCR website. Then it would email me the content of the text that appeared in the screenshot. Would this work as a temporary workaround?

I don't think it would, since page comes up blank so taking screenshot of blank page wouldn't take you far.

Link to post
Share on other sites

Ahh sorry yeah! Blank page won't be much good in fairness!

 

Idea: download the pdf then add it to google drive? Might be able to automate something from that perhaps?

Link to post
Share on other sites

Ahh sorry yeah! Blank page won't be much good in fairness!

 

Idea: download the pdf then add it to google drive? Might be able to automate something from that perhaps?

If URL exists there is no problem downloading the PDF with UBot's download command, but if you don't have URL (URL generated on server side, and you get PDF served after redirect) you won't be able to download it, since after clicking the button it will auto load the page/pdf from a random URL and your screen will remain blank.

Link to post
Share on other sites

If URL exists there is no problem downloading the PDF with UBot's download command, but if you don't have URL (URL generated on server side, and you get PDF served after redirect) you won't be able to download it, since after clicking the button it will auto load the page/pdf from a random URL and your screen will remain blank.

 

Ok I got the dark screen by browsing in through ubot's browser.

 

However, I have managed to get a pdf to load inside ubot's browser, albeit via a non-traditional method and not sure whether it will be what's required.

 

Ultimately I think it will need to go to an OCR site or some such, but, the PDF does load, as images but it loads ALL the pages contained inside the PDF.

 

Here's the code:

ui text box("URL to PDF", #pdfurl)
navigate(#pdfurl, "Wait")
navigate("http://view.samurajdata.se/", "Wait")
change attribute(<url field>, "value", "http://{#pdfurl}")
click($element offset(<name="submit">, 0), "Left Click", "No")
wait for element(<innertext="Viewer home">, "", "Appear")
alert("PDF Loaded")

Sample PDF: www.handysoftware.com/cpif/docs/CPIF-Lesson-04.pdf

 

I've made the code so as you can simply add a PDF to the text box. It first Navigates to the pdf as normal so you'll see it load a dark page then it loads via that website.

Link to post
Share on other sites

Ok I got the dark screen by browsing in through ubot's browser.

 

However, I have managed to get a pdf to load inside ubot's browser, albeit via a non-traditional method and not sure whether it will be what's required.

 

Ultimately I think it will need to go to an OCR site or some such, but, the PDF does load, as images but it loads ALL the pages contained inside the PDF.

 

Here's the code:

ui text box("URL to PDF", #pdfurl)
navigate(#pdfurl, "Wait")
navigate("http://view.samurajdata.se/", "Wait")
change attribute(<url field>, "value", "http://{#pdfurl}")
click($element offset(<name="submit">, 0), "Left Click", "No")
wait for element(<innertext="Viewer home">, "", "Appear")
alert("PDF Loaded")

Sample PDF: www.handysoftware.com/cpif/docs/CPIF-Lesson-04.pdf

 

I've made the code so as you can simply add a PDF to the text box. It first Navigates to the pdf as normal so you'll see it load a dark page then it loads via that website.

 

Why wouldn't you just use "download file" when you have the url already?

download file("http://www.handysoftware.com/cpif/docs/CPIF-Lesson-04.pdf", "c:\\downloaded.pdf")

Again, the problem exists in case where you don't have/can't find PDF URL on the website, but instead the website loads PDF after redirect. The problem is that if you navigate to the URL again it won't show PDF anymore since it's generated dynamically... 

Link to post
Share on other sites

The OP couldn't load a pdf in the browser. Sure he could of downloaded it but my interpretation of the post was he needed it loaded in a browser. Download file seemed too obvious didn't it?!

Link to post
Share on other sites

I have an invoicing system that does something similar to what you described about downloading the pdf file. I'll take a look on my end. I am sure a dialogue box will appear though but TJ has a plugin for that which will bring it to front if I recall.

Link to post
Share on other sites

The OP couldn't load a pdf in the browser. Sure he could of downloaded it but my interpretation of the post was he needed it loaded in a browser. Download file seemed too obvious didn't it?!

Ah, you are right...forgot what OP actually wanted to achieve. Nice workaround, although if he doesn't have URL (as described above) that also won't be possible. I think this is something UBot team would need to fix...

Link to post
Share on other sites

I have an invoicing system that does something similar to what you described about downloading the pdf file. I'll take a look on my end. I am sure a dialogue box will appear though but TJ has a plugin for that which will bring it to front if I recall.

I think I had problems a year ago when I tried to download PDF from Scribd.com. Instead of a download popup pdf got rendered blank and the URL didn't work when I tried to download PDF after it got displayed (URL was expired, so I would need to click download button again to generate a new one).

 

So I'm just saying that if that happens he won't be even able to use the workaround you provided.

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...