Jump to content

HELP! Time sensitive


tomstirling1979

Recommended Posts

I have taken over a wordpress site that a web developer set up and he is no longer working with me so I cant get his help with it, I have a custom front page that has been pulling press releases that where posted previously and categorized as "press" I was asked to add a blog which I did by categorizing the post as "blog"

 

In a nutshell, I now need the front page code to pull a mixture of both the "press" and "blog" each category has a numerical id so blog is 7 and press is 3

 

This is the current code that is in the page

<?php query_posts('category_name=press&showposts=10&offset=0'); ?>

 

I looked up wordpress support for this, and found this

query_posts(array('category__in' => array(2,6)));

 

How can I integrate this if possible with the top line so it pulls the newest posts from both categories? Any suggestions could REALLY help me out!

 

Thanks!

 

 

Link to comment
Share on other sites

Do I need to give more information, I am a total newbie to php this "complex" - The only thing I use it for on a regular basis is include/require files and thats straight forward, I feel I just dont have the synthax down here for this to work the way I need it to.

 

And again, any help at all would be really appreciated. Sorry for being impatient, but as I said its a time sensitive issue and help sooner than later can make all the difference. i normally wouldn't try and bump my post up.......

Link to comment
Share on other sites

Ok, this ALMOST did exactly what I wanted it to do....

 

<?php query_posts(array('category__and&showposts=10&offset=0' => array(3,7))); ?>

 

The feed did show a mix of the 2 categories, BUT! - it didn't show any more than the most recent and the next one, thr part where I have it saying showposts=10 didnt seem to register. Any ideas?

 

:'(

 

 

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.