Site icon Hip-Hop Website Design and Development

Allow users to give a dashboard widget a custom name using ACF

I want to use ACF (and CPT) to allow users to give a custom name to an admin dashboard widget from a settings page. In the below code, a widget would be created called "my title". If the acf field on the settings page is ‘my_widget_name’ – how do I add it to my code so it shows up in the users backend dashboard? CPT would be "dashboard_feeds" if that is important.

add_action( 'wp_dashboard_setup', 'feed_dashboard_add_widgets' );
  

  function feed_dashboard_add_widgets() {
     wp_add_dashboard_widget( 'dw_dashboard_widget_feed', ( 'my title' ), 'my_cool_widget');
 }