Die Hard Gaming Posted December 9, 2013 Share Posted December 9, 2013 So I have this code <center> <script language="JavaScript" type="text/javascript"> function redirect(site){ window.location= site } </script> <select name="report_input" onchange='redirect(this.value)'> <option value=''>Select Report:</option> <if test="in_array($this->memberData['member_group_id'], array(4,7,8,9,11,13,15,16) )"> <optgroup label='Squad/Team Staff Options'> <option value="#">View Practice Dates</option> <option value="#">View Squad/Team Points</option> </optgroup> </if> <if test="in_array($this->memberData['member_group_id'], array(4,8,9,11,13,15,16) )"> <optgroup label='Battalion/Clubhouse Staff Options'> <option value="#">Recruit List</option> <option value="#">Member List</option> <option value="# ">SS/TS/Supevisor List</option> </optgroup> </if> <if test="in_array($this->memberData['member_group_id'], array(4,9,11,13,15,16) )"> <optgroup label='Division Staff Options'> <option value="#">Validate recruits</option> <option value="#">BTN/CH Report</option> <option value="#">Discharge Logs</option> </optgroup> </if> <if test="in_array($this->memberData['member_group_id'], array(4,15,16) )"> <optgroup label='Web Team Staff Options'> <option value="#">Announcemnt Accounts</option> </optgroup> </if> </select> </center> The code <if test="in_array($this->memberData['member_group_id'], array(4,15,16) )"> Is checking primary group. How do I make it so it checks secondary group as well. 1 Link to comment Share on other sites More sharing options...
0 Lock Down Posted December 10, 2013 Share Posted December 10, 2013 Use this instead: <if test="IPSMember::isInGroup( $this->memberData, array(4,15,16) )"> 2 Link to comment Share on other sites More sharing options...
0 Verified Posted December 10, 2013 Share Posted December 10, 2013 The question(s) in this support topic have been answered and the owner has been able to solve the problem. Because of this, the support topic has been closed and moved. If you have other questions, please open a new topic. Link to comment Share on other sites More sharing options...
Question
Die Hard Gaming
So I have this code
The code
Is checking primary group. How do I make it so it checks secondary group as well.Link to comment
Share on other sites
2 answers to this question
Recommended Posts