diff options
Diffstat (limited to 'pages')
-rw-r--r-- | pages/account/29.php | 4 | ||||
-rw-r--r-- | pages/account/30.php | 1 | ||||
-rw-r--r-- | pages/account/35.php | 117 | ||||
-rw-r--r-- | pages/wot/6.php | 7 |
4 files changed, 85 insertions, 44 deletions
diff --git a/pages/account/29.php b/pages/account/29.php index c1a3def..4229b3b 100644 --- a/pages/account/29.php +++ b/pages/account/29.php @@ -35,10 +35,12 @@ <td class="DataTD"><input type="text" name="domainname" value="<?=sanitizeHTML($_SESSION['_config']['domain'])?>"></td> </tr> <tr> - <td class="DataTD" colspan="2"><input type="submit" name="process" value="<?=_("Update")?>"></td> + <td class="DataTD"><input type="submit" name="cancel" value="<?=_("Cancel")?>"></td> + <td class="DataTD"><input type="submit" name="process" value="<?=_("Update")?>"></td> </tr> </table> <input type="hidden" name="oldid" value="<?=intval($id)?>"> <input type="hidden" name="orgid" value="<?=intval($_REQUEST['orgid'])?>"> +<input type="hidden" name="domid" value="<?=intval($_REQUEST['domid'])?>"> </form> diff --git a/pages/account/30.php b/pages/account/30.php index 33eeca8..04ad229 100644 --- a/pages/account/30.php +++ b/pages/account/30.php @@ -41,5 +41,6 @@ <input type="hidden" name="oldid" value="<?=intval($id)?>"> <input type="hidden" name="orgid" value="<?=intval($_REQUEST['orgid'])?>"> <input type="hidden" name="domain" value="<?=sanitizeHTML($row['domain'])?>"> +<input type="hidden" name="domid" value="<?=intval($_REQUEST['domid'])?>"> </form> diff --git a/pages/account/35.php b/pages/account/35.php index 3a4714f..05c7f2b 100644 --- a/pages/account/35.php +++ b/pages/account/35.php @@ -15,44 +15,89 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ ?> + <table align="center" valign="middle" border="0" cellspacing="0" cellpadding="0" class="wrapper" width="400"> - <tr> - <td colspan="3" class="title"><?=_("Organisations")?></td> - </tr> - <tr> - <td class="DataTD">#</td> - <td class="DataTD"><?=_("Organisation")?></td> - <td class="DataTD"><?=_("Admins")?></td> - </tr> -<? - $query = "select * from `orginfo`,`org` where `orginfo`.`id`=`org`.`orgid` and `org`.`memid`='".intval($_SESSION['profile']['id'])."'"; - $res = mysql_query($query); - while($row = mysql_fetch_assoc($res)) - { - //number of admins for the org - $r2 = mysql_query("select * from `org` where `orgid`='".intval($row['id'])."'"); - $admincount = mysql_num_rows($r2); - // number of domains for the org - $r2 = mysql_query("select * from `orgdomains` where `orgid`='".intval($row['id'])."'"); - $domcount = mysql_num_rows($r2); -?> - <tr> - <td class="DataTD"><?=intval($row['id'])?></td> - <td class="DataTD"><?=($row['O'])?>, <?=($row['ST'])?> <?=sanitizeHTML($row['C'])?></td> - <td class="DataTD"><a href="account.php?id=32&orgid=<?=$row['id']?>"><?=_("Admins")?> (<?=$admincount?>)</a></td> - </tr> <? - // display the domains of each organisation - $query3 = "select * from `orgdomains` where `orgid`='".intval($row['id'])."'"; - $res3 = mysql_query($query3); - while($detailorg = mysql_fetch_assoc($res3)) +$query = "select * + from `orginfo`,`org` + where `orginfo`.`id`=`org`.`orgid` + and `org`.`memid`='".intval($_SESSION['profile']['id'])."'"; + +$res = mysql_query($query); +while($row = mysql_fetch_assoc($res)) +{ + ?> + <tr> + <td colspan="3" class="title"><?=_("Organisation")?></td> + </tr> + <tr> + <td class="DataTD"><?=_("Organisation Name")?>:</td> + <td colspan="2" class="DataTD" ><b><?=$row['O']?></b></td> + </tr> + <tr> + <td class="DataTD"><?=_("Contact Email")?>:</td> + <td colspan="2" class="DataTD"><?=($row['contact'])?></td> + </tr> + <tr> + <td class="DataTD"><?=_("Town/Suburb")?>:</td> + <td colspan="2" class="DataTD"><?=($row['L'])?></td> + </tr> + <tr> + <td class="DataTD"><?=_("State/Province")?>:</td> + <td colspan="2" class="DataTD"><?=($row['ST'])?></td> + </tr> + <tr> + <td class="DataTD"><?=_("Country")?>:</td> + <td colspan="2" class="DataTD"><?=($row['C'])?></td> + </tr> + <? + + //domain info + $query = "select `domain` from `orgdomains` where `orgid`='".intval($row['id'])."'"; + $res1 = mysql_query($query); + while($domain = mysql_fetch_assoc($res1)) + { + ?> + <tr> + <td class="DataTD"><?=_("Domain")?></td> + <td colspan="2" class="DataTD"><?=sanitizeHTML($domain['domain'])?></td> + </tr> + <? + } + + ?> + <tr> + <td class="DataTD"><?=_("Administrator")?></td> + <td class="DataTD"><?=_("Master Account")?></td> + <td class="DataTD"><?=_("Department")?></td> + </tr> + <? + + //org admins + $query = "select * from `org` where `orgid`='".intval($row['id'])."'"; + $res2 = mysql_query($query); + while($org = mysql_fetch_assoc($res2)) { -?> - <tr> - <td class="DataTD"><?=intval($detailorg['id'])?></td> - <td class="DataTD"><?=_("Domain available")?></td> - <td class="DataTD"><?=sanitizeHTML($detailorg['domain'])?></td> - </tr> -<? } } ?> + $user = mysql_fetch_assoc(mysql_query("select * from `users` where `id`='".intval($org['memid'])."'")); + ?> + <tr> + <td class="DataTD"><a href='mailto:<?=$user['email']?>'><?=($user['fname'])?> <?=($user['lname'])?></a></td> + <td class="DataTD"><?=($org['masteracc'])?></td> + <td class="DataTD"><?=($org['OU'])?></td> + </tr> + <? + + if(intval($org['masteracc']) === 1 && + intval($org['memid']) === intval($_SESSION['profile']['id'])) + { + $master="account.php?id=32&orgid=".intval($row['id']); + ?> + <tr> + <td colspan="3" class="DataTD"><a href="<?=$master ?>"><?=_("Edit")?></a></td> + </tr> + <? + } + } +} ?> </table> diff --git a/pages/wot/6.php b/pages/wot/6.php index e648ed4..28c1875 100644 --- a/pages/wot/6.php +++ b/pages/wot/6.php @@ -17,10 +17,6 @@ */ ?> <? -function makecap() -{ -} - if(!array_key_exists('notarise',$_SESSION['_config'])) { echo "Error: No user data found."; @@ -44,8 +40,6 @@ function makecap() $name = $fname." ".$mname." ".$lname." ".$suffix; $_SESSION['_config']['wothash'] = md5($name."-".$dob); - $cap=makecap($fname,$mname,$lname,$suffix,$dob,$row['email'],$_SESSION['profile']['fname'],$_SESSION['profile']['mname'],$_SESSION['profile']['lname'],$_SESSION['profile']['suffix']); - include_once($_SESSION['_config']['filepath']."/includes/wot.inc.php"); AssureHead(_("Assurance Confirmation"),sprintf(_("Please check the following details match against what you witnessed when you met %s in person. You MUST NOT proceed unless you are sure the details are correct. You may be held responsible by the CAcert Arbitrator for any issues with this Assurance."), $fname)); @@ -61,6 +55,5 @@ function makecap() AssureInboxLine("points",_("Points"),"","<br />(Max. ".maxpoints().")"); AssureCCABoxLine("CCAAgreed",sprintf(_("Check this box only if %s agreed to the <a href=\"/policy/CAcertCommunityAgreement.php\">CAcert Community Agreement</a>"),$fname)); AssureCCABoxLine("CCAAgree",_("Check this box only if YOU agree to the <a href=\"/policy/CAcertCommunityAgreement.php\">CAcert Community Agreement</a>")); - AssureTextLine(_("WoT Form"),"<a href=\"".$cap."\" target=\"_blank\">A4 - "._("WoT Form")."</a> <a href=\"".$cap."&format=letter\" target=\"_blank\">US - "._("WoT Form")."</a>"); AssureFoot($id,_("I confirm this Assurance")); ?> |