Пример #1
0
 /**
  * Obfuscate some text
  *
  * @param   string  $text  Text to obfuscate
  * @return  string
  * @throws  \InvalidArgumentException If no text passed
  */
 public function __invoke($text = null)
 {
     if (null === $text) {
         throw new \InvalidArgumentException(__METHOD__ . '(); No text passed.');
     }
     return String::obfuscate($text);
 }
Пример #2
0
				<?php 
    if ($this->params->get('access_email', 2) == 0 || $this->params->get('access_email', 2) == 1 && $loggedin || $this->params->get('access_email', 2) == 2 && $isUser) {
        ?>
					<li class="profile-email field">
						<div class="field-content">
							<div class="key"><?php 
        echo Lang::txt('PLG_GROUPS_PROFILE_EMAIL');
        ?>
</div>
							<div class="value">
								<a class="email" href="mailto:<?php 
        echo \Hubzero\Utility\String::obfuscate($this->profile->get('email'));
        ?>
" rel="nofollow">
									<?php 
        echo \Hubzero\Utility\String::obfuscate($this->profile->get('email'));
        ?>
								</a>
							</div>
						</div>
					</li>
				<?php 
    }
    ?>
			<?php 
}
?>

			<?php 
if ($this->registration->ORCID != REG_HIDE && $this->profile->get('orcid')) {
    ?>
Пример #3
0
                    $usersConfig = Component::params('com_users');
                    $useractivation = $usersConfig->get('useractivation', 1);
                    if ($useractivation != 0) {
                        ?>
								<p class="warning"><?php 
                        echo Lang::txt('COM_MEMBERS_REGISTER_YOU_MUST_CONFIRM_EMAIL', \Hubzero\Utility\String::obfuscate(Config::get('mailfrom')));
                        ?>
</p>
							<?php 
                    }
                    ?>
						<?php 
                } else {
                    ?>
							<p class="warning">Important! If you change your e-mail address you <strong>must</strong> confirm receipt of the confirmation e-mail from <?php 
                    echo \Hubzero\Utility\String::obfuscate(Config::get('mailfrom'));
                    ?>
 in order to re-activate your account.</p>
						<?php 
                }
            }
            ?>
					<?php 
        }
        ?>
				<?php 
    }
    ?>
			</fieldset>
			<div class="clear"></div>
		<?php 
Пример #4
0
 /**
  * Automatically links any strings matching a URL or email pattern
  *
  * Link is pushed to internal array and placeholder returned
  * This is to ensure links aren't parsed twice. We put the links back in place
  * towards the end of parsing.
  *
  * @param   array   $matches  Text matching link pattern
  * @return  string
  */
 public function anchor($matches)
 {
     if (empty($matches)) {
         return '';
     }
     $whole = $matches[0];
     $prtcl = rtrim($matches[1], ':');
     $url = $matches[3];
     $url .= isset($matches[4]) ? $matches[4] : '';
     $url .= isset($matches[5]) ? $matches[5] : '';
     $url .= isset($matches[6]) ? $matches[6] : '';
     $prfx = preg_replace('/^([\\s]*)(.*)/i', "\$1", $whole);
     $href = trim($whole);
     if (substr($href, 0, 1) == '>') {
         $href = ltrim($href, '>');
         $prfx .= '>';
     }
     $txt = $href;
     if ($prtcl == 'mailto') {
         $txt = $url;
         $href = 'mailto:' . String::obfuscate($url);
     }
     return $prfx . '<a class="ext-link" href="' . $href . '" rel="external">' . $txt . '</a>';
 }
Пример #5
0
 /**
  * Auto-link mailto, ftp, and http strings in text
  *
  * @param      array  $matches Text to autolink
  * @return     string
  */
 public function autolink($matches)
 {
     $href = $matches[0];
     if (substr($href, 0, 1) == '!') {
         return substr($href, 1);
     }
     $href = str_replace('"', '', $href);
     $href = str_replace("'", '', $href);
     $href = str_replace('&#8221', '', $href);
     $h = array('h', 'm', 'f', 'g', 'n');
     if (!in_array(substr($href, 0, 1), $h)) {
         $href = substr($href, 1);
     }
     $name = trim($href);
     if (substr($name, 0, 7) == 'mailto:') {
         $name = substr($name, 7, strlen($name));
         $name = \Hubzero\Utility\String::obfuscate($name);
         $href = 'mailto:' . $name;
     }
     $l = sprintf(' <a class="ext-link" href="%s" rel="external">%s</a>', $href, $name);
     return $l;
 }
Пример #6
0
		<div class="col span-half omega">
			<?php 
if ($this->getError()) {
    ?>
				<p class="error"><?php 
    echo $this->getError();
    ?>
</p>
			<?php 
} else {
    if ($this->xprofile->get('emailConfirmed') < 0) {
        ?>
				<div class="account-activation">
					<div class="instructions">
						<p><?php 
        echo Lang::txt('COM_MEMBERS_REGISTER_ACCOUNT_CREATED_MESSAGE', $this->sitename, \Hubzero\Utility\String::obfuscate($this->xprofile->get('email')));
        ?>
</p>
						<ol>
							<li><?php 
        echo Lang::txt('COM_MEMBERS_REGISTER_ACCOUNT_INSTRUCT_FIND_EMAIL');
        ?>
</li>
							<li><?php 
        echo Lang::txt('COM_MEMBERS_REGISTER_ACCOUNT_INSTRUCT_ACTIVATE');
        ?>
</li>
							<li><?php 
        echo Lang::txt('COM_MEMBERS_REGISTER_ACCOUNT_INSTRUCT_LOGIN');
        ?>
</li>