2014-05-14 16:46:07 +09:00
|
|
|
|
<?php
|
|
|
|
|
|
2015-07-02 02:15:31 +09:00
|
|
|
|
/* · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
|
2014-05-14 16:46:07 +09:00
|
|
|
|
· ·
|
|
|
|
|
· ·
|
|
|
|
|
· Q V I T T E R ·
|
|
|
|
|
· ·
|
2016-01-18 09:24:37 +09:00
|
|
|
|
· https://git.gnu.io/h2p/Qvitter ·
|
2014-05-14 16:46:07 +09:00
|
|
|
|
· ·
|
|
|
|
|
· ·
|
|
|
|
|
· <o) ·
|
|
|
|
|
· /_//// ·
|
|
|
|
|
· (____/ ·
|
|
|
|
|
· (o< ·
|
|
|
|
|
· o> \\\\_\ ·
|
|
|
|
|
· \\) \____) ·
|
|
|
|
|
· ·
|
2015-07-02 02:15:31 +09:00
|
|
|
|
· ·
|
2014-05-14 16:46:07 +09:00
|
|
|
|
· ·
|
|
|
|
|
· Qvitter is free software: you can redistribute it and / or modify it ·
|
|
|
|
|
· under the terms of the GNU Affero General Public License as published by ·
|
|
|
|
|
· the Free Software Foundation, either version three of the License or (at ·
|
|
|
|
|
· your option) any later version. ·
|
|
|
|
|
· ·
|
|
|
|
|
· Qvitter is distributed in hope that it will be useful but WITHOUT ANY ·
|
|
|
|
|
· WARRANTY; without even the implied warranty of MERCHANTABILTY or FITNESS ·
|
|
|
|
|
· FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for ·
|
|
|
|
|
· more details. ·
|
|
|
|
|
· ·
|
|
|
|
|
· You should have received a copy of the GNU Affero General Public License ·
|
|
|
|
|
· along with Qvitter. If not, see <http://www.gnu.org/licenses/>. ·
|
|
|
|
|
· ·
|
|
|
|
|
· Contact h@nnesmannerhe.im if you have any questions. ·
|
2015-07-02 02:15:31 +09:00
|
|
|
|
· ·
|
2014-05-14 16:46:07 +09:00
|
|
|
|
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · */
|
2014-05-16 11:07:30 +09:00
|
|
|
|
class QvitterAction extends ApiAction
|
2014-05-14 16:46:07 +09:00
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
function isReadOnly($args)
|
|
|
|
|
{
|
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected function prepare(array $args=array())
|
|
|
|
|
{
|
|
|
|
|
parent::prepare($args);
|
|
|
|
|
|
|
|
|
|
$user = common_current_user();
|
|
|
|
|
|
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected function handle()
|
|
|
|
|
{
|
|
|
|
|
parent::handle();
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2014-05-14 16:46:07 +09:00
|
|
|
|
$this->showQvitter();
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function showQvitter()
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$logged_in_user_nickname = '';
|
2015-07-02 02:15:31 +09:00
|
|
|
|
$logged_in_user_obj = false;
|
2014-05-14 16:46:07 +09:00
|
|
|
|
$logged_in_user = common_current_user();
|
|
|
|
|
if($logged_in_user) {
|
|
|
|
|
$logged_in_user_nickname = $logged_in_user->nickname;
|
2014-05-16 11:07:30 +09:00
|
|
|
|
$logged_in_user_obj = ApiAction::twitterUserArray($logged_in_user->getProfile());
|
2014-05-14 16:46:07 +09:00
|
|
|
|
}
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2014-05-16 11:07:30 +09:00
|
|
|
|
$registrationsclosed = false;
|
|
|
|
|
if(common_config('site','closed') == 1 || common_config('site','inviteonly') == 1) {
|
|
|
|
|
$registrationsclosed = true;
|
|
|
|
|
}
|
2015-02-04 22:44:04 +09:00
|
|
|
|
|
|
|
|
|
// check if the client's ip address is blocked for registration
|
|
|
|
|
if(is_array(QvitterPlugin::settings("blocked_ips"))) {
|
2015-07-02 02:15:31 +09:00
|
|
|
|
$client_ip_is_blocked = in_array($_SERVER['REMOTE_ADDR'], QvitterPlugin::settings("blocked_ips"));
|
|
|
|
|
}
|
|
|
|
|
|
2014-05-14 16:46:07 +09:00
|
|
|
|
$sitetitle = common_config('site','name');
|
|
|
|
|
$siterootdomain = common_config('site','server');
|
|
|
|
|
$qvitterpath = Plugin::staticPath('Qvitter', '');
|
2014-12-01 11:48:04 +09:00
|
|
|
|
$apiroot = common_path('api/', StatusNet::isHTTPS());
|
2015-01-24 00:28:41 +09:00
|
|
|
|
$attachmentroot = common_path('attachment/', StatusNet::isHTTPS());
|
2014-12-01 11:48:04 +09:00
|
|
|
|
$instanceurl = common_path('', StatusNet::isHTTPS());
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
|
|
|
|
|
2014-05-14 16:46:07 +09:00
|
|
|
|
common_set_returnto(''); // forget this
|
|
|
|
|
|
|
|
|
|
// if this is a profile we add a link header for LRDD Discovery (see WebfingerPlugin.php)
|
2015-07-02 02:15:31 +09:00
|
|
|
|
if(substr_count($_SERVER['REQUEST_URI'], '/') == 1) {
|
2014-05-14 16:46:07 +09:00
|
|
|
|
$nickname = substr($_SERVER['REQUEST_URI'],1);
|
|
|
|
|
if(preg_match("/^[a-zA-Z0-9]+$/", $nickname) == 1) {
|
|
|
|
|
$acct = 'acct:'. $nickname .'@'. common_config('site', 'server');
|
|
|
|
|
$url = common_local_url('webfinger') . '?resource='.$acct;
|
|
|
|
|
foreach (array(Discovery::JRD_MIMETYPE, Discovery::XRD_MIMETYPE) as $type) {
|
|
|
|
|
header('Link: <'.$url.'>; rel="'. Discovery::LRDD_REL.'"; type="'.$type.'"');
|
|
|
|
|
}
|
|
|
|
|
}
|
2015-07-02 02:15:31 +09:00
|
|
|
|
}
|
2014-05-14 16:46:07 +09:00
|
|
|
|
|
|
|
|
|
?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
|
|
|
|
|
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
|
|
|
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
2015-07-02 02:15:31 +09:00
|
|
|
|
<head>
|
2014-05-14 16:46:07 +09:00
|
|
|
|
<title><?php print $sitetitle; ?></title>
|
|
|
|
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
2015-07-02 02:15:31 +09:00
|
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=0">
|
2014-11-28 21:49:00 +09:00
|
|
|
|
<link rel="stylesheet" type="text/css" href="<?php print $qvitterpath; ?>css/qvitter.css?changed=<?php print date('YmdHis',filemtime(QVITTERDIR.'/css/qvitter.css')); ?>" />
|
2015-07-02 02:15:31 +09:00
|
|
|
|
<link rel="stylesheet" type="text/css" href="<?php print $qvitterpath; ?>css/jquery.minicolors.css" />
|
2015-01-28 05:22:17 +09:00
|
|
|
|
<link rel="shortcut icon" type="image/x-icon" href="<?php print $qvitterpath; ?><?php print QvitterPlugin::settings("favicon"); ?>">
|
2014-05-14 16:46:07 +09:00
|
|
|
|
<?php
|
|
|
|
|
|
|
|
|
|
// if qvitter is a webapp and this is a users url we add feeds
|
2015-07-02 02:15:31 +09:00
|
|
|
|
if(substr_count($_SERVER['REQUEST_URI'], '/') == 1) {
|
2014-05-14 16:46:07 +09:00
|
|
|
|
$nickname = substr($_SERVER['REQUEST_URI'],1);
|
|
|
|
|
if(preg_match("/^[a-zA-Z0-9]+$/", $nickname) == 1) {
|
2015-07-02 02:15:31 +09:00
|
|
|
|
$user = User::getKV('nickname', $nickname);
|
2014-05-14 16:46:07 +09:00
|
|
|
|
if(!isset($user->id)) {
|
2014-11-28 07:29:58 +09:00
|
|
|
|
//error_log("QVITTER: Could not get user id for user with nickname: $nickname – REQUEST_URI: ".$_SERVER['REQUEST_URI']);
|
2015-07-02 02:15:31 +09:00
|
|
|
|
}
|
2014-05-14 16:46:07 +09:00
|
|
|
|
else {
|
|
|
|
|
print '<link title="Notice feed for '.$nickname.' (Activity Streams JSON)" type="application/stream+json" href="'.$instanceurl.'api/statuses/user_timeline/'.$user->id.'.as" rel="alternate">'."\n";
|
2015-02-08 22:02:34 +09:00
|
|
|
|
print ' <link title="Notice feed for '.$nickname.' (RSS 1.0)" type="application/rdf+xml" href="'.$instanceurl.$nickname.'/rss" rel="alternate">'."\n";
|
|
|
|
|
print ' <link title="Notice feed for '.$nickname.' (RSS 2.0)" type="application/rss+xml" href="'.$instanceurl.'api/statuses/user_timeline/'.$user->id.'.rss" rel="alternate">'."\n";
|
|
|
|
|
print ' <link title="Notice feed for '.$nickname.' (Atom)" type="application/atom+xml" href="'.$instanceurl.'api/statuses/user_timeline/'.$user->id.'.atom" rel="alternate">'."\n";
|
|
|
|
|
print ' <link title="FOAF for '.$nickname.'" type="application/rdf+xml" href="'.$instanceurl.$nickname.'/foaf" rel="meta">'."\n";
|
2015-07-02 02:15:31 +09:00
|
|
|
|
print ' <link href="'.$instanceurl.$nickname.'/microsummary" rel="microsummary">'."\n";
|
|
|
|
|
|
2015-02-08 22:02:34 +09:00
|
|
|
|
// maybe openid
|
2015-02-09 06:23:28 +09:00
|
|
|
|
if (array_key_exists('OpenID', StatusNet::getActivePlugins())) {
|
2015-02-08 22:02:34 +09:00
|
|
|
|
print ' <link rel="openid2.provider" href="'.common_local_url('openidserver').'"/>'."\n";
|
|
|
|
|
print ' <link rel="openid2.local_id" href="'.$user->getProfile()->profileurl.'"/>'."\n";
|
|
|
|
|
print ' <link rel="openid2.server" href="'.common_local_url('openidserver').'"/>'."\n";
|
2015-07-02 02:15:31 +09:00
|
|
|
|
print ' <link rel="openid2.delegate" href="'.$user->getProfile()->profileurl.'"/>'."\n";
|
|
|
|
|
}
|
|
|
|
|
}
|
2014-05-14 16:46:07 +09:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
elseif(substr($_SERVER['REQUEST_URI'],0,7) == '/group/') {
|
|
|
|
|
$group_id_or_name = substr($_SERVER['REQUEST_URI'],7);
|
|
|
|
|
if(stristr($group_id_or_name,'/id')) {
|
|
|
|
|
$group_id_or_name = substr($group_id_or_name, 0, strpos($group_id_or_name,'/id'));
|
2015-07-02 02:15:31 +09:00
|
|
|
|
$group = User_group::getKV('id', $group_id_or_name);
|
2016-01-08 00:39:46 +09:00
|
|
|
|
if($group instanceof User_group) {
|
|
|
|
|
$group_name = $group->nickname;
|
|
|
|
|
$group_id = $group_id_or_name;
|
|
|
|
|
}
|
|
|
|
|
} else {
|
2015-02-05 02:03:49 +09:00
|
|
|
|
$group = Local_group::getKV('nickname', $group_id_or_name);
|
2016-01-08 00:39:46 +09:00
|
|
|
|
if($group instanceof Local_group) {
|
|
|
|
|
$group_id = $group->group_id;
|
|
|
|
|
$group_name = $group_id_or_name;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
if(preg_match("/^[a-zA-Z0-9]+$/", $group_id_or_name) == 1 && isset($group_name) && isset($group_id)) {
|
2015-02-05 02:19:49 +09:00
|
|
|
|
?>
|
|
|
|
|
|
|
|
|
|
<link rel="alternate" href="<?php echo htmlspecialchars(common_local_url('ApiTimelineGroup', array('id'=>$group_id, 'format'=>'as'))); ?>" type="application/stream+json" title="Notice feed for '<?php echo htmlspecialchars($group_name); ?>' group (Activity Streams JSON)" />
|
|
|
|
|
<link rel="alternate" href="<?php echo htmlspecialchars(common_local_url('grouprss', array('nickname'=>$group_name))); ?>" type="application/rdf+xml" title="Notice feed for '<?php echo htmlspecialchars($group_name); ?>' group (RSS 1.0)" />
|
|
|
|
|
<link rel="alternate" href="<?php echo htmlspecialchars(common_local_url('ApiTimelineGroup', array('id'=>$group_id, 'format'=>'rss'))); ?>" type="application/rss+xml" title="Notice feed for '<?php echo htmlspecialchars($group_name); ?>' group (RSS 2.0)" />
|
|
|
|
|
<link rel="alternate" href="<?php echo htmlspecialchars(common_local_url('ApiTimelineGroup', array('id'=>$group_id, 'format'=>'atom'))); ?>" type="application/atom+xml" title="Notice feed for '<?php echo htmlspecialchars($group_name); ?>' group (Atom)" />
|
|
|
|
|
<link rel="meta" href="<?php echo htmlspecialchars(common_local_url('foafgroup', array('nickname'=>$group_name))); ?>" type="application/rdf+xml" title="FOAF for '<?php echo htmlspecialchars($group_name); ?>' group" />
|
|
|
|
|
<?php
|
2014-05-14 16:46:07 +09:00
|
|
|
|
}
|
2015-07-02 02:15:31 +09:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-06-02 01:27:36 +09:00
|
|
|
|
?>
|
|
|
|
|
<script>
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
|
@licstart The following is the entire license notice for the
|
2015-06-02 01:27:36 +09:00
|
|
|
|
JavaScript code in this page.
|
|
|
|
|
|
|
|
|
|
Copyright (C) 2015 Hannes Mannerheim and other contributors
|
|
|
|
|
|
|
|
|
|
This program is free software: you can redistribute it and/or modify
|
|
|
|
|
it under the terms of the GNU Affero General Public License as
|
|
|
|
|
published by the Free Software Foundation, either version 3 of the
|
|
|
|
|
License, or (at your option) any later version.
|
|
|
|
|
|
|
|
|
|
This program is distributed in the hope that it will be useful,
|
|
|
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
|
GNU Affero General Public License for more details.
|
|
|
|
|
|
|
|
|
|
You should have received a copy of the GNU Affero General Public License
|
2015-07-02 02:15:31 +09:00
|
|
|
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
2015-06-02 01:27:36 +09:00
|
|
|
|
|
|
|
|
|
@licend The above is the entire license notice
|
|
|
|
|
for the JavaScript code in this page.
|
|
|
|
|
*/
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2016-01-18 23:26:54 +09:00
|
|
|
|
window.usersLanguageCode = <?php print json_encode(substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2)) ?>;
|
|
|
|
|
window.usersLanguageNameInEnglish = <?php print json_encode(Locale::getDisplayLanguage(substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2), 'en')) ?>;
|
|
|
|
|
window.englishLanguageData = <?php print file_get_contents($qvitterpath.'/locale/en.json'); ?>;
|
|
|
|
|
window.defaultAvatarStreamSize = <?php print json_encode(Avatar::defaultImage(AVATAR_STREAM_SIZE)) ?>;
|
2015-08-26 06:27:08 +09:00
|
|
|
|
window.defaultAvatarProfileSize = <?php print json_encode(Avatar::defaultImage(AVATAR_PROFILE_SIZE)) ?>;
|
2014-05-16 11:07:30 +09:00
|
|
|
|
window.textLimit = <?php print json_encode((int)common_config('site','textlimit')) ?>;
|
|
|
|
|
window.registrationsClosed = <?php print json_encode($registrationsclosed) ?>;
|
2014-11-28 07:29:58 +09:00
|
|
|
|
window.thisSiteThinksItIsHttpButIsActuallyHttps = <?php
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2015-09-29 23:57:21 +09:00
|
|
|
|
// this is due to a crazy setup at quitter.se, sorry about that
|
2015-12-30 00:35:09 +09:00
|
|
|
|
$siteSSL = common_config('site', 'ssl');
|
|
|
|
|
if(isset($_SERVER['HTTPS'])
|
2014-11-28 07:29:58 +09:00
|
|
|
|
&& $_SERVER['HTTPS'] != 'off'
|
2015-12-30 00:35:09 +09:00
|
|
|
|
&& $siteSSL == 'never' ) {
|
2015-09-29 23:57:21 +09:00
|
|
|
|
$this_site_thinks_it_is_http_but_is_actually_https = true;
|
|
|
|
|
print 'true';
|
2014-11-28 07:29:58 +09:00
|
|
|
|
}
|
|
|
|
|
else {
|
2015-09-29 23:57:21 +09:00
|
|
|
|
$this_site_thinks_it_is_http_but_is_actually_https = false;
|
2014-11-28 07:29:58 +09:00
|
|
|
|
print 'false';
|
|
|
|
|
}
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2014-11-28 07:29:58 +09:00
|
|
|
|
?>;
|
2014-05-15 03:57:16 +09:00
|
|
|
|
window.siteTitle = <?php print json_encode($sitetitle) ?>;
|
2015-07-02 02:15:31 +09:00
|
|
|
|
window.loggedIn = <?php
|
|
|
|
|
|
2014-11-28 07:29:58 +09:00
|
|
|
|
$logged_in_user_json = json_encode($logged_in_user_obj);
|
2015-07-02 02:15:31 +09:00
|
|
|
|
$logged_in_user_json = str_replace('http:\/\/quitter.se\/','https:\/\/quitter.se\/',$logged_in_user_json);
|
|
|
|
|
print $logged_in_user_json;
|
|
|
|
|
|
2014-10-05 21:07:31 +09:00
|
|
|
|
?>;
|
2014-05-14 16:46:07 +09:00
|
|
|
|
window.timeBetweenPolling = <?php print QvitterPlugin::settings("timebetweenpolling"); ?>;
|
2015-09-29 23:31:49 +09:00
|
|
|
|
window.apiRoot = <?php
|
|
|
|
|
|
|
|
|
|
$api_root = common_path("api/", StatusNet::isHTTPS());
|
2015-09-29 23:57:21 +09:00
|
|
|
|
if($this_site_thinks_it_is_http_but_is_actually_https) {
|
2015-11-17 00:09:01 +09:00
|
|
|
|
$api_root = str_replace('http://','https://',$api_root);
|
2015-09-29 23:57:21 +09:00
|
|
|
|
}
|
2015-09-29 23:31:49 +09:00
|
|
|
|
print '\''.$api_root.'\'';
|
|
|
|
|
|
|
|
|
|
?>;
|
2014-05-14 16:46:07 +09:00
|
|
|
|
window.fullUrlToThisQvitterApp = '<?php print $qvitterpath; ?>';
|
|
|
|
|
window.siteRootDomain = '<?php print $siterootdomain; ?>';
|
2015-07-02 02:15:31 +09:00
|
|
|
|
window.siteInstanceURL = '<?php print $instanceurl; ?>';
|
2014-05-14 16:46:07 +09:00
|
|
|
|
window.defaultLinkColor = '<?php print QvitterPlugin::settings("defaultlinkcolor"); ?>';
|
|
|
|
|
window.defaultBackgroundColor = '<?php print QvitterPlugin::settings("defaultbackgroundcolor"); ?>';
|
2015-01-22 05:03:38 +09:00
|
|
|
|
window.siteBackground = '<?php print QvitterPlugin::settings("sitebackground"); ?>';
|
2015-05-30 00:30:03 +09:00
|
|
|
|
window.enableWelcomeText = <?php print json_encode(QvitterPlugin::settings("enablewelcometext")); ?>;
|
|
|
|
|
window.customWelcomeText = <?php print json_encode(QvitterPlugin::settings("customwelcometext")); ?>;
|
2015-07-02 02:15:31 +09:00
|
|
|
|
window.urlShortenerAPIURL = '<?php print QvitterPlugin::settings("urlshortenerapiurl"); ?>';
|
2014-11-24 21:47:45 +09:00
|
|
|
|
window.urlShortenerSignature = '<?php print QvitterPlugin::settings("urlshortenersignature"); ?>';
|
2015-01-24 00:28:41 +09:00
|
|
|
|
window.commonSessionToken = '<?php print common_session_token(); ?>';
|
|
|
|
|
window.siteMaxThumbnailSize = <?php print common_config('thumbnail', 'maxsize'); ?>;
|
2015-07-02 02:15:31 +09:00
|
|
|
|
window.siteAttachmentURLBase = '<?php print $attachmentroot; ?>';
|
|
|
|
|
window.siteEmail = '<?php print common_config('site', 'email'); ?>';
|
2015-01-26 03:05:09 +09:00
|
|
|
|
window.siteLicenseTitle = '<?php print common_config('license', 'title'); ?>';
|
|
|
|
|
window.siteLicenseURL = '<?php print common_config('license', 'url'); ?>';
|
2015-06-19 18:46:37 +09:00
|
|
|
|
window.customTermsOfUse = <?php print json_encode(QvitterPlugin::settings("customtermsofuse")); ?>;
|
2015-08-25 21:00:07 +09:00
|
|
|
|
window.siteLocalOnlyDefaultPath = <?php print (common_config('public', 'localonly') ? 'true' : 'false'); ?>;
|
2015-09-01 06:53:09 +09:00
|
|
|
|
<?php
|
|
|
|
|
|
2015-11-18 06:48:28 +09:00
|
|
|
|
// Get all topics in Qvitter's namespace in Profile_prefs
|
2015-09-01 06:53:09 +09:00
|
|
|
|
if($logged_in_user) {
|
2015-11-19 04:08:25 +09:00
|
|
|
|
|
|
|
|
|
try {
|
|
|
|
|
$qvitter_profile_prefs = Profile_prefs::getNamespace(Profile::current(),'qvitter');
|
|
|
|
|
} catch (Exception $e) {
|
|
|
|
|
$qvitter_profile_prefs = array();
|
|
|
|
|
}
|
|
|
|
|
|
2015-11-18 06:48:28 +09:00
|
|
|
|
if(count($qvitter_profile_prefs)>0) {
|
|
|
|
|
$topic_data = new stdClass();
|
|
|
|
|
foreach($qvitter_profile_prefs as $pref) {
|
|
|
|
|
$topic_data->{$pref->topic} = $pref->data;
|
|
|
|
|
}
|
|
|
|
|
print 'window.qvitterProfilePrefs = '.json_encode($topic_data).';';
|
2015-09-01 06:53:09 +09:00
|
|
|
|
}
|
|
|
|
|
else {
|
2015-11-18 06:48:28 +09:00
|
|
|
|
print 'window.qvitterProfilePrefs = false;';
|
2015-09-01 06:53:09 +09:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
?>
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2015-02-25 06:36:36 +09:00
|
|
|
|
// available language files and their last update time
|
|
|
|
|
window.availableLanguages = {<?php
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2015-02-25 06:36:36 +09:00
|
|
|
|
// scan all files in the locale directory and create a json object with their change date added
|
|
|
|
|
$available_languages = array_diff(scandir(QVITTERDIR.'/locale'), array('..', '.'));
|
2015-06-18 21:24:37 +09:00
|
|
|
|
foreach($available_languages as $lankey=>$lan) {
|
|
|
|
|
|
2015-02-25 06:36:36 +09:00
|
|
|
|
$lancode = substr($lan,0,strpos($lan,'.'));
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2015-06-19 18:46:37 +09:00
|
|
|
|
// for the paranthesis containing language region to work with rtl in ltr enviroment and vice versa, we add a
|
|
|
|
|
// special rtl or ltr html char after the paranthesis
|
|
|
|
|
// this list is incomplete, but if any rtl language gets a regional translation, it will probably be arabic
|
|
|
|
|
$rtl_or_ltr_special_char = '‎';
|
|
|
|
|
$base_lancode = substr($lancode,0,strpos($lancode,'_'));
|
|
|
|
|
if($base_lancode == 'ar'
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|| $base_lancode == 'fa'
|
2015-06-19 18:46:37 +09:00
|
|
|
|
|| $base_lancode == 'he') {
|
2015-07-02 02:15:31 +09:00
|
|
|
|
$rtl_or_ltr_special_char = '‏';
|
2015-06-19 18:46:37 +09:00
|
|
|
|
}
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2015-02-25 06:36:36 +09:00
|
|
|
|
// also make an array with all language names, to use for generating menu
|
|
|
|
|
$languagecodesandnames[$lancode]['english_name'] = Locale::getDisplayLanguage($lancode, 'en');
|
|
|
|
|
$languagecodesandnames[$lancode]['name'] = Locale::getDisplayLanguage($lancode, $lancode);
|
|
|
|
|
if(Locale::getDisplayRegion($lancode, $lancode)) {
|
2015-07-02 02:15:31 +09:00
|
|
|
|
$languagecodesandnames[$lancode]['name'] .= ' ('.Locale::getDisplayRegion($lancode, $lancode).')'.$rtl_or_ltr_special_char;
|
2015-02-25 06:36:36 +09:00
|
|
|
|
}
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2015-06-18 21:24:37 +09:00
|
|
|
|
// ahorita meme only on quitter.es
|
|
|
|
|
if($lancode == 'es_ahorita') {
|
|
|
|
|
if($siterootdomain == 'quitter.es') {
|
2015-07-02 02:15:31 +09:00
|
|
|
|
$languagecodesandnames[$lancode]['name'] = 'español (ahorita)';
|
2015-06-18 21:24:37 +09:00
|
|
|
|
}
|
|
|
|
|
else {
|
|
|
|
|
unset($available_languages[$lankey]);
|
|
|
|
|
unset($languagecodesandnames[$lancode]);
|
|
|
|
|
continue;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
print "\n".' "'.$lancode.'": "'.$lan.'?changed='.date('YmdHis',filemtime(QVITTERDIR.'/locale/'.$lan)).'",';
|
2015-07-02 02:15:31 +09:00
|
|
|
|
}
|
2015-02-25 06:36:36 +09:00
|
|
|
|
?>
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2015-02-25 06:36:36 +09:00
|
|
|
|
};
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2014-05-14 16:46:07 +09:00
|
|
|
|
</script>
|
2015-03-03 08:33:18 +09:00
|
|
|
|
<?php
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2015-03-03 08:33:18 +09:00
|
|
|
|
// event for other plugins to use to add head elements to qvitter
|
2015-07-02 02:15:31 +09:00
|
|
|
|
Event::handle('QvitterEndShowHeadElements', array($this));
|
|
|
|
|
|
2015-03-03 08:33:18 +09:00
|
|
|
|
?>
|
2014-05-14 16:46:07 +09:00
|
|
|
|
</head>
|
|
|
|
|
<body style="background-color:<?php print QvitterPlugin::settings("defaultbackgroundcolor"); ?>">
|
2015-08-07 04:32:32 +09:00
|
|
|
|
<?php
|
|
|
|
|
|
|
|
|
|
// add an accessibility toggle link to switch to standard UI, if we're logged in
|
|
|
|
|
if($logged_in_user) {
|
|
|
|
|
print '<a id="accessibility-toggle-link" href="#"></a>';
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
?>
|
2015-11-17 04:27:40 +09:00
|
|
|
|
<input id="upload-image-input" class="upload-image-input" type="file" name="upload-image-input">
|
2014-05-14 16:46:07 +09:00
|
|
|
|
<div class="topbar">
|
2015-08-25 20:27:14 +09:00
|
|
|
|
<a href="<?php
|
|
|
|
|
|
|
|
|
|
// if we're logged in, the logo links to the home stream
|
|
|
|
|
// if logged out it links to the site's public stream
|
|
|
|
|
if($logged_in_user) {
|
|
|
|
|
print $instanceurl.$logged_in_user_nickname.'/all';
|
|
|
|
|
}
|
|
|
|
|
else {
|
|
|
|
|
print $instanceurl.'main/public';
|
|
|
|
|
}
|
|
|
|
|
|
2015-11-05 20:34:12 +09:00
|
|
|
|
?>"><div id="logo"></div></a><?php
|
|
|
|
|
|
|
|
|
|
// menu for logged in users
|
|
|
|
|
if($logged_in_user) { ?>
|
|
|
|
|
<a id="settingslink">
|
|
|
|
|
<div class="dropdown-toggle">
|
2015-11-16 23:42:53 +09:00
|
|
|
|
<div class="nav-session" style="background-image:url('<?php print htmlspecialchars($logged_in_user_obj['profile_image_url_profile_size']) ?>')"></div>
|
2015-11-05 20:34:12 +09:00
|
|
|
|
</div>
|
|
|
|
|
</a><?php
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
?><div id="top-compose" class="hidden"></div>
|
2014-05-14 16:46:07 +09:00
|
|
|
|
<ul class="quitter-settings dropdown-menu">
|
|
|
|
|
<li class="dropdown-caret right">
|
|
|
|
|
<span class="caret-outer"></span>
|
|
|
|
|
<span class="caret-inner"></span>
|
|
|
|
|
</li>
|
2014-11-24 21:47:45 +09:00
|
|
|
|
<li class="fullwidth"><a id="logout"></a></li>
|
|
|
|
|
<li class="fullwidth dropdown-divider"></li>
|
2015-07-02 02:15:31 +09:00
|
|
|
|
<li class="fullwidth"><a id="edit-profile-header-link"></a></li>
|
|
|
|
|
<li class="fullwidth"><a id="settings" href="<?php print $instanceurl; ?>settings/profile" donthijack></a></li>
|
|
|
|
|
<li class="fullwidth"><a id="faq-link"></a></li>
|
|
|
|
|
<li class="fullwidth"><a id="shortcuts-link"></a></li>
|
2014-12-10 10:25:37 +09:00
|
|
|
|
<?php if (common_config('invite', 'enabled') && !common_config('site', 'closed')) { ?>
|
2014-12-09 10:24:23 +09:00
|
|
|
|
<li class="fullwidth"><a id="invite-link" href="<?php print $instanceurl; ?>main/invite"></a></li>
|
2015-07-02 02:15:31 +09:00
|
|
|
|
<?php } ?>
|
|
|
|
|
<li class="fullwidth"><a id="classic-link"></a></li>
|
2015-02-25 06:36:36 +09:00
|
|
|
|
<li class="fullwidth language dropdown-divider"></li>
|
|
|
|
|
<?php
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2015-02-25 06:36:36 +09:00
|
|
|
|
// languages
|
|
|
|
|
foreach($languagecodesandnames as $lancode=>$lan) {
|
|
|
|
|
print '<li class="language"><a class="language-link" title="'.$lan['english_name'].'" data-lang-code="'.$lancode.'">'.$lan['name'].'</a></li>';
|
|
|
|
|
}
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
|
|
|
|
?>
|
2016-01-18 23:26:54 +09:00
|
|
|
|
<li class="fullwidth language dropdown-divider"></li>
|
|
|
|
|
<li class="fullwidth"><a href="https://git.gnu.io/h2p/Qvitter/tree/master/locale" target="_blank" id="add-edit-language-link"></a></li>
|
2015-07-02 02:15:31 +09:00
|
|
|
|
</ul>
|
2014-05-14 16:46:07 +09:00
|
|
|
|
<div class="global-nav">
|
|
|
|
|
<div class="global-nav-inner">
|
2015-07-02 02:15:31 +09:00
|
|
|
|
<div class="container">
|
2014-05-14 16:46:07 +09:00
|
|
|
|
<div id="search">
|
|
|
|
|
<input type="text" spellcheck="false" autocomplete="off" name="q" placeholder="Sök" id="search-query" class="search-input">
|
|
|
|
|
<span class="search-icon">
|
|
|
|
|
<button class="icon nav-search" type="submit" tabindex="-1">
|
|
|
|
|
<span> Sök </span>
|
2015-07-02 02:15:31 +09:00
|
|
|
|
</button>
|
2014-05-14 16:46:07 +09:00
|
|
|
|
</span>
|
2015-07-02 02:15:31 +09:00
|
|
|
|
</div>
|
2014-05-14 16:46:07 +09:00
|
|
|
|
<ul class="language-dropdown">
|
|
|
|
|
<li class="dropdown">
|
|
|
|
|
<a class="dropdown-toggle">
|
|
|
|
|
<small></small>
|
|
|
|
|
<span class="current-language"></span>
|
|
|
|
|
<b class="caret"></b>
|
|
|
|
|
</a>
|
|
|
|
|
<ul class="dropdown-menu">
|
|
|
|
|
<li class="dropdown-caret right">
|
|
|
|
|
<span class="caret-outer"></span>
|
|
|
|
|
<span class="caret-inner"></span>
|
|
|
|
|
</li>
|
2015-02-25 06:36:36 +09:00
|
|
|
|
<?php
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2015-02-25 06:36:36 +09:00
|
|
|
|
// languages
|
|
|
|
|
foreach($languagecodesandnames as $lancode=>$lan) {
|
|
|
|
|
print '<li><a class="language-link" title="'.$lan['english_name'].'" data-lang-code="'.$lancode.'">'.$lan['name'].'</a></li>';
|
|
|
|
|
}
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
|
|
|
|
?>
|
2016-01-18 23:26:54 +09:00
|
|
|
|
<li class="fullwidth language dropdown-divider"></li>
|
|
|
|
|
<li class="fullwidth"><a href="https://git.gnu.io/h2p/Qvitter/tree/master/locale" target="_blank" id="add-edit-language-link"></a></li>
|
2014-05-14 16:46:07 +09:00
|
|
|
|
</ul>
|
|
|
|
|
</li>
|
2015-07-02 02:15:31 +09:00
|
|
|
|
</ul>
|
2014-05-14 16:46:07 +09:00
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
2015-11-17 04:27:40 +09:00
|
|
|
|
<div id="no-js-error">Please enable javascript to use this site.<script>var element = document.getElementById('no-js-error'); element.parentNode.removeChild(element);</script></div>
|
2014-05-14 16:46:07 +09:00
|
|
|
|
<div id="page-container">
|
2014-09-25 06:20:35 +09:00
|
|
|
|
<?php
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2014-09-25 06:20:35 +09:00
|
|
|
|
$site_notice = common_config('site', 'notice');
|
|
|
|
|
if(!empty($site_notice)) {
|
|
|
|
|
print '<div id="site-notice">'.common_config('site', 'notice').'</div>';
|
2015-07-02 02:15:31 +09:00
|
|
|
|
}
|
|
|
|
|
|
2015-12-04 00:06:02 +09:00
|
|
|
|
// welcome text, login and register container if logged out
|
|
|
|
|
if($logged_in_user === null) { ?>
|
|
|
|
|
<div class="front-welcome-text <?php if ($registrationsclosed) { print 'registrations-closed'; } ?>"></div>
|
|
|
|
|
<div id="login-register-container">
|
|
|
|
|
<div id="login-content">
|
|
|
|
|
<form id="form_login" class="form_settings" action="<?php print common_local_url('qvitterlogin'); ?>" method="post">
|
|
|
|
|
<div id="username-container">
|
|
|
|
|
<input id="nickname" name="nickname" type="text" value="<?php print $logged_in_user_nickname ?>" tabindex="1" />
|
|
|
|
|
</div>
|
|
|
|
|
<table class="password-signin"><tbody><tr>
|
|
|
|
|
<td class="flex-table-primary">
|
|
|
|
|
<div class="placeholding-input">
|
|
|
|
|
<input id="password" name="password" type="password" tabindex="2" value="" />
|
|
|
|
|
</div>
|
|
|
|
|
</td>
|
|
|
|
|
<td class="flex-table-secondary">
|
|
|
|
|
<button class="submit" type="submit" id="submit-login" tabindex="4"></button>
|
|
|
|
|
</td>
|
|
|
|
|
</tr></tbody></table>
|
|
|
|
|
<div id="remember-forgot">
|
|
|
|
|
<input type="checkbox" id="rememberme" name="rememberme" value="yes" tabindex="3" checked="checked"> <span id="rememberme_label"></span> · <a id="forgot-password" href="<?php print $instanceurl ?>main/recoverpassword" ></a>
|
|
|
|
|
<input type="hidden" id="token" name="token" value="<?php print common_session_token(); ?>">
|
|
|
|
|
<?php
|
|
|
|
|
|
|
|
|
|
if (array_key_exists('OpenID', StatusNet::getActivePlugins())) {
|
|
|
|
|
print '<a href="'.$instanceurl.'main/openid" id="openid-login" title="OpenID" donthijack>OpenID</a>';
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
?>
|
|
|
|
|
</div>
|
|
|
|
|
</form>
|
|
|
|
|
</div>
|
|
|
|
|
<?php
|
|
|
|
|
if($registrationsclosed === false && $client_ip_is_blocked === false) {
|
|
|
|
|
?><div class="front-signup">
|
|
|
|
|
<h2></h2>
|
|
|
|
|
<div class="signup-input-container"><input placeholder="" type="text" name="user[name]" autocomplete="off" class="text-input" id="signup-user-name"></div>
|
|
|
|
|
<div class="signup-input-container"><input placeholder="" type="text" name="user[email]" autocomplete="off" id="signup-user-email"></div>
|
|
|
|
|
<div class="signup-input-container"><input placeholder="" type="password" name="user[user_password]" class="text-input" id="signup-user-password"></div>
|
|
|
|
|
<button id="signup-btn-step1" class="signup-btn" type="submit"></button>
|
|
|
|
|
</div>
|
|
|
|
|
<div id="other-servers-link"></div><?php }
|
|
|
|
|
?><div id="qvitter-notice-logged-out"><?php print common_config('site', 'qvitternoticeloggedout'); ?></div>
|
|
|
|
|
</div><?php
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// box containing the logged in users queet count and compose form
|
|
|
|
|
if($logged_in_user) { ?>
|
|
|
|
|
<div id="user-container" style="display:none;">
|
2015-11-16 23:42:53 +09:00
|
|
|
|
<div id="user-header" style="background-image:url('<?php print htmlspecialchars($logged_in_user_obj['cover_photo']) ?>')">
|
2015-11-05 20:34:12 +09:00
|
|
|
|
<div id="mini-edit-profile-button"></div>
|
|
|
|
|
<div class="profile-header-inner-overlay"></div>
|
2015-11-16 23:42:53 +09:00
|
|
|
|
<div id="user-avatar-container"><img id="user-avatar" src="<?php print htmlspecialchars($logged_in_user_obj['profile_image_url_profile_size']) ?>" /></div>
|
|
|
|
|
<div id="user-name"><?php print htmlspecialchars($logged_in_user_obj['name']) ?></div>
|
|
|
|
|
<div id="user-screen-name"><?php print htmlspecialchars($logged_in_user_obj['screen_name']) ?></div>
|
2015-11-05 20:34:12 +09:00
|
|
|
|
</div>
|
|
|
|
|
<ul id="user-body">
|
|
|
|
|
<li><a href="<?php print $instanceurl.$logged_in_user->nickname ?>" id="user-queets"><span class="label"></span><strong><?php print $logged_in_user_obj['statuses_count'] ?></strong></a></li>
|
|
|
|
|
<li><a href="<?php print $instanceurl.$logged_in_user->nickname ?>/subscriptions" id="user-following"><span class="label"></span><strong><?php print $logged_in_user_obj['friends_count'] ?></strong></a></li>
|
|
|
|
|
<li><a href="<?php print $instanceurl.$logged_in_user->nickname ?>/groups" id="user-groups"><span class="label"></span><strong><?php print $logged_in_user_obj['groups_count'] ?></strong></a></li>
|
|
|
|
|
</ul>
|
|
|
|
|
<div id="user-footer">
|
|
|
|
|
<div id="user-footer-inner">
|
|
|
|
|
<div id="queet-box" class="queet-box queet-box-syntax" data-start-text=""></div>
|
|
|
|
|
<div class="syntax-middle"></div>
|
|
|
|
|
<div class="syntax-two" contenteditable="true"></div>
|
|
|
|
|
<div class="mentions-suggestions"></div>
|
|
|
|
|
<div class="queet-toolbar">
|
|
|
|
|
<div class="queet-box-extras">
|
|
|
|
|
<button class="upload-image"></button>
|
|
|
|
|
<button class="shorten disabled">URL</button>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="queet-button">
|
|
|
|
|
<span class="queet-counter"></span>
|
|
|
|
|
<button></button>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
2015-12-04 00:06:02 +09:00
|
|
|
|
</div>
|
|
|
|
|
<div id="main-menu" class="menu-container"><?php
|
|
|
|
|
|
|
|
|
|
if($logged_in_user) {
|
|
|
|
|
?><a href="<?php print $instanceurl.$logged_in_user->nickname ?>/all" class="stream-selection friends-timeline"><i class="chev-right"></i></a>
|
|
|
|
|
<a href="<?php print $instanceurl.$logged_in_user->nickname ?>/notifications" class="stream-selection notifications"><span id="unseen-notifications"></span><i class="chev-right"></i></a>
|
|
|
|
|
<a href="<?php print $instanceurl.$logged_in_user->nickname ?>/replies" class="stream-selection mentions"><i class="chev-right"></i></a>
|
|
|
|
|
<a href="<?php print $instanceurl.$logged_in_user->nickname ?>" class="stream-selection my-timeline"><i class="chev-right"></i></a>
|
|
|
|
|
<a href="<?php print $instanceurl.$logged_in_user->nickname ?>/favorites" class="stream-selection favorites"><i class="chev-right"></i></a>
|
|
|
|
|
<a href="<?php print $instanceurl ?>main/public" class="stream-selection public-timeline"><i class="chev-right"></i></a>
|
|
|
|
|
<a href="<?php print $instanceurl ?>main/all" class="stream-selection public-and-external-timeline"><i class="chev-right"></i></a>
|
|
|
|
|
<?php
|
|
|
|
|
}
|
|
|
|
|
?>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="menu-container" id="bookmark-container"></div>
|
|
|
|
|
<div class="menu-container" id="history-container"></div>
|
|
|
|
|
<div id="clear-history"></div>
|
|
|
|
|
<div id="qvitter-notice"><?php print common_config('site', 'qvitternotice'); ?></div>
|
|
|
|
|
</div><?php
|
|
|
|
|
} ?>
|
|
|
|
|
|
|
|
|
|
<div id="feed">
|
2014-05-14 16:46:07 +09:00
|
|
|
|
<div id="feed-header">
|
|
|
|
|
<div id="feed-header-inner">
|
|
|
|
|
<h2></h2>
|
2015-07-02 02:15:31 +09:00
|
|
|
|
<div class="reload-stream"></div>
|
2014-05-14 16:46:07 +09:00
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div id="new-queets-bar-container" class="hidden"><div id="new-queets-bar"></div></div>
|
|
|
|
|
<div id="feed-body"></div>
|
|
|
|
|
</div>
|
2015-10-21 20:16:45 +09:00
|
|
|
|
<div id="hidden-html"><?php
|
|
|
|
|
|
|
|
|
|
// adds temporary support for microformats and linkbacks on the notice page
|
|
|
|
|
if(substr($_SERVER['REQUEST_URI'],0,8) == '/notice/' && $this->arg('notice')) {
|
|
|
|
|
echo '<ol class="notices xoxo">';
|
|
|
|
|
$notice = Notice::getKV('id', $this->arg('notice'));
|
|
|
|
|
if($notice instanceof Notice) {
|
|
|
|
|
$widget = new NoticeListItem($notice, $this);
|
|
|
|
|
$widget->show();
|
|
|
|
|
$this->flush();
|
|
|
|
|
}
|
|
|
|
|
echo '</ol>';
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Event::handle('QvitterHiddenHtml', array($this));
|
|
|
|
|
|
|
|
|
|
?></div>
|
2014-11-24 21:47:45 +09:00
|
|
|
|
<div id="footer"><div id="footer-spinner-container"></div></div>
|
|
|
|
|
</div>
|
2015-06-02 01:27:36 +09:00
|
|
|
|
<script type="text/javascript" src="<?php print $qvitterpath; ?>js/lib/jquery-2.1.4.min.js?changed=<?php print date('YmdHis',filemtime(QVITTERDIR.'/js/lib/jquery-2.1.4.min.js')); ?>"></script>
|
2015-09-22 02:08:06 +09:00
|
|
|
|
<script type="text/javascript" src="<?php print $qvitterpath; ?>js/lib/jquery-ui.min.js?changed=<?php print date('YmdHis',filemtime(QVITTERDIR.'/js/lib/jquery-ui.min.js')); ?>"></script>
|
2015-07-02 02:15:31 +09:00
|
|
|
|
<script type="text/javascript" src="<?php print $qvitterpath; ?>js/lib/jquery.minicolors.min.js?changed=<?php print date('YmdHis',filemtime(QVITTERDIR.'/js/lib/jquery.minicolors.min.js')); ?>"></script>
|
|
|
|
|
<script type="text/javascript" src="<?php print $qvitterpath; ?>js/lib/jquery.jWindowCrop.js?changed=<?php print date('YmdHis',filemtime(QVITTERDIR.'/js/lib/jquery.jWindowCrop.js')); ?>"></script>
|
2015-06-02 01:27:36 +09:00
|
|
|
|
<script type="text/javascript" src="<?php print $qvitterpath; ?>js/lib/load-image.min.js?changed=<?php print date('YmdHis',filemtime(QVITTERDIR.'/js/lib/load-image.min.js')); ?>"></script>
|
2015-08-12 00:53:58 +09:00
|
|
|
|
<script type="text/javascript" src="<?php print $qvitterpath; ?>js/lib/xregexp-all-3.0.0-pre.js?changed=<?php print date('YmdHis',filemtime(QVITTERDIR.'/js/lib/xregexp-all-3.0.0-pre.js')); ?>"></script>
|
2015-09-22 01:30:37 +09:00
|
|
|
|
<script type="text/javascript" src="<?php print $qvitterpath; ?>js/lib/lz-string.js?changed=<?php print date('YmdHis',filemtime(QVITTERDIR.'/js/lib/lz-string.js')); ?>"></script>
|
2015-11-17 00:09:01 +09:00
|
|
|
|
<script type="text/javascript" src="<?php print $qvitterpath; ?>js/lib/bowser.min.js?changed=<?php print date('YmdHis',filemtime(QVITTERDIR.'/js/lib/bowser.min.js')); ?>"></script>
|
2015-06-02 20:53:36 +09:00
|
|
|
|
<script charset="utf-8" type="text/javascript" src="<?php print $qvitterpath; ?>js/dom-functions.js?changed=<?php print date('YmdHis',filemtime(QVITTERDIR.'/js/dom-functions.js')); ?>"></script>
|
|
|
|
|
<script charset="utf-8" type="text/javascript" src="<?php print $qvitterpath; ?>js/misc-functions.js?changed=<?php print date('YmdHis',filemtime(QVITTERDIR.'/js/misc-functions.js')); ?>"></script>
|
|
|
|
|
<script charset="utf-8" type="text/javascript" src="<?php print $qvitterpath; ?>js/ajax-functions.js?changed=<?php print date('YmdHis',filemtime(QVITTERDIR.'/js/ajax-functions.js')); ?>"></script>
|
2015-09-18 08:42:52 +09:00
|
|
|
|
<script charset="utf-8" type="text/javascript" src="<?php print $qvitterpath; ?>js/stream-router.js?changed=<?php print date('YmdHis',filemtime(QVITTERDIR.'/js/stream-router.js')); ?>"></script>
|
2015-06-02 20:53:36 +09:00
|
|
|
|
<script charset="utf-8" type="text/javascript" src="<?php print $qvitterpath; ?>js/qvitter.js?changed=<?php print date('YmdHis',filemtime(QVITTERDIR.'/js/qvitter.js')); ?>"></script>
|
2014-11-28 05:04:41 +09:00
|
|
|
|
<?php
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2015-03-03 08:33:18 +09:00
|
|
|
|
// event for other plugins to add scripts to qvitter
|
|
|
|
|
Event::handle('QvitterEndShowScripts', array($this));
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2014-11-28 05:04:41 +09:00
|
|
|
|
// we might have custom javascript in the config file that we want to add
|
|
|
|
|
if(QvitterPlugin::settings('js')) {
|
|
|
|
|
print '<script type="text/javascript">'.QvitterPlugin::settings('js').'</script>';
|
2015-07-02 02:15:31 +09:00
|
|
|
|
}
|
|
|
|
|
|
2015-06-07 17:52:38 +09:00
|
|
|
|
?>
|
|
|
|
|
<div id="dynamic-styles">
|
|
|
|
|
<style>
|
|
|
|
|
a, a:visited, a:active,
|
|
|
|
|
ul.stats li:hover a,
|
|
|
|
|
ul.stats li:hover a strong,
|
|
|
|
|
#user-body a:hover div strong,
|
|
|
|
|
#user-body a:hover div div,
|
|
|
|
|
.permalink-link:hover,
|
|
|
|
|
.stream-item.expanded > .queet .stream-item-expand,
|
|
|
|
|
.stream-item-footer .with-icn .requeet-text a b:hover,
|
|
|
|
|
.queet-text span.attachment.more,
|
|
|
|
|
.stream-item-header .created-at a:hover,
|
|
|
|
|
.stream-item-header a.account-group:hover .name,
|
|
|
|
|
.queet:hover .stream-item-expand,
|
|
|
|
|
.show-full-conversation:hover,
|
|
|
|
|
#new-queets-bar,
|
2015-07-02 02:15:31 +09:00
|
|
|
|
.menu-container div,
|
2015-06-07 17:52:38 +09:00
|
|
|
|
.cm-mention, .cm-tag, .cm-group, .cm-url, .cm-email,
|
|
|
|
|
div.syntax-middle span,
|
|
|
|
|
#user-body strong,
|
|
|
|
|
ul.stats,
|
|
|
|
|
.stream-item:not(.temp-post) ul.queet-actions li .icon:not(.is-mine):hover:before,
|
|
|
|
|
.show-full-conversation,
|
|
|
|
|
#user-body #user-queets:hover .label,
|
2015-07-02 02:15:31 +09:00
|
|
|
|
#user-body #user-groups:hover .label,
|
2015-06-07 17:52:38 +09:00
|
|
|
|
#user-body #user-following:hover .label,
|
|
|
|
|
ul.stats a strong,
|
|
|
|
|
.queet-box-extras button,
|
2015-08-26 07:11:31 +09:00
|
|
|
|
#openid-login:hover:after,
|
|
|
|
|
.post-to-group {
|
2015-06-07 17:52:38 +09:00
|
|
|
|
color:/*COLORSTART*/<?php print QvitterPlugin::settings("defaultlinkcolor"); ?>/*COLOREND*/;
|
2015-07-02 02:15:31 +09:00
|
|
|
|
}
|
2015-06-07 17:52:38 +09:00
|
|
|
|
#unseen-notifications,
|
2015-11-26 04:11:59 +09:00
|
|
|
|
.stream-item.notification.not-seen > .queet::before,
|
2015-06-07 17:52:38 +09:00
|
|
|
|
#top-compose,
|
|
|
|
|
#logo,
|
|
|
|
|
.queet-toolbar button,
|
|
|
|
|
#user-header,
|
|
|
|
|
.profile-header-inner,
|
|
|
|
|
.topbar,
|
|
|
|
|
.menu-container,
|
|
|
|
|
.member-button.member,
|
|
|
|
|
.external-follow-button.following,
|
|
|
|
|
.qvitter-follow-button.following,
|
|
|
|
|
.save-profile-button,
|
|
|
|
|
.crop-and-save-button,
|
|
|
|
|
.topbar .global-nav.show-logo:before,
|
2015-11-18 06:48:28 +09:00
|
|
|
|
.topbar .global-nav.pulse-logo:before,
|
|
|
|
|
.dropdown-menu li:not(.dropdown-caret) a:hover {
|
2015-06-07 17:52:38 +09:00
|
|
|
|
background-color:/*BACKGROUNDCOLORSTART*/<?php print QvitterPlugin::settings("defaultlinkcolor"); ?>/*BACKGROUNDCOLOREND*/;
|
2015-07-02 02:15:31 +09:00
|
|
|
|
}
|
|
|
|
|
.queet-box-syntax[contenteditable="true"]:focus,
|
|
|
|
|
.stream-item.selected-by-keyboard::before {
|
2015-06-07 17:52:38 +09:00
|
|
|
|
border-color:/*BORDERCOLORSTART*/#999999/*BORDERCOLOREND*/;
|
|
|
|
|
}
|
|
|
|
|
#user-footer-inner,
|
|
|
|
|
.inline-reply-queetbox,
|
|
|
|
|
#popup-faq #faq-container p.indent {
|
|
|
|
|
background-color:/*LIGHTERBACKGROUNDCOLORSTART*/rgb(205,230,239)/*LIGHTERBACKGROUNDCOLOREND*/;
|
|
|
|
|
}
|
|
|
|
|
#user-footer-inner,
|
|
|
|
|
.queet-box,
|
|
|
|
|
.queet-box-syntax[contenteditable="true"],
|
|
|
|
|
.inline-reply-queetbox,
|
|
|
|
|
span.inline-reply-caret,
|
|
|
|
|
.stream-item.expanded .stream-item.first-visible-after-parent,
|
2015-08-26 07:11:31 +09:00
|
|
|
|
#popup-faq #faq-container p.indent,
|
2016-01-07 11:03:18 +09:00
|
|
|
|
.post-to-group,
|
|
|
|
|
.quoted-notice:hover,
|
|
|
|
|
.stream-item:hover:not(.expanded) .quoted-notice:hover {
|
2015-06-07 17:52:38 +09:00
|
|
|
|
border-color:/*LIGHTERBORDERCOLORSTART*/rgb(155,206,224)/*LIGHTERBORDERCOLOREND*/;
|
|
|
|
|
}
|
|
|
|
|
span.inline-reply-caret .caret-inner {
|
|
|
|
|
border-bottom-color:/*LIGHTERBORDERBOTTOMCOLORSTART*/rgb(205,230,239)/*LIGHTERBORDERBOTTOMCOLOREND*/;
|
|
|
|
|
}
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2015-06-07 17:52:38 +09:00
|
|
|
|
.modal-close .icon,
|
|
|
|
|
.chev-right,
|
|
|
|
|
.close-right,
|
|
|
|
|
button.icon.nav-search,
|
|
|
|
|
.member-button .join-text i,
|
|
|
|
|
.external-member-button .join-text i,
|
|
|
|
|
.external-follow-button .follow-text i,
|
|
|
|
|
.qvitter-follow-button .follow-text i,
|
|
|
|
|
#logo,
|
|
|
|
|
.upload-cover-photo,
|
|
|
|
|
.upload-avatar,
|
|
|
|
|
.upload-background-image,
|
|
|
|
|
button.shorten i,
|
|
|
|
|
.reload-stream,
|
|
|
|
|
.topbar .global-nav:before,
|
2015-07-02 02:15:31 +09:00
|
|
|
|
.stream-item.notification.repeat .dogear,
|
2015-06-07 17:52:38 +09:00
|
|
|
|
.stream-item.notification.like .dogear,
|
|
|
|
|
.ostatus-link,
|
|
|
|
|
.close-edit-profile-window {
|
2015-07-02 02:15:31 +09:00
|
|
|
|
background-image: url("<?php print QvitterPlugin::settings("sprite"); ?>");
|
|
|
|
|
background-size: 500px 1329px;
|
2015-06-07 17:52:38 +09:00
|
|
|
|
}
|
2015-07-02 02:15:31 +09:00
|
|
|
|
@media (max-width: 910px) {
|
2015-06-07 17:52:38 +09:00
|
|
|
|
#search-query,
|
|
|
|
|
.menu-container a,
|
|
|
|
|
.menu-container a.current,
|
|
|
|
|
.stream-selection.friends-timeline:after,
|
|
|
|
|
.stream-selection.notifications:after,
|
2015-07-02 02:15:31 +09:00
|
|
|
|
.stream-selection.my-timeline:after,
|
|
|
|
|
.stream-selection.public-timeline:after {
|
|
|
|
|
background-image: url("<?php print QvitterPlugin::settings("sprite"); ?>");
|
2015-06-07 17:52:38 +09:00
|
|
|
|
background-size: 500px 1329px;
|
2015-07-02 02:15:31 +09:00
|
|
|
|
}
|
2015-06-07 17:52:38 +09:00
|
|
|
|
}
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2015-06-07 17:52:38 +09:00
|
|
|
|
</style>
|
|
|
|
|
</div>
|
2014-05-14 16:46:07 +09:00
|
|
|
|
</body>
|
|
|
|
|
</html>
|
|
|
|
|
|
2015-07-02 02:15:31 +09:00
|
|
|
|
|
2014-05-15 20:25:18 +09:00
|
|
|
|
<?php
|
2014-05-14 16:46:07 +09:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|