it is b/c wp_list_pages ECHOES by default. so it echoes before your return happens.
wherever you are defining your $args, set
‘echo’ => FALSE,
see
http://codex.wordpress.org/Function_Reference/wp_list_pages
Related Posts:
- Return HTML Template Page with PHP Function
- How do I use Shortcodes inside of HTML tags?
- WordPress Shortcode and Dynamic CSS
- ob_get_clean returns empty string, ob_get_flush outputs string
- Export User Info to CSV from Front End
- Counting number of posts in a category and its sub categories and displaying result using shortcode
- Add/echo div with Analytics-Code to function in functions.php
- Creating a WordPress shortcode
- How do I hardcode a WordPress shortcode into my theme?
- has_shortcode() – how to detect nested shortcode
- How to return multiples lines in a shortcode?
- How can I default to all WordPress roles when parameter is not included in shortcode?
- Listing and displaying WooCommerce Shipping Zones in the frontend? [closed]
- How do I turn a shortcode into PHP code?
- Need to turn this php into WP shortcode
- How to return a foreach inside a shortcode
- Placing raw HTML inside a WordPress shortcode
- Shortcode content output but not in correct place
- PHP code inside shortcodes
- Append HTML Using Shortcode
- How to display posts by current user in a drop down
- Colon is Missing In My Website Url in WordPress
- Pass php dynamic variable to shortcode
- wordpress 4.4 self hosted video (html5) doesn’t show
- do_shortcode with custom field
- Remove echo from shortcode
- Get URL from shortcode tag
- Multiple do_shortcode in page template
- get_posts works in the page template but not in a shortcode
- How can I include shortcodes within PHP?
- $wpdb returns duplicate posts
- Syntax error in a shortcode function
- Shortcode to find and replace URL
- Could use some help with Shortcodes
- How to put a form with php code into a variable or shortcode?
- Help with WordPress function inside a shortcode
- Short code template + ajax
- WordPress shortcode returns the data before
- Shortcode to embed Edit Account form not working
- Handling PHP/HTML inside the output of a shortcode function
- Need to Modify a WordPress Shortcode with another wordpress shortcode
- Split shortcodes to array of shortcodes
- PHP error with a shortcode: “no suitable wrapper” for file_get_contents
- How to make a conditional statement within $output in shortcodes.php?
- Shortcode for a Series of Elevating Image Files, Excluding a Range?
- Shortcode won’t execute
- Shortcode displaying at the top of the page [duplicate]
- AJAX function not working [closed]
- Can ‘Custom Field’ data be inserted into this Short Code?
- MySQL Query Returns Array () In Shortcode
- Why wp_remote_get() fetches certain web pages while it doesn’t work for my localhost?
- How to exclude labels from certain categories in a shortcode?
- Set document title through shortcode plugin
- Trying to call dynamic content into a 3rd party shortcode
- Shortcode in Shortcode/HTML Graphics and Pictures
- Why is the current page loaded in the pop-up window and not the specified one?
- How to search order using database frontend short code WordPress
- How do I reopen the (Popup Maker) after entering the correct password for a password protected page?
- Not able to remove caption shortcode from the content
- How to add a shortcode which runs a .php file for the current post
- Block error message in foreach loop when looping through ACF field
- Get title of page containing post grid within the posts
- PHP multiple forms, same page, isset($_POST[]) not working?
- Shortcodes not processing inside post content
- Gravity Forms: How to add PHP function to confirmation conditional shortcode?
- wpdb->query returns different value to phpMyAdmin
- shortcodes, custom php and their errors
- I want to hide “sold by” on certain pages with id page 43
- Echo short code syntax
- How to add a PHP scripts into WordPress
- Why my Ajax events are no longer detected after dynamic change of shortcode content
- Multiple Arrays for Custom Post Query using Boostrap accordions and ACF repeater fields
- Replacing entire tag with shortcode – JavaScript [duplicate]
- Offset with ajax load more posts duplicates
- Get posts by id using shortcode
- Shortcode just with a php code
- Shortcode in a $output statement
- Need help with PHP functions
- Custom fields changes the formatting of metabox input
- Shortcode is not outputting all of the desired markup
- Contact form field in wordpress menu
- Serializing URL via wp add_shortcode to auto select from option list onload
- php string inside shortcode does not work
- Limit the number of successful logins
- Shortcodes (with a space) added to php Sample
- Show contact 7 form in popup
- How can I put a custom field as the link of a button shortcode?
- Custom field within shortcode
- Problem using explode inside add_shortcode() callback funciton [closed]
- Php inside the shortcode is getting commented
- Shortcode to include PHP file, pass various parameters to include?
- Display Current Time using shortcode
- Set variable in javascript and using in my shortcode
- How to create shortcode of this PHP code
- HTTP 500 Error after Creating Shortcode
- How to edit a widget code?
- How to execute a shortcode within a custom field?
- Calling a function via a shortcode in javascript
- Nav Menu Short code Not working When non Login
- Automatically populating a date parameter within a shortcode