// If set to true the priority settings of ostatus contacts are used
$a->config['system']['ostatus_use_priority'] = false;
-// If enabled all items are cached in the given directory
+// If enabled, all items are cached in the given directory
$a->config['system']['itemcache'] = "";
+
+// If enabled, the lockpath is used for a lockfile to check if the poller is running
+$a->config['system']['lockpath'] = "";
$Text);
// [img=widthxheight]image source[/img]
- $Text = preg_replace("/\[img\=([0-9]*)x([0-9]*)\](.*?)\[\/img\]/ism", '<img src="$3" style="height: $2px; width: $1px;" >', $Text);
+ //$Text = preg_replace("/\[img\=([0-9]*)x([0-9]*)\](.*?)\[\/img\]/ism", '<img src="$3" style="height: $2px; width: $1px;" >', $Text);
+ $Text = preg_replace("/\[img\=([0-9]*)x([0-9]*)\](.*?)\[\/img\]/ism", '<img src="$3" style="width: $1px;" >', $Text);
// Images
// [img]pathtoimage[/img]
$urls = array();
foreach ($result as $treffer) {
// A list of some links that should be ignored
- $list = array("/user/", "/tag/", "/profile/", "/search?search=", "mailto:", "/u/", "/node/",
+ $list = array("/user/", "/tag/", "/group/", "/profile/", "/search?search=", "mailto:", "/u/", "/node/",
"//facebook.com/profile.php?id=", "//plus.google.com/");
foreach ($list as $listitem)
if (strpos($treffer[1], $listitem) !== false)
$ignore = true;
+ if ((strpos($treffer[1], "//plus.google.com/") !== false) and (strpos($treffer[1], "/posts") !== false))
+ $ignore = false;
+
if (!$ignore)
$urls[$treffer[1]] = $treffer[1];
}
--- /dev/null
+<?php
+class pidfile {
+ private $_file;
+ private $_running;
+
+ public function __construct($dir, $name) {
+ $this->_file = "$dir/$name.pid";
+
+ if (file_exists($this->_file)) {
+ $pid = trim(file_get_contents($this->_file));
+ if (posix_kill($pid, 0)) {
+ $this->_running = true;
+ }
+ }
+
+ if (! $this->_running) {
+ $pid = getmypid();
+ file_put_contents($this->_file, $pid);
+ }
+ }
+
+ public function __destruct() {
+ if ((! $this->_running) && file_exists($this->_file)) {
+ unlink($this->_file);
+ }
+ }
+
+ public function is_already_running() {
+ return $this->_running;
+ }
+}
+?>
require_once('include/Contact.php');
require_once('include/email.php');
require_once('include/socgraph.php');
+ require_once('include/pidfile.php');
load_config('config');
load_config('system');
+ $lockpath = get_config('system','lockpath');
+ if ($lockpath != '') {
+ $pidfile = new pidfile($lockpath, 'poller.lck');
+ if($pidfile->is_already_running()) {
+ logger("poller: Already running");
+ exit;
+ }
+ }
+
$a->set_baseurl(get_config('system','url'));
load_hooks();
--- /dev/null
+<ok>$ok</ok>
#photos-upload-newalbum-div {
float: left;
width: 175px;
-}
\ No newline at end of file
+}
#photos-upload-newalbum-div {
float: left;
width: 175px;
-}
\ No newline at end of file
+}
#photos-upload-newalbum-div {
float: left;
width: 175px;
-}
\ No newline at end of file
+}
#photos-upload-newalbum-div {
float: left;
width: 175px;
-}
\ No newline at end of file
+}
.tools { background-position: -50px -40px;}
.lock { background-position: -70px -40px;}
+.unlock { background-position: -90px -40px;}
.video { background-position: -110px -40px;}
.youtube { background-position: -130px -40px;}
.icon {
display: block;
- width: 20px;
- height: 20px;
+ width: 18px;
+ height: 18px;
background-image: url('icons.png');
}
background: #EEE;
}
.tool .label {
- float: left;
+/* float: left; */
}
.tool .action {
float: right;
}
.tool a {
- color: #000;
+/* color: #000; */
}
.tool a:hover {
- text-decoration: none;
+ text-decoration: underline;
+}
+.sidebar-group-element {
+/* color: #000; */
}
+
/* popup notifications */
div.jGrowl div.notice {
background: #511919 url("../../../images/icons/48/notice.png") no-repeat 5px center;
#jot #jot-tools li.loading img {
margin-top: 10px;
}
-#jot #jot-title {
+/* #jot */
+#jot-title {
border: 0px;
margin: 0px;
height: 20px;
line-height: 20px;
padding-right: 20px;
}
+
+#profile-jot-submit {
+ float: right;
+ margin-left: 15px;
+}
+#profile-upload-wrapper {
+ float: left;
+ margin-left: 15px;
+}
+#profile-attach-wrapper {
+ float: left;
+ margin-left: 15px;
+}
+#profile-link-wrapper {
+ float: left;
+ margin-left: 15px;
+}
+#profile-video-wrapper {
+ float: left;
+ margin-left: 15px;
+}
+#profile-audio-wrapper {
+ float: left;
+ margin-left: 15px;
+}
+#profile-location-wrapper {
+ float: left;
+ margin-left: 15px;
+}
+#profile-nolocation-wrapper {
+ float: left;
+ margin-left: 15px;
+}
+#jot-perms-icon {
+ float: right;
+ margin-left: 15px;
+}
+#jot-preview-link {
+ float: right;
+}
+#profile-jot-end {
+ clear: both;
+}
+#profile-jot-text_tbl {
+ width: 800px;
+}
+#profile-jot-wrapper {
+ margin-bottom: 20px;
+}
+
/** buttons **/
/*input[type="submit"] {
border: 0px;