wenjay tew

Forum Replies Created

Viewing 25 posts - 51 through 75 (of 86 total)
in reply to: wpdm_onstart_download – download email notification #190873

wenjay tew
Participant

add_action("wpdm_before_email_download_link", "your_function", 10, 2);
function your_function($post, $package){
    $package_data = get_post( $package['ID'] );
    $headers = 'From: Site Name <noreply@sitename.com>' . "\r\n";
    $headers .= 'Content-type: text/html' . "\r\n";

    // Set the time zone to Asia/Singapore
    date_default_timezone_set('Asia/Singapore');
    $current_date_time = date('Y-m-d h:i:s A');

    $message = '<html><body>';
    $message .= '<table style="border: 1px solid #ccc; background-color: #f5f5f5; border-collapse: collapse;">';
    $message .= '<tr><td style="font-weight: bold; border: 1px solid #ccc;">Downloader Name:</td><td style="border: 1px solid #ccc;">' . $post['name'] . '</td></tr>';
    $message .= '<tr><td style="font-weight: bold; border: 1px solid #ccc;">Downloader Email:</td><td style="border: 1px solid #ccc;">' . $post['email'] . '</td></tr>';
    $message .= '<tr><td style="font-weight: bold; border: 1px solid #ccc;">Package Title:</td><td style="border: 1px solid #ccc;">' . $package_data->post_title . '</td></tr>';
    $message .= '<tr><td style="font-weight: bold; border: 1px solid #ccc;">Downloader\'s IP:</td><td style="border: 1px solid #ccc;">' . $_SERVER['REMOTE_ADDR'] . '</td></tr>';
    $message .= '<tr><td style="font-weight: bold; border: 1px solid #ccc;">Downloaded Time:</td><td style="border: 1px solid #ccc;">' . $current_date_time . '</td></tr>';
    $message .= '</table>';
    $message .= '</body></html>';

    wp_mail(get_option("admin_email"), "Potential Leads - Visitor downloaded a file from the NSW website.", $message, $headers); 
}

View post on imgur.com

Hi thanks for your guidance im able to use your code to modify it helps alot.
This code above already works flawlessly, i have change to wpdm_before_email_download_link but i wanted to add “company” using advanced customfield. it didnt work, i wanted to add extra 1 info to the email notification.

however i use the following code to add “company” it seems doesnt work:

$company = wpdm_acf([acf_EmailLock_Company], 'EmailLock/Company');
    $message .= "Company: " . $custom_data . "<br>";

not sure how to add that in.. could you guide me?

in reply to: wpdm_onstart_download – download email notification #190867

wenjay tew
Participant

Hi, im trying to add custom field “company” into the email notification

View post on imgur.com

it doenst work. the code i copy to put on my $message is wpdm_acf([ID],’EmailLock/Company’
can you guide me?

in reply to: wpdm_onstart_download – download email notification #190865

wenjay tew
Participant

what if i wanted to add “Name” and “company” (made with custom_form_fields)” as following the email notification came empty

    $message .= "Name: " . $post['name'] . "<br>";
    $message .= "Company: " . $custom_data . "<br>";

these 2 fields info doenst send to my email.
is my code wrong?

in reply to: wpdm_onstart_download – download email notification #190855

wenjay tew
Participant

R u able to provide me guidance to do this?

in reply to: Play video #190454

wenjay tew
Participant

Thank man.. didnt know it was that simple.

in reply to: Play video #190450

wenjay tew
Participant
This reply has been marked as private.
in reply to: Play video #190444

wenjay tew
Participant
This reply has been marked as private.
in reply to: Play video #190397

wenjay tew
Participant
This reply has been marked as private.
in reply to: Play video #190383

wenjay tew
Participant

View post on imgur.com

hi it doesnt work

in reply to: Play video #190382

wenjay tew
Participant

can u give an example of it?

in reply to: Play video #190381

wenjay tew
Participant

does this protect from hotlinks?


wenjay tew
Participant
This reply has been marked as private.

wenjay tew
Participant
This reply has been marked as private.

wenjay tew
Participant
This reply has been marked as private.

wenjay tew
Participant
This reply has been marked as private.

wenjay tew
Participant

Hi is the WordPress Download Manager Special Pack included this WPDM webhook? i have to buy that separated?

in reply to: Hi SPF neutral when send file via email lock #182941

wenjay tew
Participant

one of our client still reported going into spam folder.
i suspect is the SPF record problems.

https://app.screencast.com/nWF3itISf2Ms4

how to I make it pass?

in reply to: Hi SPF neutral when send file via email lock #182934

wenjay tew
Participant
This reply has been marked as private.
in reply to: Hi SPF neutral when send file via email lock #182930

wenjay tew
Participant
This reply has been marked as private.
in reply to: Hi SPF neutral when send file via email lock #182928

wenjay tew
Participant
This reply has been marked as private.
in reply to: Hi SPF neutral when send file via email lock #182925

wenjay tew
Participant

what should i do? how to adjust?

in reply to: Hi SPF neutral when send file via email lock #182921

wenjay tew
Participant
This reply has been marked as private.

wenjay tew
Participant
This reply has been marked as private.

wenjay tew
Participant
This reply has been marked as private.

wenjay tew
Participant

no i wanted to hide it from the public not specific user only..am I able to do it?

Viewing 25 posts - 51 through 75 (of 86 total)