---
description: >-
  http://www.prowebguru.com/2021/02/wordpress-menu-link-remove-title-attribute/#.Yo2Y9XbP1D8
---

# Thêm thuộc tính vào menu, add attributes, Remove attributes (ok)



![co](https://2370029328-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LWPtKFbhw0XehxVuoiZ%2Fuploads%2Fbnh2u2D9QO6nUnwqGAem%2FScreenshot_1.png?alt=media\&token=af98c758-bf51-4fd6-8850-ae3c68f60c41)

C:\xampp\htdocs\tiah\wp-content\themes\gutener-child\functions.php

```
function add_specific_menu_atts( $atts, $item, $args,$depth ) {
    $atts['data-scroll-nav'] = $item->ID;
    unset($atts['title']);
    return $atts;
}
add_filter( 'nav_menu_link_attributes', 'add_specific_menu_atts', 10, 4 );

```
