get_the_title takes an int, not an array of ints, and therefore returns a string, not an array of strings.
So just break that bit out into a loop:
$titles="";
foreach ($act_name as $act_name_item) {
$titles .= ($titles ? ',' : '') . get_the_title ($act_name_item);
}
Related Posts:
- How to get an array of menu items from the toolbar?
- If function exists, and array is met, echo function?
- Defining a global array in functions.php?
- How to manage arrays from custom functions stored in functions.php?
- get_post_type() in in_array doesn’t work for some reason
- Simple custom theme option not being saved
- Sorting table function default
- Can’t properly set the_title add_filter to show short_URL
- Get array of metakey in all posts
- Turn get_posts as string into an array for use in theme admin options
- How to echo the value of an array element using a function via a shortcode
- issue with if/elseif in_array inside foreach loop display only one post
- Output comment_author in array
- Override a Post’s URL with Advanced Custom Fields Function
- How to create an array if ’empty’?
- Pass an argument into a function to extract from array
- Combine multiple menus using the filter wp_nav_menu_items
- Featured image on archive page based on post type
- Code executes outside of Loop while same code gives ‘Uninitialized string offset’ notice inside a while loop
- How to assign results to variables?
- Dynamically generated Navigation Diagram using Custom Fields
- Using array page name together with page id to deregister script
- Echo custom field value in shortcode function
- get_footer can’t find any variables set in functions.php
- trouble with passing class method data to outside function
- Rename file after title , one small problem
- Explode Array from Repeatable Custom Field
- Automatically delete posts that aren’t in an array
- plugins_url vs plugin_dir_url
- Get list of years when posts have been published
- Redeclare a function in a child theme
- Is it possible to remove the “standard” post format?
- Do WordPress’ cron’s clean up expired transients?
- How to add first name & last name to default registration form?
- Masking logout URL
- How can I programmatically create “child” pages on theme activation?
- Warning/Notice about functions.php
- How to include one class/instance without using global variables
- Modify search function in WordPress (TwentyTwelve)
- Is checking whether the blog is installed necessary?
- How to add CSS style sheet dynamically in wordpress
- Replace Archive Widget Link Text
- How do I deactivate a plugin for some roles
- How to display more audio file ID3 tags in WordPress
- Searching for content post
- Running CRON on Server with WP Function
- Using separate .php file for functions – how to run on site?
- How to include local menu based on page id?
- How to add custom fields to my custom registration form
- Add Featured image column into wordpress admin on pages AND posts
- How can I change the do_action function in footer (copyright area)
- How to display post content instead of excerpt
- Access Plugin data from Functions.php
- how to call a function only in specific pages and exclude it from other pages
- Which action does wp_update_user triggers?
- Use register_setting() in a loop
- Dynamic dropdown from database table
- Add dynamic links in WordPress custom theme
- WordPress website Rs changed to currency symbol
- Functions in custom theme
- Attempt to change jQuery version caused White Screen of Death
- check if author has published posts in custom post type, then send mail
- paginate_links() don’t properly work in search.php?
- Difference b/w Simple function call & do_action call
- What’s wrong with my use of plugin_url()?
- Hook into a function without a hook?
- Filter yoast canonical add_action priority [closed]
- Should I store functions in separate folder?
- How can I modify the element on all pages?
- AMP – Change rel=”canonical” from functions.php [closed]
- the_password_form functions not working together
- Function filter breaking tag archive menus
- PHP 7.1 | Warning: A non-numeric value encountered in
- Way to redirect all Product Sub Category to its Main category Page?
- Convert multiple logos into the_custom_logo
- Fatal error: Call to undefined function is_even()
- search form leads to 404
- How to hide WooCommerce product title and short description to non logged in users?
- How to loop while adding data to database?
- localize_script but data changes dependent on product ID
- Can we have conditional CSS styling?
- Change function without filter hook
- is_email gives me error
- only update titles of single posts
- Post content overflows on my mobile phone
- How to add javascript code into Divi child theme?
- Using AJAX on frontend: Synchronous XMLHttpRequest deprecation except for admin role
- how can I change the read more link destinations and direct all to the same page?
- Woocommerce custom calculation function
- How to build two WordPress site using two different themes with same database (No ! I am not taking about multisite network)?
- How can I stop the hook from breaking the login/logout function?
- Does WordPress function replace_hello() exists?
- What to do to have access to WordPress functions
- Adding a meta box fields to child theme options page
- How to programmatically GET (to know) which Sidebar (or) which Menu is being used on Different Pages?
- Remove theme, change theme button and WP version on “Right Now” admin dashboard?
- Making an under maintenance page (without using plugins)
- Image width issue in IE [closed]
- comment_post function with js not running
- Problem with removing characters “<” – WpAllImport