Support » Plugins » Including Files Incrementally Based on Categories

  • I’ve looked around for an answer, but I can’t find anything that seems to do the trick.

    I would like to include a file in a single post page based on the category. In addition, I’d like to include a new file every time a new post is made.

    For example, I’d like to put a folder on my server with the files I want to include: file-1.htm, file-2.htm, file-3.htm, etc. When I make the first post to that category, I would like it to automatically include file-1.htm. When I make the second post to that category, I’d like it to automatically include file-2.htm, etc.

    I have the problem of templates for different categories worked out, so I can simply insert the php code that I need for that category into that template file. However, I don’t know what the php code should be.

    How can you get the next file in the folder for the next post in the category? Doing it by Post ID wouldn’t seem to work because you never know what the next post in certain category will be. Is there some other identifier in the category that would label it as 1st, 2nd, 3rd, etc.?

    Thanks for any suggestions.

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘Including Files Incrementally Based on Categories’ is closed to new replies.