winterwisp
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: Get attachment url in large size not workingI figured it out I think.
I don’t fully understand what I did but it works for me and hopefully it helps someone:
<?php global $wp_query; $postid = $wp_query->post->ID; $imageid = get_post_meta(68, 'Slide 1 image', true); ?> <?php $imageUrl = wp_get_attachment_image_src( $imageid, array(640, 320)); echo '<img class="CustomClassGoesHere" src="'; echo $imageUrl[0]; echo '"/> '; ?>Forum: Fixing WordPress
In reply to: Get attachment url in large size not workingThanks so much for clarifying that. It’s definitely pulling the correct image now!
However, it outputs the entire image code and I was wondering if I could add a custom class to the image?
Thanks!
Forum: Themes and Templates
In reply to: Option to choose from logo or blogname?Hi there,
I know where it is. What I mean is I would like to find code similar to this:
<?php if (get_option(‘uwc_logo_header’)) { ?>
<div id=”title”>
“><img />” title=”<?php bloginfo(‘name’); ?>” alt=”<?php bloginfo(‘name’); ?>” />
</div>
<?php } else { ?>
<div id=”title”>
“><?php bloginfo(‘name’); ?>
</div>
<?php } ?>I would really appreciate it if someone could direct me to a tutorial or something that has the code for the header.php and the functions.php
Thanks!