BetaONE will rise again!

BetaONE will rise again! (http:\\b1.hcanet.com\forum/index.php)
-   Web Development (http:\\b1.hcanet.com\forum/forumdisplay.php?f=50)
-   -   Theme Selector In The Main Page ? (http:\\b1.hcanet.com\forum/showthread.php?t=11754)

Bads 15th May 04 04:15 PM

Hi,

I want to put a "theme selector" in the main page of my forum ;) I don't have a news page just the main forum

How can I do that please ?

Thanks

Zone-MR 15th May 04 06:05 PM

This is how we do it:

Code:

&nbsp; &nbsp; &nbsp;<form>
 &nbsp; &nbsp; &nbsp; <select name='u_skin' class='forminput' onchange="window.location='/?act=UserCP&CODE=07&u_language=en&u_skin='+this.value">
 &nbsp; &nbsp; &nbsp; <?
 &nbsp; &nbsp; &nbsp; $DB->query("SELECT uid, sid, sname FROM ib_beta_skins WHERE hidden <> 1");
 &nbsp; &nbsp; &nbsp; if ( $DB->get_num_rows() )
 &nbsp; &nbsp; &nbsp; &nbsp;{
 &nbsp; &nbsp; &nbsp; &nbsp;while ( $s = $DB->fetch_row() )
 &nbsp; &nbsp; &nbsp; &nbsp; {
 &nbsp; &nbsp; &nbsp; &nbsp; $skin_select .= $s['sid'] == $ibforums->member['skin'] ? "<option value='{$s['sid']}' selected>{$s['sname']}</option>" : "<option value='{$s['sid']}'>{$s['sname']}</option>";
 &nbsp; &nbsp; &nbsp; &nbsp; }
 &nbsp; &nbsp; &nbsp; &nbsp;$skin_select .= "</select>";
 &nbsp; &nbsp; &nbsp; &nbsp;}
 &nbsp; &nbsp; &nbsp; print("$skin_select");
 &nbsp; &nbsp; &nbsp; ?>
 &nbsp; &nbsp; &nbsp;</form>

You'd just need to find the right place to stick that code, to get the selector to appear where you want it.

Bads 15th May 04 06:14 PM

Thanks Zone-MR ;)

I have to paste this code in the index ?

I will try in my local forum before ;)

Bads 15th May 04 07:38 PM

I can't find where to put this code :blink:

robinwilson16 9th Jun 04 09:12 AM

Did you try putting it in the header in skin_global
Not sure if that php will work in a skin file though


All times are GMT +1. The time now is 10:46 PM.

Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.