Beispiel #1
0
function multimedia_publish_attachments_register(&$attachment_types)
{
  l10n_load('plugins/multimedia/l10n');
  $attachment_types[] = array('caption' => l10n('mm.attach.pic'), 'editor' => 'multimedia/picture.php');
  $attachment_types[] = array('caption' => l10n('mm.attach.link'), 'editor' => 'multimedia/link.php');
  $attachment_types[] = array('caption' => l10n('mm.attach.text'), 'editor' => 'multimedia/text.php');
}
Beispiel #2
0
function friendlyui_show_notice(&$data, &$ds)
{
  l10n_load('plugins/friendlyui/l10n');
  
  ?><div class="notice_me">
    <? include('plugins/friendlyui/msg.'.$data['notice_type'].'.php'); ?>
  </div><?
}
Beispiel #3
0
	function getMyGroups()
	{
	  l10n_load('mvc/friends/l10n');
	  $result = array();
	  $grpList = DB_GetList('SELECT * FROM '.getTableName('localgroups').' WHERE lg_entity = ?', array(object('user')->ds['u_entity'])); 
	  if(sizeof($grpList) == 0)
	  {
	    foreach(explode(',', '_friends,_colleagues,_acquaintances,_family') as $gname)
	    {
	      $nds = array('lg_entity' => object('user')->ds['u_entity'], 'lg_name' => $gname);
	      $nds['lg_key'] = DB_UpdateDataset('localgroups', $nds);
	      $grpList[] = $nds; 
      }
    }
    foreach($grpList as $grp)
    {
      if(substr($grp['lg_name'], 0, 1) == '_') $grp['lg_name'] = l10n($grp['lg_name']);
      $result[] = $grp;
    }
    return($result);
  }
Beispiel #4
0
<?

if($_REQUEST['controller'] != 'signin') l10n_load('mvc/signin/l10n');

?>
  <div class="paragraph padded_extra" style="width: 550px">      
    <? 
      /* fixme: Twitter Signin is broken 
      if($GLOBALS['config']['twitter']['enabled'] === true) $signInLinks[] = '<a class="btn" href="'.actionUrl('twitter', 'signin').'">Twitter</a>';
      */
      if($GLOBALS['config']['facebook']['enabled'] === true) $signInLinks[] = '<a class="btn" href="'.actionUrl('fb', 'signin').'">Facebook</a>';
      $signInLinks[] = '<a class="btn" href="'.actionUrl('google', 'signin').'">Google</a>';
      $signInLinks[] = '<a class="btn" href="'.actionUrl('yahoo', 'signin').'">Yahoo</a>';
      $signInLinks[] = '<a class="btn" onclick="$(\'#signinform\').html($(\'#signinform_openid\').html());">OpenID</a>';
      $signInLinks[] = '<a class="btn" onclick="$(\'#signinform\').html($(\'#signinform_email\').html());">Email</a>';
      print(implode(' ', $signInLinks));
    ?><br/><br/>
    <div id="signinform">
      <? include('mvc/signin/signin.ajax_'.getDefault($_SESSION['load_signin'], 'email').'form.php'); ?>
    </div>
    <div id="signinform_email" style="display:none">
      <? include('mvc/signin/signin.ajax_emailform.php'); ?>
    </div>
    <div id="signinform_openid" style="display:none">
      <? include('mvc/signin/signin.ajax_openidform.php'); ?>
    </div>
    <div style="margin-bottom: 8px; margin-top: 4px;">
    <?
    if($_REQUEST['controller'] == 'signin')
    {
    ?>
Beispiel #5
0
<?

  if (substr($_SERVER['REQUEST_URI'], 0, 1) == '/')
	   interpretQueryString($_SERVER['REQUEST_URI']);    
  
  ob_start();
  
  $GLOBALS['config']['page']['title'] = 'Install';
  $GLOBALS['page.h1'] = 'Hubbub 0.2 Installer';
  l10n_load('ext/installer/l10n');
  
  $GLOBALS['errorhandler_ignore'] = true;
  
  $installerFN = 'ext/installer/'.getDefault(getDefault($_REQUEST['p'], $_REQUEST['controller']), 'index').'.php';
  if (file_exists($installerFN))
    include($installerFN);
  else
    redirect('./');
  
  $GLOBALS['content']['main'] = '<div class="installer">'.ob_get_clean().'</div>';
  
  header('content-type: text/html;charset=UTF-8');
  include('themes/default/default.php');
  
  die();

?>
Beispiel #6
0
<?php
    l10n_load('templates/openidlogin');

    $openidProviders = array(
      'google' => array('icon' => 'google.png', 'url' => 'https://www.google.com/accounts/o8/id', 'caption' => 'Google'),
      'yahoo' => array('icon' => 'yahoo.png', 'url' => 'https://me.yahoo.com', 'caption' => 'Yahoo'),
      );
    require('ext/lightopenid/openid.php');
    try {
        if(!isset($_REQUEST['openid_mode'])) {
            if(isset($_REQUEST['identity'])) {
                $openid = new LightOpenID;
                $openid->identity = $_REQUEST['identity'];
                header('Location: ' . $openid->authUrl());
            }
          } elseif($_REQUEST['openid_mode'] == 'cancel') {
              echo '<div class="banner">'.l10n('openid.cancel').'</div>';
          } else {
              $openid = new LightOpenID;
              if($openid->validate())
              {
              	$this->onOpenIDLogin($openid);
              }
              else
              {
                ?><div class="banner"><?= l10n('openid.error') ?> :-(</div><?
              }
          }
      } catch(ErrorException $e) {
          echo $e->getMessage();
      }
Beispiel #7
0
 function __construct($name)
 {
     $this->name = $name;
     $this->user =& $GLOBALS['obj']['user'];
     $this->menu = array();
     $this->subControllers = array();
     if (!isset($GLOBALS['submenu'])) {
         $GLOBALS['submenu'] =& $this->menu;
     }
     if (!isset($GLOBALS['currentcontroller'])) {
         $GLOBALS['currentcontroller'] =& $this;
     }
     l10n_load('mvc/' . $this->name . '/l10n');
 }