I have made a WordPress theme, and have managed to detect if bbpress is installed or not and I wanted a proper way to see if I was on the forums, list of topics or topic page.
From what I understand the url structures are as such:
- ?post_type=forum
- ?forum=test-2
- ?topic=test
For a very basic install with out the use of sub forms and all that. My question is, would I use GET and or POST or is there some built in wordpress functions I am missing?
I was trying to do:
if('forum' == get_post_type() || 'topic' == get_post_type()){
echo "I am here"; exit;
}
but that didnt work. So....I am wondering am I missing something?