Jones 177 Share Posted February 21, 2019 Putting the final touch on miniprofiles for the WiP site. Finish line is so close now. Just wondering how to set it up so I can display the alliance and department in their appropriate colors? I know ',$message['member']['group'] will get me the characters Department, and I know how to set it to the right color by giving it an inline style that calls on ['member']['group_color']. But I would like to be able to do the same for their alliance too. It's an HP themed site so our Alliances are Magical and Muggle, each with same 3 departments just divided by color. Remembering which colors are for wizards and which are for muggles will take time for new members though so I would like to have both displayed for quick reference. Thanks so much, @Arceus. You've been such a huge help getting this thing pulled together. Even aside from your awesome character mod. Link to comment Share on other sites More sharing options...
Arceus 1,082 Share Posted February 21, 2019 All the way at the bottom of Load.php, there should be this function: acmLoadCharacterContext($id_character) What you want already loads. You just need to output it by adding to the $character array. 'alliance' => $row['alliance_name'], 'department' => $row['department_name'], This is the function that controls what loads and is available for characters in Display.template. You will have to do an empty check on it or your error log will fill up with PHP warnings, as regular members won't have these keys in their memberContext array. ',(!empty($message['member']['alliance']) ? $message['member']['alliance'] : ''),' Something like that. 1 I am the darkness, always watching, always listening, ALWAYS THERE. (If you're interested in Plain of Ice, message me, it's private. Bleach site, non-canon.) Link to comment Share on other sites More sharing options...
Jones 177 Author Share Posted February 21, 2019 Worked perfectly thanks so much. I also ended up adding alliance color to the array, going off the way you did group_color. 'alliance_color' => ((!empty($row['alliance_color']) ? $row['alliance_color'] : '')), Link to comment Share on other sites More sharing options...
Recommended Posts