Hi @sukalo
Converting the quote description?field into a rich Textbox is not possible as it’s a WordPress excerpt field and meant to be shown that way.
but you can create a custom description field using the below code.
You can add this code to your child theme functions.php file or you can use a plugin like code snippet.
add_action( 'add_meta_boxes', 'adding_a_new_metaabox' );
function adding_a_new_metaabox() {
add_meta_box('html_myid_31_section', 'Quote Description', 'gd_buddy_output_func', 'wpi_quote' );
}
function gd_buddy_output_func( $post ) {
//so, dont ned to use esc_attr in front of get_post_meta
$valueeee2= get_post_meta($_GET['post'], 'gd_buddy_quote_description' , true ) ;
wp_editor( htmlspecialchars_decode($valueeee2), 'gd_buddy_quote_description_field', $settings = array('textarea_name'=>'gd_buddy_quote_description') );
}
function save_my_post_data( $post_id ) {
if (!empty($_POST['gd_buddy_quote_description'])) {
$datta = htmlspecialchars($_POST['gd_buddy_quote_description']);
update_post_meta($post_id, 'gd_buddy_quote_description', $datta );
}
}
add_action( 'save_post', 'save_my_post_data' );
/**
* Display invoice description before line items.
*
* @param WPInv_Invoice $invoice
*/
function getpaid_gd_buddy_quote_description( $invoice ) {
$quote_id = $invoice->get_id();
if ( !empty( $quote_id ) ) {
$content = html_entity_decode( get_post_meta( $quote_id, 'gd_buddy_quote_description' , true ) );
echo wp_kses_post( wpautop( $content ) );
}
}
add_action( 'getpaid_invoice_line_items', 'getpaid_gd_buddy_quote_description', 100 );
add_action( 'wpinv_email_billing_details', 'getpaid_gd_buddy_quote_description', 100 );
This code will add a new description field inside quotes and you can add html in it.
https://ibb.co/4KwBKY0
Regards