Title: vfree's Replies | WordPress.org

---

# vfree

  [  ](https://wordpress.org/support/users/vfree/)

 *   [Profile](https://wordpress.org/support/users/vfree/)
 *   [Topics Started](https://wordpress.org/support/users/vfree/topics/)
 *   [Replies Created](https://wordpress.org/support/users/vfree/replies/)
 *   [Reviews Written](https://wordpress.org/support/users/vfree/reviews/)
 *   [Topics Replied To](https://wordpress.org/support/users/vfree/replied-to/)
 *   [Engagements](https://wordpress.org/support/users/vfree/engagements/)
 *   [Favorites](https://wordpress.org/support/users/vfree/favorites/)

 Search replies:

## Forum Replies Created

Viewing 3 replies - 1 through 3 (of 3 total)

 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Ultimate Member – User Profile, Registration, Login, Member Directory, Content Restriction & Membership Plugin] Bug after bug….](https://wordpress.org/support/topic/bug-after-bug/)
 *  [vfree](https://wordpress.org/support/users/vfree/)
 * (@vfree)
 * [8 years, 7 months ago](https://wordpress.org/support/topic/bug-after-bug/#post-9684461)
    -  This reply was modified 8 years, 7 months ago by [vfree](https://wordpress.org/support/users/vfree/).
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Ultimate Member – User Profile, Registration, Login, Member Directory, Content Restriction & Membership Plugin] Directory. Decrease size of blocks with user info](https://wordpress.org/support/topic/directory-decrease-size-of-blocks-with-user-info/)
 *  Thread Starter [vfree](https://wordpress.org/support/users/vfree/)
 * (@vfree)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/directory-decrease-size-of-blocks-with-user-info/#post-9611939)
 * Yes,I understood it already.
 * For this I had to play, for example, with properties of class .um-member
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Ultimate Member – User Profile, Registration, Login, Member Directory, Content Restriction & Membership Plugin] Bug after bug….](https://wordpress.org/support/topic/bug-after-bug/)
 *  [vfree](https://wordpress.org/support/users/vfree/)
 * (@vfree)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/bug-after-bug/#post-9600586)
 * Check which type of validation you have selected for the youtube video field.
   Firstly I have the type “website url” and the url sent to the function um_youtube_id_from_url(
   $url) for getting video id wasn`t pure web url, it contains html tags.
    So, I
   created action for custom field validation and put it in function.php:
 *     ```
       add_action('um_submit_form_errors_hook_','um_custom_validate_youtube_url', 998, 1);
       function um_custom_validate_youtube_url( $args ) {
       	global $ultimatemember;
       	$pattern = '/^(http(s)?:\/\/)?((w){3}.)?youtu(be|.be)?(\.com)?\/.+/';
       	$result = preg_match($pattern, $args[video], $matches);
         	if (!$result) {
       		$ultimatemember->form->add_error( 'video', 'This text is not relate to youtube url.' );
       	}
       }
       ```
   

Viewing 3 replies - 1 through 3 (of 3 total)