public static function cp_mp_order_notification_subject($subject, $order) { if (cp_get_order_course_id($order->ID)) { return coursepress_get_mp_order_email_subject(); } else { return $subject; } }
<td> <input type="text" name="option_mp_order_from_email" value="<?php echo esc_attr(coursepress_get_mp_order_from_email()); ?> "/> </td> </tr> <tr> <th><?php _e('E-mail Subject', 'cp'); ?> </th> <td> <input type="text" name="option_mp_order_email_subject" value="<?php echo esc_attr(coursepress_get_mp_order_email_subject()); ?> "/> </td> </tr> <tr> <th><?php _e('E-mail Content', 'cp'); ?> </th> <td> <p class="description"><?php _e('These codes will be replaced with actual data: CUSTOMER_NAME, BLOG_NAME, LOGIN_ADDRESS, COURSES_ADDRESS, WEBSITE_ADDRESS, COURSE_ADDRESS, ORDER_ID, ORDER_STATUS_URL', 'cp'); ?> </p>