Support » Fixing WordPress » Categories in a PHP include

  • Hi – I was wondering if anyone knows if it’s possible to link to a page where one weblog category would be displayed as a PHP include. I tried this <? include(“wp/index.php?cat=2”); ?> which obviously didn’t work, so does anyone know of another way?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Zahra,
    I’m not sure I understand what you’re trying to do…Is this page going to exist somewhere outside your normal blog? Perhaps using a different template?
    You could put the following at the top of the page:
    just under $blog = 1;
    $cat = 2; // add this line
    Not sure if that’s what you’re looking for, though…

    I’m not sure either. :/ Basically i’m using a php include to display my blog on my site: <? inclue(“wp/index.php”); ?>. I’m trying to make a link to a page that will display a category of my blog with an include, if possible. I’ll try that, though.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Categories in a PHP include’ is closed to new replies.