Treehouse: Grow your CSS skills. Land your dream job.

WordPress Link

  • # October 22, 2010 at 3:10 pm

    Hi, I am using wordpress to create a site and basically I am trying to display a list of bikes for sale using a custom post type and catagoies. I want the image of the bike to be a link to the site of the manufacturer but for some reason instead of going to for example it goes to I can’t work out why though, this is my code:

    $loop = new WP_Query(array('post_type' => 'Bikes', 'posts_per_page' => 10));
    while ( $loop->have_posts() ) : $loop->the_post();

    $custom = get_post_custom($post->ID);
    $bike_url = $custom["bike_url"][0];
    $bike_img = $custom["bike_img"][0];
    $bike_price = $custom[0];


    < ?php the_title(); ?>

    "><?php echo $bike_url ?/>
    < ?php the_content();
    echo $bike_price;
    echo $bike_url; ?>


    # October 22, 2010 at 3:26 pm

    What are the code tags now? the post won’t format correctly

    # October 22, 2010 at 3:44 pm

    Code tags are still



Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.