From bac61cf596c143a15a430b5ba15d9f3a8dfe21e5 Mon Sep 17 00:00:00 2001 From: rabuzarus <> Date: Sun, 25 Oct 2015 16:49:45 +0100 Subject: [PATCH] manage-selector: some cleanup and css work --- mod/manage.php | 9 +++--- view/global.css | 45 ++++++++++++++++++++++++++++++ view/templates/manage.tpl | 35 +++++++++++------------ view/theme/frost-mobile/style.css | 46 ++++++++++++++++++++++++++----- view/theme/frost/style.css | 46 ++++++++++++++++++++++++++----- 5 files changed, 144 insertions(+), 37 deletions(-) diff --git a/mod/manage.php b/mod/manage.php index 236a3fb054..3f553dfa6b 100644 --- a/mod/manage.php +++ b/mod/manage.php @@ -99,16 +99,17 @@ function manage_content(&$a) { $identities = $a->identities; - //getting profile pics for delegates + //getting additinal information for each identity foreach ($identities as $key=>$id) { - $thumb = q("SELECT `thumb` FROM `contact` WHERE `uid` = %d AND `name` = '%s' AND `nick` = '%s' AND (network = 'dfrn' OR self = 1)", + $thumb = q("SELECT `thumb` FROM `contact` WHERE `uid` = %d AND `name` = '%s' AND `nick` = '%s' AND (`network` = '%s' OR `self` = 1)", intval($a->user['uid']), dbesc($id['username']), - dbesc($id['nickname']) + dbesc($id['nickname']), + dbesc(NETWORK_DFRN) ); $identities[$key][thumb] = $thumb[0][thumb]; - $identities[$key]['selected'] = (($id['nickname'] === $a->user['nickname']) ? ' selected="selected" ' : ''); + $identities[$key]['selected'] = (($id['nickname'] === $a->user['nickname']) ? true : false); } $o = replace_macros(get_markup_template('manage.tpl'), array( diff --git a/view/global.css b/view/global.css index c2f5840039..d1c07d60aa 100644 --- a/view/global.css +++ b/view/global.css @@ -212,3 +212,48 @@ a { clip: rect(0,0,0,0); border: 0; } + +.itentity-match-wrapper { + float: left; + padding: 10px; + width: 120px; + height: 140px; + margin-bottom: 20px; +} + +.identity-match-photo { + float: left; + text-align: center; + width: 120px; +} + +.identity-match-name { + text-align: center; +} + +.identity-match-details { + float: left; + text-align: center; + width: 120px; + overflow: hidden; + font-size: 10px; + font-weight: 500; + color: #999999; +} + +.identity-match-break, .identity-match-end { + clear: both; +} + +.identity-match-photo button { + border: none; + padding: 0; + margin: 0; + background: none; + height: 80px; + width: 80px; +} + +.selected-identity img { + border: 2px solid #ff0000; +} \ No newline at end of file diff --git a/view/templates/manage.tpl b/view/templates/manage.tpl index d82ddb6d73..8a7922d7be 100644 --- a/view/templates/manage.tpl +++ b/view/templates/manage.tpl @@ -2,32 +2,29 @@