Beispiel #1
0
    public function findAllUsersSharing($page = 1, $perPage = 10, &$totalFound)
    {
        $db = $this->_getDb();
        $records = $this->fetchAllKeyed('
			SELECT SQL_CALC_FOUND_ROWS COUNT(*) AS total, field_value
			FROM xf_user_field_value
			WHERE field_id = "analytics_cid"
				AND field_value LIKE "GA%"
			GROUP BY field_value
			HAVING total > 1
			ORDER BY total DESC, field_value
			LIMIT ' . intval(($page - 1) * $perPage) . ', ' . $perPage . '
			', 'field_value', array());
        $totalFound = $db->fetchOne('SELECT FOUND_ROWS()');
        $clientIds = $users = array();
        if ($records) {
            foreach ($records as $record) {
                $clientIds[] = $record['field_value'];
            }
            $users = $db->fetchAll('
				SELECT xf_user.*, xf_user_field_value.field_value
				FROM xf_user_field_value
					LEFT JOIN xf_user ON (xf_user.user_id = xf_user_field_value.user_id)
				WHERE xf_user_field_value.field_id = "analytics_cid"
					AND xf_user_field_value.field_value IN(' . $db->quote($clientIds) . ')
				ORDER BY xf_user_field_value.user_id
			');
            if ($users) {
                foreach ($users as &$user) {
                    $records[$user['field_value']]['users_output'][$user['user_id']] = XenForo_Template_Helper_Core::callHelper('usernamehtml', array($user, '', true, array('href' => XenForo_Template_Helper_Core::adminLink('users/edit', $user, array()), 'class' => 'NoOverlay')));
                }
                foreach ($records as &$record) {
                    $record['users_output'] = implode(', ', $record['users_output']);
                }
            }
        }
        return $records;
    }
Beispiel #2
0
<?php

if (!class_exists('XenForo_Application', false)) {
    die;
}
$__output = '';
$__output .= '<div style="display: block; padding: 3px; margin: 2px">
	<a href="' . XenForo_Template_Helper_Core::adminLink('widgets/add', '', array('position' => $positionCode, 'display_order' => $displayOrder)) . '"
		target="_blank"
		title="' . htmlspecialchars($positionCode, ENT_QUOTES, 'UTF-8') . ($displayOrder + 0 != 0 ? ' - ' . 'Display Order' . ': ' . htmlspecialchars($displayOrder, ENT_QUOTES, 'UTF-8') : '') . '"
		class="Tooltip"
		style="background: white; color: black; border: 1px solid black; padding: 3px">
		' . 'Add Widget' . '
	</a>
</div>';
Beispiel #3
0
    $__compilerVar82 .= '
											<li><a href="' . XenForo_Template_Helper_Core::link('members/shared-ips', $user, array()) . '" class="OverlayTrigger">' . 'Chia sẻ IPs' . '</a></li>
										';
}
$__compilerVar82 .= '
										';
if ($canBanUsers) {
    $__compilerVar82 .= '
											';
    if ($user['is_banned']) {
        $__compilerVar82 .= '
												<li><a href="' . XenForo_Template_Helper_Core::adminLink('banning/users/lift', $user, array()) . '">' . 'Lift Ban' . '</a></li>
											';
    } else {
        $__compilerVar82 .= '
												<li><a href="' . XenForo_Template_Helper_Core::adminLink('banning/users/add', $user, array()) . '">' . 'Ban' . '</a></li>
											';
    }
    $__compilerVar82 .= '
										';
}
$__compilerVar82 .= '
										';
if ($canEditUser) {
    $__compilerVar82 .= '
											<li><a href="' . XenForo_Template_Helper_Core::link('members/edit', $user, array()) . '">' . 'Sửa' . '</a></li>
										';
}
$__compilerVar82 .= '
									';
if (trim($__compilerVar82) !== '') {