• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

Download Monitor & Manager Plugin

Simple Download Monitor & Manager for WordPress

  • Home
  • Documentation
  • Addons/Extensions
  • Login
    • Sign In
    • Edit Profile
    • My Downloads
  • Support
    • Tutorials
    • Forum
    • Forum Search
    • Forum Login
    • Forum Registration
  • Contact Us
You are here: Home

ohwowmarketing

  • Profile
  • Topics Started
  • Replies Created
  • Engagements
  • Favorites

Forum Replies Created

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • August 15, 2019 at 3:33 am in reply to: Request Timeout when downloading 10mb PDF filesize #1299
    ohwowmarketing
    Participant

    No. There is no configuration about secure downloads addon.

    We have tried to reduce the pdf filesize down to 1.9mb and it is still registering the filesize to 374 bytes in the debug log.

    Please do remember that I customize your code into my own hooks to make it able to work.
    https://simple-download-monitor.com/forums/topic/squeeze-form-downloading-pdf-result-of-zero-bytes/.

    `2019-08-15 01:45:55: [SUCCESS] Making API call to subscribe user to list ID: 88a5060313
    2019-08-15 01:45:55: [SUCCESS] Mailchimp sign-up API query successful.
    2019-08-15 01:45:55: [SUCCESS] Notification email after download feature is enabled.
    2019-08-15 01:45:55: [SUCCESS] Notification email sent to: mark@#########.com
    2019-08-15 01:45:55: [SUCCESS] File Name: ##########.com/wp-content/uploads/2019/06/9701-#######-Brochure.pdf File Size:374 File Ext:pdf File Header:application/pdf`

    April 30, 2019 at 11:28 pm in reply to: open download in new window #1092
    ohwowmarketing
    Participant

    I agree on this.

    Manually done this to one of my project, using cookie (manually edit the plugin script) and pass it with parameter, use get variable and set condition to display “Thank you… etc”.

    I hope this should be part of the program.

    April 17, 2019 at 10:44 am in reply to: Squeeze Form – Downloading PDF result of Zero Bytes #1077
    ohwowmarketing
    Participant

    ok, so this is the final code that is completely working.

    
    $parsed = parse_url( get_post_meta($postid, 'sdm_upload', true) );
    $url    = dirname( $parsed [ 'path' ] ) . '/' . rawurlencode( basename( $parsed[ 'path' ] ) );
    
    // Combine the absolute path and the attachment url
    $filePath = ABSPATH . substr($url, 1);
    
    // Get the attachment file-size
    $size = filesize($filePath);
    
    // Temporary disable due to error
    // $headers = get_headers($file, 1);
    // $fsize = $headers['Content-Length'];
    

    here’s the code will look like after the provision codes.

    
    header('Content-Length: ' . $size);
    readfile( $filePath );
    

    Hope this will help others.

    April 12, 2019 at 3:50 am in reply to: Squeeze Form – Downloading PDF result of Zero Bytes #1073
    ohwowmarketing
    Participant

    Hello.

    It’s been 4 and half months after I open this thread. My bad I didn’t provide yet any access to the author. However, it is bad as well that I didn’t see if they’ve manage to check this error/issue.

    Anyway, upon debugging “in my case” today April 12, readfile() is failing to give a 200 ok code to the header in-which resulting http/1.1 403 forbidden to the attached PDF file.

    `
    Warning: readfile(http://localhost:8888/wp-content/uploads/2019/01/Brochure.pdf): failed to open stream: HTTP request failed! HTTP/1.1 403 Forbidden in /Users/mac/Sites/sandbox/wp-content/plugins/sdm-squeeze-form/sdm-sf-shortcodes.php on line 281
    `

    Base on my findings, readfile() throwing 403 to the pdf attachment which ending-up zero-byte. I tried to create small code inside the sdm-sf-shortcodes.php

    `
    $parsed = parse_url( get_post_meta($postid, ‘sdm_upload’, true) );
    $url = dirname( $parsed [ ‘path’ ] ) . ‘/’ . rawurlencode( basename( $parsed[ ‘path’ ] ) );

    $filePath = ABSPATH . substr($url, 1);
    `

    then I rewrite the readfile( $file ) var into readfile( $filePath );

    Overall, I am still open for some comments if they’ve manage to fix this issue. Else, i will mark this as resolved, if I can prove that the code I am using is the solution to this case.

    Regards,

    November 22, 2018 at 5:27 am in reply to: Squeeze Form – Downloading PDF result of Zero Bytes #853
    ohwowmarketing
    Participant

    As your suggestion, please watch the video. drive.google.com/open?id=1VBzlkoUtNUASF9mSIHmr5Pz-83fVD_rK

    Actually, my theme does heave header and footer. Since it was custom theme (and fresh installed) made by me to my client, it was more optimized than the usual.

    November 21, 2018 at 3:14 am in reply to: Squeeze Form – Downloading PDF result of Zero Bytes #851
    ohwowmarketing
    Participant

    Please watch this video i made… drive.google.com/open?id=1v3wtWJqMNVDRtCfGtxJnsHQ4ASpcLfj2

    Regarding page, I will create one for you guys.

    November 16, 2018 at 12:16 am in reply to: Connect Squeeze Form to Email Notification #846
    ohwowmarketing
    Participant

    Hi Chanel… Yeah I thought it was.. but it wasn’t. I manually configure and hooked it. I don’t know why. Out of frustration, I break the plugin and do all stuff to make it working.

    The process i can see from the debug:

    [SUCCESS] Sqeeze form submitted. Processing submission.
    [SUCCESS] Mailchimp signup is enabled.
    [SUCCESS] Making API call to subscribe user to list ID: 00000000
    [SUCCESS] Mailchimp sign-up API query successful.

    i dont see this:

    [SUCCESS] Notification email after download feature is enabled.

    Update:
    During the time I am testing the SF download shortcode, i tried to use the SDM shortcode and it works, it sends me an email… then when I go back to SF download, i don’t receive any email notification.

    November 15, 2018 at 7:45 pm in reply to: Fatal Error: SDM Debug not found #842
    ohwowmarketing
    Participant

    It looks like a charm.. and it is working back fine now. I don’t know why.

  • Author
    Posts
Viewing 8 posts - 1 through 8 (of 8 total)

Primary Sidebar

Featured Addons

  • Squeeze Form Addon
  • Hidden Downloads Addon
  • Amazon S3 Integration

Support Links

  • Support Forum

Search

Featured Plugin

WP Express Checkout Plugin

Start managing and tracking your file downloads with the simple download monitor plugin. Download Now

Copyright © 2025 | Simple Download Monitor | A member of the Tips and Tricks HQ family.