我爱占星网 我爱占星网
首页
编程
java
php
前端
首页 编程 java php 前端

从PHP中删除PDF中的无效字符

We're getting PDFs from a vendor that have 58,000+ null characters following the legal end of the document %%EOF. We're working with the vendor to see if they can correct it, but I want to get ahead of the issue in case they can't.

Using PHP (or classic ASP, though I doubt that's possible) I want to

  • find the EOF marker

  • strip anything after

  • and resave the file as a valid PDF.

I've not worked with binary files before and have only a vague idea of where to even start.

近期文章

  • 已启用状态的产品的产品计数
  • Xcode通过php发布到mysql工作从模拟器,但不是从设备
  • php - 将JPEG插入SQL数据库时发出警告
  • 验证嵌套关系中没有重复 - CakePHP 2
  • 通过组合symfony2和ajax创建注册表单
  • jQuery - 用php数组检查用户输入
  • 如何将yii2-solr与mongodb集成?
  • CORS不允许jquery AJAX获得结果
  • 当我使用PHP echo时,Font Awesome图标无法渲染?
  • Laravel 5未在子文件夹中加载图像
  • 字段隐藏时输出表示数组
  • Mage注册表项“_singleton / [Extension_Model_Core]”已经存在
  • 使用php将文件移动并收集到Amazon S3存储桶
  • 启用浏览器缓存时如何处理文件更改?
  • 阻止用户以特定权限级别登录,然后显示警报以告知用户原因
  • 使用PhpMailer类使用PHP发送电子邮件返回Developer Tools中的错误500
  • JavaScript委托并选择AJAX响应
  • PHP中的注册表模式用于创建类
  • 预检OPTIONS请求同源
  • 动态内容未在移动设备上加载

Copyright ©2022 我爱占星 All Rights Reserved.

浙ICP备2022030071号-1

部分图文来自网络,如有侵犯您的版权,请告诉我们删除

友情链接:代码精华