• I want to add a unique number in contact-form-7, user will receive a notification email and pdf file attachments after submited the form.

    I use the “send-pdf-for-contact-form-7 plugin” to create pdf files.
    I tried using a simple php function to generate a unique number.

    /* Generate Quote Ticket */
    function genTicketString() {
        $length = 8;
        $characters = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ";
        for ($p = 0; $p < $length; $p++) {
            $string .= $characters[mt_rand(0, strlen($characters)-1)];
        }
        return $string;
    }
    add_shortcode('quoteticket', 'genTicketString');

    I got code from This link

    [dynamictext ticket “quoteticket”] The shortcode works well on the form but doesn’t work on pdf file using “send-pdf-for-contact-form-7 plugin”

    please help .

    https://www.ads-software.com/plugins/contact-form-7-dynamic-text-extension/

  • The topic ‘not work in "send-pdf-for-contact-form-7 plugin"’ is closed to new replies.