Title: strpos() error
Last modified: March 20, 2023

---

# strpos() error

 *  Resolved [nashaden](https://wordpress.org/support/users/nashaden/)
 * (@nashaden)
 * [3 years, 2 months ago](https://wordpress.org/support/topic/strpos-error-3/)
 * Hi,
 * I’ve just installed your plugin and wanted to give it a quick try. I created 
   my first download file, gave it a name and uploaded a pdf file. Upon the ‘publish’
   button click i get:
 *     ```wp-block-code
       Warning: strpos(): Empty needle in /wp-content/plugins/download-monitor/src/FileManager.php on line 433
       ```
   
 * When I got back to the admin area the file is there on the list and everything
   seems fine. I copied the shortcode for that file and pasted it on test page. 
   The link is there but when I press it (both as admin and not) the file that gets
   downloaded is download.html.
 * Here is the link to the test page: [https://konferencje.nowa-energia.com.pl/przykladowa-strona/](https://konferencje.nowa-energia.com.pl/przykladowa-strona/)

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [BSF – Humayon Kabir](https://wordpress.org/support/users/humayonk/)
 * (@humayonk)
 * [3 years, 2 months ago](https://wordpress.org/support/topic/strpos-error-3/#post-16576415)
 * Hi [@nashaden](https://wordpress.org/support/users/nashaden/)
 * Thank you for writing to us.
 * First, please ensure that you are using the latest version of the WPDM plugin.
 * Also, is the error appearing only for PDF files or every other files as well 
   and which please share the exact short code you are using?
 * And, have you added the file using the server browser or from the media library?
   
   We are looking forward to hearing back from you.
 * Regards
 *  [difreo](https://wordpress.org/support/users/difreo/)
 * (@difreo)
 * [3 years, 1 month ago](https://wordpress.org/support/topic/strpos-error-3/#post-16681334)
 * Hi, I have the same problem. Also when trying to download the file it is downloading
   html with the same errors:
 * **Warning**: strpos(): Empty needle in **/wp-content/plugins/download-monitor/
   src/FileManager.php** on line **433**
 * **Warning**: Cannot modify header information – headers already sent by (output
   started at /wp-content/plugins/download-monitor/src/FileManager.php:433) in **/
   wp-content/plugins/download-monitor/src/DownloadHandler.php** on line **433**
 * **Warning**: Cannot modify header information – headers already sent by (output
   started at /wp-content/plugins/download-monitor/src/FileManager.php:433) in **/
   wp-content/plugins/download-monitor/src/DownloadHandler.php** on line **899**
 * **Warning**: Cannot modify header information – headers already sent by (output
   started at /wp-content/plugins/download-monitor/src/FileManager.php:433) in **/
   wp-content/plugins/download-monitor/src/DownloadHandler.php** on line **900**
 * **Warning**: Cannot modify header information – headers already sent by (output
   started at /wp-content/plugins/download-monitor/src/FileManager.php:433) in **/
   wp-content/plugins/download-monitor/src/DownloadHandler.php** on line **901**
 * **Warning**: Cannot modify header information – headers already sent by (output
   started at /wp-content/plugins/download-monitor/src/FileManager.php:433) in **/
   wp-content/plugins/download-monitor/src/DownloadHandler.php** on line **903**
 *  Plugin Contributor [Shafaet Alam](https://wordpress.org/support/users/shafayat-alam/)
 * (@shafayat-alam)
 * [3 years, 1 month ago](https://wordpress.org/support/topic/strpos-error-3/#post-16682721)
 * [@difreo](https://wordpress.org/support/users/difreo/) ,
   You’re using a different
   plugin, not this one.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘strpos() error’ is closed to new replies.

 * ![](https://ps.w.org/download-manager/assets/icon-256x256.png?rev=1561688)
 * [Download Manager](https://wordpress.org/plugins/download-manager/)
 * [Support Threads](https://wordpress.org/support/plugin/download-manager/)
 * [Active Topics](https://wordpress.org/support/plugin/download-manager/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/download-manager/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/download-manager/reviews/)

 * 3 replies
 * 4 participants
 * Last reply from: [Shafaet Alam](https://wordpress.org/support/users/shafayat-alam/)
 * Last activity: [3 years, 1 month ago](https://wordpress.org/support/topic/strpos-error-3/#post-16682721)
 * Status: resolved