|
|
|
||||
|
Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact us. |
![]() |
|
|||||||
| Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed. |
|
|
Thread Tools |
|
|
#1 |
|
Confirmed User
Join Date: Jul 2005
Posts: 2,339
|
WordPress Gurus...I need your help please...
Hey all! Long time, no post. I'm having a major issue with the design of a WordPress site I'm working on for a buddy of mine, and I knew if anyone had the answer, it would be the GFY crew.
Actually, this is probably a pretty easy problem that one of you will be able to help with in a matter of minutes...but for me...it's been 2 weeks of trying different things and failing miserably. Ok, here's all the details, the best that I can explain it... The site is www.bizarrolive.com. It's for a wresting promotion that I work for based out of Ohio. We are using Brian Gardner's "Revolution Church 2.0" as the basis of the site, but we have modified it until it bares little resemblance to the original, in both design and functionality. Where the problem comes in is on the main page. "Church" is written so that you have to choose which category and how many posts you want for your top stories...and then it posts them all (how many ever you choose) in one long box on the front page. It looks like this... ![]() What we are wanting to do it make it work more like an actual blog, whereas it will post stories from every category on the front page, and not just from one specific one. We are also wanting to to post each story in it's own box, something like this... ![]() The current code for that section of the page is... Code:
<div class="hpbottom">
<h3>Latest News</h3>
<?php $recent = new WP_Query("cat=1&showposts=1"); while($recent->have_posts()) : $recent->the_post();?>
<?php if( get_post_meta($post->ID, "hpbottom", true) ): ?>
<a href="<?php the_permalink() ?>" rel="bookmark"><img style="float:left;margin:0px 0px 5px 0px;" src="<?php echo get_post_meta($post->ID, "hpbottom", true); ?>" alt="<?php the_title(); ?>" /></a>
<?php else: ?>
<a href="<?php the_permalink() ?>" rel="bookmark"><img style="float:left;margin:0px 0px 5px 0px;" src="<?php bloginfo('template_url'); ?>/images/bigthumbnail.png" alt="<?php the_title(); ?>" /></a>
<?php endif; ?>
<b><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></b>
<?php the_content_limit(350, "[Read more...]"); ?>
<?php endwhile; ?>
</div>
</div>
Code:
<?php get_header(); ?>
<div id="content">
<div id="contentleft">
<div class="postarea">
<?php include(TEMPLATEPATH."/breadcrumb.php");?>
<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
<h1><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h1>
<br />
<?php the_content(__('Read more'));?><div style="clear:both;"></div>
<div class="date">
<div class="dateleft">
<p><span class="time">Filed under <?php the_category(', ') ?> on <?php the_time('F j, Y'); ?></span> by <?php the_author_posts_link(); ?> <?php edit_post_link('(Edit)', '', ''); ?></p>
</div>
<div class="dateright">
<p><span class="icomment"><a href="<?php the_permalink(); ?>#respond"><?php comments_number('Leave a Comment', '1 Comment', '% Comments'); ?></a></span></p>
</div>
</div>
<div style="clear:both;"></div>
<?php endwhile; else: ?>
<p><?php _e('Sorry, no posts matched your criteria.'); ?></p><?php endif; ?>
<p><?php posts_nav_link(' ? ', __('« Previous Page'), __('Next Page »')); ?></p>
</div>
</div>
<?php include(TEMPLATEPATH."/sidebar.php");?>
</div>
<!-- The main column ends -->
<?php get_footer(); ?>
Thanks in advance to anyone that can help us out with this. I have literally been playing with the template for two weeks straight, and can't work out all the little bugs such as this. Any help will be greatly appreciated and you will have my undying gratitude. |
|
|
|
|
|
#2 |
|
So Fucking Banned
Industry Role:
Join Date: Nov 2010
Posts: 3,618
|
![]() Bump for you from The Flying Redneck |
|
|
|
|
|
#3 |
|
So Fucking Banned
Industry Role:
Join Date: Oct 2010
Posts: 673
|
why don't u just use the free suffusion them plugin for wordpress? you can make that do anything you want.
|
|
|
|
|
|
#4 |
|
So Fucking Banned
Industry Role:
Join Date: Oct 2010
Posts: 673
|
use the magazine template in suffusion and you are gold
|
|
|
|
|
|
#5 |
|
Confirmed User
Join Date: Jul 2005
Posts: 2,339
|
|
|
|
|
|
|
#6 |
|
Confirmed User
Join Date: Jul 2005
Posts: 2,339
|
I'm checking it out, and it looks pretty cool. I will probably use it on a future project that I am working on.
As for the Bizarro site, I wanna stay with the template we have now, I just need to get those few little problems worked out. We've spent a lot of time getting the site the way we want it, and I don't want to abandon what we already have done. Thanks though...I do like the Suffusion theme, and like I said, I will definitely be using it on the next site I have to do. |
|
|
|
|
|
#7 |
|
Confirmed User
Industry Role:
Join Date: Jul 2001
Location: 127.0.0.1
Posts: 9,266
|
there
Code:
<div class="hpbottom">
<h3>Latest News</h3>
<?php $recent = new WP_Query(); while($recent->have_posts()) : $recent->the_post();?>
<?php if( get_post_meta($post->ID, "hpbottom", true) ): ?>
<a href="<?php the_permalink() ?>" rel="bookmark"><img style="float:left;margin:0px 0px 5px 0px;" src="<?php echo get_post_meta($post->ID, "hpbottom", true); ?>" alt="<?php the_title(); ?>" /></a>
<?php else: ?>
<a href="<?php the_permalink() ?>" rel="bookmark"><img style="float:left;margin:0px 0px 5px 0px;" src="<?php bloginfo('template_url'); ?>/images/bigthumbnail.png" alt="<?php the_title(); ?>" /></a>
<?php endif; ?>
<b><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></b>
<?php the_content_limit(350, "[Read more...]"); ?>
<?php endwhile; ?>
</div>
</div>
__________________
This post is endorsed by CIA, KGB, MI6, the Mafia, Illuminati, Kim Jong Il, Worldwide Ninjas Association, Klingon Empire and lolcats. Don't mess around with it, just accept it and embrace the truth |
|
|
|
|
|
#8 | |
|
Confirmed User
Join Date: Jul 2005
Posts: 2,339
|
Quote:
|
|
|
|
|
|
|
#9 | |
|
Confirmed User
Industry Role:
Join Date: Jul 2001
Location: 127.0.0.1
Posts: 9,266
|
Quote:
try using just the default simple WP loop, many times coders try to look cool using queries and they mess things up, so maybe that will solve it for you. so Code:
<?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?> <b><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></b> <?php the_content_limit(350, "[Read more...]"); ?> <?php endwhile; ?> <?php endif; ?> and btw, there's a reason why WP has the post thumbnails feature, try using that. It's better, faster and less workload for you
__________________
This post is endorsed by CIA, KGB, MI6, the Mafia, Illuminati, Kim Jong Il, Worldwide Ninjas Association, Klingon Empire and lolcats. Don't mess around with it, just accept it and embrace the truth |
|
|
|
|
|
|
#10 |
|
Confirmed User
Join Date: Jul 2005
Posts: 2,339
|
Hey! Should have posted this sooner...but that worked like a charm. Something sooo simple and I totally overlooked it. I think I'm losing my mojo. lol
Anyway, thank you all so much for the help! It is greatly appreciated!! |
|
|
|
|
|
#11 |
|
. . .
Industry Role:
Join Date: Apr 2007
Location: NY
Posts: 13,724
|
what exactly "worked like a charm", the modified simple loop, or the post thumbnails feature?
|
|
|
|
|
|
#12 |
|
Confirmed User
Join Date: Jul 2005
Posts: 2,339
|
The modified simple loop. Haven't messed with the post thumbnails yet...but I will. Not 100% happy with the site yet, so I'll keep playing with it adding new stuff.
|
|
|
|