英文:
EvoPdf: Problem on converting html to image while using baseUrl for external resources
问题
I'm using EvoPdf for converting HTML to an Image (EvoPdf: ConvertHtmlToImageObject). Now I tried to set the baseUrl for using local resources like: in the html I'm using a css link for custom fonts.
imgConverter.ConvertHtmlToImageObject(html, baseUrl: path)
-> the folder contains the css with the @font-faces and the custom font ttf's and woff's.
But somehow it doesn't work. It's like it doesn't even read the baseUrl.
I was trying to use different baseUrl's, I placed my resources in all different folders of the project but still nothing worked.
Does someone have an idea what I could be doing wrong?
Or even better a working example?
Thanks guys!
英文:
I'm using EvoPdf for converting HTML to an Image (EvoPdf: ConvertHtmlToImageObject). Now I tried to set the baseUrl for using local resources like: in the html I'm using a css link for custom fonts.
imgConverter.ConvertHtmlToImageObject(html, baseUrl: path)
-> the folder contains the css with the @font-faces and the custom font tff's and woff's.
But somehow the it doesn't work. It's like it doesn't even read the baseUrl.
I was trying to use differen baseUrl's, I placed my resources in all different folders of the project but still nothing worked.
Does someone have an idea what I could be doing wrong?
Or even better a working example?
Thanks guys!
答案1
得分: 0
谢谢各位!
我认为我找到了问题所在。我尝试连接到本地驱动器,而不是使用网站资源。
BaseUrl应该是我的网站的URL。
英文:
Thanks guys!
I think I found the issue. I tried to connect to a local drive instead of using the website resources.
The BaseUrl is supposed to be the URL of my website.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。


评论