且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

我想在Web应用程序中嵌入PDF编辑器

更新时间:2023-10-16 17:32:16

你的问题假定你有一些PDF编辑器,只有嵌入它的问题,但你没有显示这样的东西。请看我对这个问题的评论。即使正式地,PDF可以像任何其他文件一样进行编辑,但实际上它几乎完全是胡说八道。然而,我遇到了需要这些的客户,主要是那些未能与合作伙伴组织业务以接收真实数据的输家,因此他们收到PDF,这几乎与接收纸质文件相同。在正常的业务中,PDF只是工作流程的最后一点:您以PDF格式呈现数据,只是查看它,而不是尝试读取文件以外的任何内容。



还有PDF用于填充数据的互动元素,但这是一个不同的故事。



因此,我们的想法是:创建一个HTML编辑器(有许多),并且,在服务器端,采取用户创建的HTML



使用PHP,这可以用来表示PDF格式的数据: FPDF [ ^ ]。



我不知道为什么会这样做,但是Web应用程序生成的PDF或多或少都被广泛使用。你也可以这样做。



-SA
Your question assumes that you have some PDF editor, only have problem embedding it, but you did not show anything like that. Please see my comment to the question. Even though, formally, PDF can be edited, as any other file, but in practice it is nearly complete nonsense. However, I faced clients who needed that, mostly the losers who failed to organize business with partners to receive real data, so they receive PDF, which is almost the same as receiving documents on paper. In normal business, PDF can be only the final point of workflow: you present data in PDF and just look at it, not trying to read the file for anything except rendering it.

There are also PDF with interactive elements used to fill in data, but this is a different story.

So, the idea is: create an HTML editor (there are many) and, on the server side, take HTML created by the user

With PHP, this is what you can use to represent data in the form of PDF: FPDF[^].

I don't know why doing so, but generation of PDF by Web application is widely used, more or less. You can do it, too.

—SA