• I’d really like to remove the text fields, as we have built out custom templates. But the plugin crashes when they are blank. I tried a work around editing the php – but it didn’t work – really hope you can help!

    //Manage voucher title. If Voucher title is "voucher" the title is not visible on voucher. (by polecat)
    		if($voucher->name == "voucher") {
    			$vouchername = " ";
    		} else
    		{
    			$vouchername = $voucher->name;
    		}
    		//This code $voucher->name must be replace into stripslashes function to set the original code (by polecat)
    		// print title
    		$pdf->writeHTML( stripslashes( $vouchername ), $ln=true, $fill=false, $reseth=false, $cell=false, $align='C');
    
    		//Manage voucher text. If Voucher text is "hide" the text is not printed on voucher. (by polecat)
    		if($voucher->text == "hide") {
    			$vouchertext = "";
    		} else
    		{
    			$vouchertext = $voucher->text;
    		}
    		// print text
    		$pdf->Write( 5,  stripslashes( $vouchertext ), $link = '', $fill = 0, $align = 'C', $ln = true);		
    
    		//Manage voucher terms. If Voucher text is "hide" the text is not printed on voucher. (by polecat)
    		if($voucher->terms == "hide") {
    			$vouchertext = "";
    		} else
    		{
    			$vouchertext = $voucher->terms;
    		}
    		// print text
    		$pdf->Write( 5,  stripslashes( $vouchertext ), $link = '', $fill = 0, $align = 'C', $ln = true);

    https://wordpress.org/plugins/voucherpress/

Viewing 1 replies (of 1 total)
  • Plugin Author Chris Taylor

    (@mrwiblog)

    It’s probably best to wait for version 2.0 of VoucherPress which is much more flexible in terms of the voucher content. That version is currently being tested and should be available in the next couple of months.

Viewing 1 replies (of 1 total)
  • The topic ‘Removing Text Fields’ is closed to new replies.