Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php // don't add this line since it's already in your functions.php file
- function _add_hsd_woo_build_response_html( $html = '', $handler_object ) {
- if ( ! function_exists( 'get_user_blog_url_by_email' ) ) {
- return;
- }
- if ( ! empty( $handler_object->customer_emails ) ) {
- $html .= '<ul class="unstyled">';
- foreach ( $handler_object->customer_emails as $email ) {
- $user = get_user_by( 'email', $email );
- if ( ! is_a( $user, 'WP_User' ) ) {
- continue;
- }
- $html .= '<li>' . get_user_blog_url_by_email( $email ) . '</li>'; // append the url to the html
- }
- $html .= '</ul>';
- }
- return $html;
- }
- add_filter( 'hsd_woo_build_response_html', '_add_hsd_woo_build_response_html', 10, 2 );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement