Need a quick PHP Help

3 replies
I am using iblogpro theme by page line and i want to have a clickable button in the feature box rather than a simple. Here is the code

HTML Code:
</div>
                                        <div class="ftext">
                                            <?php echo do_shortcode($feature['text']);?>

<?php if($feature['link']):?>

 <a class="featurelink" href="<?php echo $feature['link'];?>">
                    
<?php _e('Click here to Win Free Droid Bionic',TDOMAIN);?></a>
                                                            <?php endif;?>
                                        </div>
How can i place a image in the feature box instead of the link?
#php #short #tip
  • Profile picture of the author phpbbxpert
    Replace
    <?php _e('Click here to Win Free Droid Bionic',TDOMAIN);?>

    with
    <img src="URL to Your Image" alt="
    <?php _e('Click here to Win Free Droid Bionic',TDOMAIN);?>"/>

    Make sure you fill in the src with your images link.
    {{ DiscussionBoard.errors[3391800].message }}
  • Profile picture of the author jaimegm
    phpbbxpert is right, the only thing that I can add about this is that you do not need to be putting <?php for every line, you can just echo your html code.
    {{ DiscussionBoard.errors[3395316].message }}
    • Profile picture of the author phpbbxpert
      Originally Posted by jaimegm View Post

      phpbbxpert is right, the only thing that I can add about this is that you do not need to be putting <?php for every line, you can just echo your html code.
      There is not really a point in that because I believe it is WordPress.
      So there are opening and closing PHP tags everywhere.
      Thats just the way they templated WordPress.
      {{ DiscussionBoard.errors[3396912].message }}

Trending Topics