How to upload files using testRigor when i don't have an input type=file? [closed] - web-testing

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 2 years ago.
Improve this question
i'm using testRigor to make webstesting in our software but we have this screen where we can click to open the upload box or we can drag the file there to upload it:
How can I make testRigor find this input to 'drag' the file if here in the documentation we have this information:
The file upload is supported out of the box. Just use it like the
following:
enter "<FILE_URL>" into "fileField"
It's said that this command 'enters' the file URL into the type=file input but as you can see in the image, I don't have this type of input to put the file.
Thanks!

It's said that this command 'enters' the file URL into the type=file input but as you can see in the image, I don't have this type of input to put the file.
Checking on the image you share, you have that type of input there:
<input id="file-input-cd730" accept="text/xml" hidden type="file">
With that said, first thing you need is to upload your desired file to some cloud storage system. The file needs to be accessible by testRigor.
Then you can do
enter "<url-to-mentioned-file>" into "file-input-cd730"
if you want to do a file upload.
Now if you want to do a drag and drop considering your sample page is:
<div class="file input dropzone ">
<label for="file-input-cd730" id="ember568" class="file-upload ember-view">
<input id="file-input-cd730" accept="text/xml" hidden type="file">
"Arrastre um arquivo para cá ou clique aqui para escolher um arquivo"
</label>
</div>
you can do
drag file "<url-to-your-file" into "dropzone"

Related

Converting word to pdf: Some hyperlinks don't work [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 1 year ago.
Improve this question
I am converting a word file into a pdf. Word version is 2016. I need to have hyperlinks active (References to sections, figures, etc.)
I use Export - Create a PDF/XPS Document and Optimized for Standard.
I have references to figures and tables completely working, but references to sections don't work. In the Table of Content, I cannot click on the page numbers. What can be done to have links to sections working?
To retain hyperlinks while converting word to pdf:
In word: Go to file, save as, choose option 'Best for electronic distribution and accessibility' and export.
Printing Word Document as PDF will deactivate all URL or link if it is inside a Text or Picture.
But if you use Save As PDF or Export as PDF Option to make your PDF all URL or link will be active and you can click on that text or picture to visit your desired link or URL.
Using Save as Option
Using Export
When you use Export as PDF,
make sure you are not on the option that says Best for printing
because your document is to be used for Electronic purposes.
Super simple way - Use the web version.
Visit office.com.
Open Word.
Create/Upload the document.
Click on File tab -> Save As -> Download As PDF.
P.S. - On uploading the document if you found it distorted/broken in the web version, just go ahead and download the PDF, it will not be distorted.
This is what worked for me:
Click on File -> Save As
In the popup, select the file type as PDF.
Click on the "Options" button.
Check the check box which says "PDF/A Compliant".
Click on OK and save the file in the required folder.
Also from what I've read, PDF/A is a better format for the future. Read more about it here: PDF/A Compliance
And another answer, but since nobody wrote it yet:
In my PDF no links worked until I deleted all internal links to other places in the doc, like footnotes. Once I deleted all internal links the http-links worked again. Be aware: one single link breaks the whole document!
If you click on Options in Save As, the options dialog will pop up. Under "Include non-printing information check Create bookmarks using ... checkbox, and select Heading radio button.
I used Save as Adobe PDF instead of Save As .. then select pdf format, none of the latter works. Save as Adobe PDF retained the hyperlinks for me, and the file size is a lot smaller too.
Under File, click "options".
Click on "Advanced" on the left side of the Word options pop up.
Uncheck "CTRL + Click to follow hyperlink"
Click "Ok".
Once you're done with this, proceed with converting your word file to pdf. The hyperlinks should be active now.

How to show the uploaded file in File picker in Moodle?

Hi I am working with Moodle 2.9.1. Here I have a form for upload a question and an answer file. I successfully upload the answer file to a location and inserted the question text and answer file name in database.
Now I want to edit the question, while editing the question the already uploaded file will be shown in the file picker area.
How can I show the uploaded file in filepicker area??
For text editor I can use
$mform->addElement('editor', 'desc', get_string('description'));
$mform->setDefault('desc', array('text'=>$defaulttext));
Please help me..
The filepicker element is used for uploading a single one-off file, that will be processed (and then, usually, discarded). If you are wanting a file that remains part of the Moodle storage and will reappear when you reopen the form, then you should use a filemanager (and restrict to a single file, if needed).
There are details in the Moodle docs about how to use this https://docs.moodle.org/dev/Using_the_File_API_in_Moodle_forms#filemanager (including re-populating the 'draft files' area when you load the form).

Wget downloading incomplete file from a URL [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 9 years ago.
Improve this question
I want to get a file downloaded on my linux system whose url is
http://download.oracle.com/otn-pub/java/jdk/7u51-b13/jre-7u51-linux-i586.tar.gz
and I am issuing the following command as :
wget -U 'Mozilla/5.0 (X11; Ubuntu; Linux i686; rv:16.0) Gecko/20100101 Firefox/16.0' http://download.oracle.com/otn-pub/java/jdk/7u51-b13/jre-7u51-linux-i586.tar.gz
whereas the user agent is being passed to -U which i have copied from my browser's user agent. But it downloads the file only of size 5.3KB whereas entire file is 46.09MB and the downloaded file is corrupted.
How can I resolve this issue?
Looking at the output, you will realize that oracle denied the request, containing following message:
In order to download products from Oracle Technology Network you must
agree to the OTN license terms.
Be sure that...
Your browser has "cookies" and JavaScript enabled.
You clicked on "Accept License" for the product you wish to download.
You attempt the download within 30 minutes of accepting the license.
Most probably you have to send some GET or POST value and/or keep session data.
The file isn't 'corrupt' exactly; if you go to that URL in a new browser session you'll see an error page saying 'In order to download products from Oracle Technology Network you must agree to the OTN license terms.'. That is the page you've downloaded - the file size of the page it redirects to is 5307 bytes.
Before you can get the file from the download page you have to accept the license agreement using the radio buttons. Doing so creates a cookie in your browser, and when you get the actual file that cookie is checked. wget doesn't have that cookie available.
You need to download directly from the site, or arrange for wget to send a fake cookie, which probably isn't supported in general. Some downloads used to have a wget script attached, not sure if this one does; it doesn't look like it from what's on the download page.

Table stuck in header - Word 2010 [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 8 years ago.
Improve this question
Somehow, I got some tables inside the header and some inside the footers in the document Im working on. They are not supposed to be there, and this destroys the formatting.
How do I move a table out of the header/footer in Word 2010? They seem to be locked in there no matter what I do. I've tried copy/paste, dragging it, copy it to another document and back. Is there some settings on the table it self? Google has not found anything for me.
I had this happen to me just a second ago and was able to figure it out - hopefully the same thing is causing the problem for you.
I clicked on the table - then "table tools/layout" in the ribbon - then "properties" - alternatively you can right click on the table and select "table properties"
Once the "table properties" box opens - click on the "table" tab (it should be automatically selected by default) - make sure "text wrapping" is set to "none"
That should solve the problem - it did for me at least.
I'm not an expert in Word but I know how Word Document are structured.
We're going to open the content of the header in a text Editor.
Steps:
Be sure to make a copy of your document before this operations, because the resulting document could be corrupted
Rename your file in a .zip file
Extract the zip in a folder named document
Go inside that folder, than in the word folder.
You should see a file named header.xml (or header1.xml)
Open it in a textEditor
Try to find out where the table is and remove it
Ensure your xml is still valid: XML Validator
Save and close your file, and zip all folders and files inside the document (if you zip the whole document folder, the file will be corrupted)
Rename the zipped file to .docx
Open the file in Word
If this doesn't work, you could post your Header.xml file, they should'nt be some confidential in there (or you could replace it by whatever you want)
I had the same problem. I just changed the orientation of the page to landscape:
Go to page layout
Go to orientation
Select landscape
The table was still on a header, but word created a page 2 and page 1 was blank. From page 2, I just dragged the table onto page 1 and it was no longer in the header!
Then, change the orientation back to portrait (follow 2 steps above and select portrait in final step).
Hope this helps!
Thanks for the answers! This is how I solved the problem:
I fixed it "manually". I just made a new document and started copying over, there was more than one table bugging. Thanks for the help anyway!
Since this question is from July 2013, and I solved it then, I'm not testing your replies. But, they might be great for other people with the same problem! They are probably better solutions than just starting over.

Show PDF in iPad using CGPDF APIs [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
I have learned Apple has release CGPDF APIs in SDK 3.2 for drawing PDF context.
What I understand from these APIs is that you can draw a PDF to a data object or a PDF file. You can then export it, may be, to your sandbox's directory OR add as an attachment in the mail.
But I am not sure if we can use these APIs to read a PDF from application bundle and show it to the user page-by-page on the screen. What I want to do is open a PDF of a magazine in a magazine reader app.
I was also wondering if we can identify the links in a PDF file and open them in the app.
Let me know if have done OR doing anything like this.
Thanks
AJ
In API documentation there is a way to load a PDF (with Quartz):
CGPDFDocument is the object you need
and CGPDFDocumentCreateWithURL is probably the constructor you are looking for.
Here are some examples on how to do it:
http://developer.apple.com/mac/library/documentation/GraphicsImaging/Conceptual/drawingwithquartz2d/dq_pdf/dq_pdf.html#//apple_ref/doc/uid/TP30001066-CH214-TPXREF109
I have spent a lot of time on this - and it seems you need to use CATiledLayers to zoom those PDFs properly!
There are some good examples on the net on how to do that...
I will put a link/solution here as soon as I have something ready!
Displaying the PDF with the Quartz APIs is pretty easy. But there's no native support for link annotations. Basically, you need to parse the "Annots" dictionary inside the pdf, and then find the correct page (which can be GoTo references, or named references, or ~10 other types; see the Adobe PDF Reference 1.7 document, the section about Actions), and the calculate the coordinates to the displayed page.
I've written a [commercial] library that includes parsing link annotations, and many more features. You may wanna check out http://pspdfkit.com