angularjs expression in html <object> tag

后端 未结 5 2252
感情败类
感情败类 2020-12-03 03:42

I have a scope like $scope.doc_details in my angularjs controller, and I want to use it to display a pdf file by using a tag, like this:



        
5条回答
  •  时光取名叫无心
    2020-12-03 04:11

    You first need to check if the response is an arraybuffer, if it is, convert it to base 64. Also you can use setattribute to assign.

    enter image description here

提交回复
热议问题