问题
I would like to specify the password of a PDF file in my request. Is this possible? Currently my code is as following:
NSString *nomPdf=_pdffile.name;
NSString *path = [[NSBundle mainBundle] pathForResource:nomPdf ofType:@"pdf"];
NSURL *url;
NSURLRequest *request;
if(path !=nil){
url = [NSURL fileURLWithPath:path];
request = [NSURLRequest requestWithURL:url];
}
How can I pass the password string required of the PDF file in this code ?
回答1:
Not fully an answer, but to rule out options, it sounds like you can't embed the password as part of a URL.
来源:https://stackoverflow.com/questions/10519122/pdf-file-in-uiwebview-with-password