|
|
Joined: Apr 2004
Posts: 52
journeyman
|
|
journeyman
Joined: Apr 2004
Posts: 52 |
I would like to display different things in an island depending upon which forum (or the main index) is being displayed.
Is there a recommended way of doing this? I can, of course, look at the URL, but I was wondering if something is built-in for this purpose?
Chuck
|
|
|
|
|
Joined: Jun 2006
Posts: 3,839 Likes: 1
Carpal Tunnel
|
|
Carpal Tunnel
Joined: Jun 2006
Posts: 3,839 Likes: 1 |
It would need something like... if url contains Board/2/ then display this code... Problem is as soon as you go to showflat then the board number is lost in the URL. If you find a decent solution let me know 
|
|
|
|
|
Joined: Jun 2006
Posts: 16,532 Likes: 150
|
|
Joined: Jun 2006
Posts: 16,532 Likes: 150 |
if($_GET["board"] == 2) { echo("board 2 content"); }
I have no clue if that would work, but hey thats how you take a variable from the url in php  .
|
|
|
|
|
Joined: Apr 2004
Posts: 52
journeyman
|
|
journeyman
Joined: Apr 2004
Posts: 52 |
Seems to me that, given that the board is not always in the URL, the only way to do it is from the post number. That involved database access which is annoying (and at least a little time consuming since it's an extra database access per page). It would be cool if there were some environment-like variable available since someone has that information already.
|
|
|
|
|
Joined: Jun 2006
Posts: 16,532 Likes: 150
|
|
Joined: Jun 2006
Posts: 16,532 Likes: 150 |
True, you'd have to look up the post number to see what forum it belonged to...
|
|
|
|
|
Joined: Apr 2004
Posts: 52
journeyman
|
|
journeyman
Joined: Apr 2004
Posts: 52 |
Someone suggested a custom header for each forum that set a variable that could be accessed by the Island. I could not get this to work, but perhaps there is some global environment that can be set?
|
|
|
|
|
Joined: Jun 2006
Posts: 3,839 Likes: 1
Carpal Tunnel
|
|
Carpal Tunnel
Joined: Jun 2006
Posts: 3,839 Likes: 1 |
I haven't tried a custom header yet - but is it tied to the posts as well?
Could we not tell which header was in use and then use the correct box.
Maybe it would be better to have custom margins for each forum, then the boxes could be tailored for those.
|
|
|
|
|
Joined: Jun 2006
Posts: 16,532 Likes: 150
|
|
Joined: Jun 2006
Posts: 16,532 Likes: 150 |
I think board is declaired as a get in the thread list, and as a post in the thread/flat view; should that help anything 
|
|
|
|
|
Joined: Jun 2006
Posts: 3,839 Likes: 1
Carpal Tunnel
|
|
Carpal Tunnel
Joined: Jun 2006
Posts: 3,839 Likes: 1 |
How much will you charge us for this 
|
|
|
|
|
Joined: Jun 2006
Posts: 16,532 Likes: 150
|
|
Joined: Jun 2006
Posts: 16,532 Likes: 150 |
Frankly I woudlnt' know where to start, so you'd be looking at research + dev time 
|
|
|
|
1 members (Havenofsobriety),
156
guests, and
140
robots. |
|
Key:
Admin,
Global Mod,
Mod
|
|
|
|