shortcode with $atts with strange results

The functions you have above don’t use the id att at all. This might be what you want, but I’m not 100% sure what you’re going for. function show_homepage_banner_function($atts) { $atts = shortcode_atts( array(‘id’ => NULL), $atts ); $content=””; global $wpdb; $upload_url=””; $upload_dir = wp_upload_dir(); $target_dir = $upload_dir[‘basedir’]; $upload_url = $upload_dir[‘baseurl’].’/banners/’; $query = “SELECT * … Read more

Display post structure in function

Try running the post content through the do_shortcode() function before displaying it. $args = array(‘posts_per_page’ => -1,’post_type’ => ‘edge’); $edge_array = get_posts( $args ); foreach($edge_array as $e): echo do_shortcode($e->post_content); endforeach;

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)