Pass parameters to PDF
-
Hi. I’m trying to pass a variable called pagina to the PDF (from single product page), but when I click on the submit button, it redirects me to cart with message: “Invalid nonce. Unable to process PDF for download.” and the URL is like this: “…/carrinho/?cart-pdf=1&_wpnonce=dc6f3b2f5c&pagina=2”. I know this is custom, but can you help me? Thanks!
<form id="orcamento-single-product-form" method="GET" action="<?php echo wc_get_cart_url(); ?>"> <button id="enviar-form-personalizacao" type="submit">ENVIAR</button> <input type="text" readonly="readonly" name="cart-pdf" value="1" /> <?php wp_nonce_field( -1, '_wpnonce', false, true ); ?> <input type="text" readonly="readonly" name="pagina" value="2" /> </form>
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘Pass parameters to PDF’ is closed to new replies.