BCOE&M update styles to AABC

This is how I edited BCOE&M 2.1.18 to suit the AABC styles.  Note this replaces the BJCP 2015 styles with the AABC styles

Timezone

There seems to be a bug that only allows for one timezone at +10 and no option for Melbourne. To fix this I edited the lib\date_time.lib.php

Edit so '10.000'=>'Australia/Melbourne', or whatever timezone you want ( https://www.php.net/manual/en/timezones.australia.php )

'8.001'=>'Australia/Queensland', 	// No DST for this part of Australia
'9.000'=>'Asia/Tokyo',
'9.500'=>'Australia/Darwin',
'10.000'=>'Australia/Melbourne', //changed to whatever timezone you want
'10.001'=>'Australia/Brisbane', 	// No DST for this part of Australia
 '11.000'=>'Asia/Magadan',

I also edited admin\site_preferences,admin.php to match (set "10.000" to be whatever text you want. in this case "Melbourne")

<option value="8.001" <?php if ($row_prefs['prefsTimeZone'] == "8.001") echo "SELECTED"; ?>>(GMT +8:00) Queensland, Perth, the Northern Territory, Western Australia</option>
<option value="9.000" <?php if ($row_prefs['prefsTimeZone'] == "9.000") echo "SELECTED"; ?>>(GMT +9:00) Tokyo, Seoul, Osaka, Sapporo, Yakutsk</option>
<option value="9.500" <?php if ($row_prefs['prefsTimeZone'] == "9.500") echo "SELECTED"; ?>>(GMT +9:30) Adelaide, Darwin</option>
<option value="10.000" <?php if ($row_prefs['prefsTimeZone'] == "10.000") echo "SELECTED"; ?>>(GMT +10:00) Melbourne</option>
<option value="10.001" <?php if ($row_prefs['prefsTimeZone'] == "10.001") echo "SELECTED"; ?>>(GMT +10:00) Brisbane</option>
         

Clubs

There is a large list of clubs in includes\constants.inc.php, but most of the Australian ones are not included. You can either add your clubs to the long list, or delete all of the other clubs an only include the ones you want

$club_array = array("Melbourne Brewers|Melbourne Brewers","Westgate Brewers|Westgate Brewers","Merri Mashers|Merri Mashers","Bayside Brewers|Bayside Brewers","Yarra Valley Brewers|Yarra Valley Brewers","Macedon Ranges Brew Club|Macedon Ranges Brew Club");

Database - Replace BJCP2015 with AABC

To edit the styles I edit lib\common.lib.php  and overwrite the styles table in the database (Note this method overwrites the BJCP2015 styles with the AABC styles)

Step 1) download a copy of the the AABC styles

Click to download >>> Download: AABCstyles.sql 

Step 2) Delete the styles database from your comp database

If you are using phpmyadmin open your database find the 'styles' table > options > Delete the table (DROP)

Step 3) upload the AABCstyles

If you are using phpmyadmin open your database and use the import tab

Step 4) edit the style categories in lib\common.lib.php Replace the BJCP2015 styles with the AABC styles (the styles start somewhere around line 1300)


	if ($_SESSION['prefsStyleSet'] == "BJCP2015") {
	switch ($number) {
		case "01": $style_convert = "Low Alcohol (<4% ABV)"; break;
		case "02": $style_convert = "Pale Lager"; break;
		case "03": $style_convert = "Amber and Dark Lager"; break;
		case "04": $style_convert = "Pale Ale"; break;
		case "05": $style_convert = "American Pale Ale"; break;
		case "06": $style_convert = "Bitter Ale"; break;
		case "07": $style_convert = "Brown Ale"; break;
		case "08": $style_convert = "Porter"; break;
		case "09": $style_convert = "Stout"; break;
		case "10": $style_convert = "Strong Stout"; break;
		case "11": $style_convert = "India Pale Ale"; break;
		case "12": $style_convert = "Specialty IPA"; break;
		case "13": $style_convert = "Wheat & Rye Ale"; break;
		case "14": $style_convert = "Sour Ale"; break;
		case "15": $style_convert = "Belgian Ale"; break;
		case "16": $style_convert = "Strong Ales & Lagers"; break;
		case "17": $style_convert = "Fruit/Spice/Herb/Vegetable Beer"; break;
		case "18": $style_convert = "Specialty Beer"; break;
		case "19": $style_convert = "Mead"; break;
		case "20": $style_convert = "Cider"; break;
		default: $style_convert = $row_style['brewStyle']." (Custom Style)"; break;
			}
		

have you made other changes to your site?  Send them to info@melbournebrewers.org  and I will include them on this list