Commit f0b3176d authored by mose's avatar mose

Instant-Auto-Merge from BRANCH-1-9 to HEAD

parent d04509e7
......@@ -719,6 +719,7 @@ tiki/doc/devtools/extract-img-db-to-fs.php -text
tiki/doc/devtools/ggg-trace.php -text
tiki/doc/devtools/index.php -text
tiki/doc/devtools/lastcvs.sh -text
tiki/doc/devtools/mergelang.pl -text
tiki/doc/devtools/phpstrip.sh -text
tiki/doc/devtools/restorehelp.php -text
tiki/doc/devtools/sharetiki.sh -text
......@@ -2064,6 +2065,7 @@ tiki/lib/rss/atom-style.css -text svneol=unset#application/octet-stream
tiki/lib/rss/index.php -text
tiki/lib/rss/rss-style.css -text svneol=unset#application/octet-stream
tiki/lib/rss/rsslib.php -text
tiki/lib/score/events.php -text
tiki/lib/score/index.php -text
tiki/lib/score/scorelib.php -text
tiki/lib/search/index.php -text
......
<?php
// $Header: /cvsroot/tikiwiki/tiki/article_image.php,v 1.9 2004-03-28 07:32:22 mose Exp $
// $Header: /cvsroot/tikiwiki/tiki/article_image.php,v 1.10 2004-06-28 16:16:24 mose Exp $
// Copyright (c) 2002-2004, Luis Argerich, Garland Foster, Eduardo Polidor, et. al.
// All Rights Reserved. See copyright.txt for details and a complete list of authors.
// Licensed under the GNU LESSER GENERAL PUBLIC LICENSE. See license.txt for details.
# $Header: /cvsroot/tikiwiki/tiki/article_image.php,v 1.9 2004-03-28 07:32:22 mose Exp $
# $Header: /cvsroot/tikiwiki/tiki/article_image.php,v 1.10 2004-06-28 16:16:24 mose Exp $
// application to display an image from the database with
// option to resize the image dynamically creating a thumbnail on the fly.
......@@ -14,7 +14,12 @@ if (!isset($_REQUEST["id"])) {
die;
}
$topiccachefile = "temp" . "/article.".$_REQUEST["id"];
include_once ('lib/init/initlib.php');
include_once ('db/tiki-db.php');
$topiccachefile = "temp";
if ($tikidomain) { $topiccachefile.= "/$tikidomain"; }
$topiccachefile.= "/article.".$_REQUEST["id"];
if (is_file($topiccachefile) and (!isset($_REQUEST["reload"]))) {
$size = getimagesize($topiccachefile);
......@@ -22,8 +27,6 @@ if (is_file($topiccachefile) and (!isset($_REQUEST["reload"]))) {
readfile($topiccachefile);
die();
} else {
include_once ('lib/init/initlib.php');
include_once ('db/tiki-db.php');
include_once ('lib/tikilib.php');
$tikilib = new Tikilib($dbTiki);
$data = $tikilib->get_article_image($_REQUEST["id"]);
......
<?php
// $Header: /cvsroot/tikiwiki/tiki/banner_image.php,v 1.8 2004-04-28 13:05:14 mose Exp $
// $Header: /cvsroot/tikiwiki/tiki/banner_image.php,v 1.9 2004-06-28 16:16:24 mose Exp $
// Copyright (c) 2002-2004, Luis Argerich, Garland Foster, Eduardo Polidor, et. al.
// All Rights Reserved. See copyright.txt for details and a complete list of authors.
// Licensed under the GNU LESSER GENERAL PUBLIC LICENSE. See license.txt for details.
# $Header: /cvsroot/tikiwiki/tiki/banner_image.php,v 1.8 2004-04-28 13:05:14 mose Exp $
# $Header: /cvsroot/tikiwiki/tiki/banner_image.php,v 1.9 2004-06-28 16:16:24 mose Exp $
// application to display an image from the database with
// option to resize the image dynamically creating a thumbnail on the fly.
......@@ -14,14 +14,17 @@ if (!isset($_REQUEST["id"])) {
die;
}
$bannercachefile = "temp" . "/banner.".$_REQUEST["id"];
include_once("lib/init/initlib.php");
include_once ('db/tiki-db.php');
$bannercachefile = "temp";
if ($tikidomain) { $bannercachefile.= "/$tikidomain"; }
$bannercachefile.= "/banner.".$_REQUEST["id"];
if (is_file($bannerchefile) and (!isset($_REQUEST["reload"]))) {
$size = getimagesize($bannercachefile);
$type = $size['mime'];
} else {
include_once("lib/init/initlib.php");
include_once ('db/tiki-db.php');
include_once ('lib/tikilib.php');
$tikilib = new Tikilib($dbTiki);
include_once ('lib/banners/bannerlib.php');
......
# $Rev$
# $Date: 2004-06-27 03:05:48 $
# $Date: 2004-06-28 16:16:24 $
# $Author: mose $
# $Name: not supported by cvs2svn $
# phpMyAdmin MySQL-Dump
......@@ -2030,7 +2030,7 @@ INSERT INTO tiki_menu_options (menuId,type,name,url,position,section,perm,groupn
INSERT INTO tiki_menu_options (menuId,type,name,url,position,section,perm,groupname) VALUES (42,'o','Admin surveys','tiki-admin_surveys.php',865,'feature_surveys','tiki_p_admin_surveys','');
INSERT INTO tiki_menu_options (menuId,type,name,url,position,section,perm,groupname) VALUES (42,'s','Newsletters','tiki-newsletters.php',900,'feature_newsletters','','');
INSERT INTO tiki_menu_options (menuId,type,name,url,position,section,perm,groupname) VALUES (42,'o','Send newsletters','tiki-send_newsletters.php',905,'feature_newsletters','tiki_p_admin_newsletters','');
INSERT INTO tiki_menu_options (menuId,type,name,url,position,section,perm,groupname) VALUES (42,'o','Send newsletters','tiki-send_newsletters.php',905,'feature_newsletters','tiki_p_send_newsletters','');
INSERT INTO tiki_menu_options (menuId,type,name,url,position,section,perm,groupname) VALUES (42,'o','Admin newsletters','tiki-admin_newsletters.php',910,'feature_newsletters','tiki_p_admin_newsletters','');
INSERT INTO tiki_menu_options (menuId,type,name,url,position,section,perm,groupname) VALUES (42,'s','Ephemerides','tiki-eph.php',950,'feature_eph','','');
......@@ -3825,7 +3825,7 @@ INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_
INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_admin_galleries', 'Can admin Image Galleries', 'editors', 'image galleries');
INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_admin_games', 'Can admin games', 'editors', 'games');
INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_admin_mailin', 'Can admin mail-in accounts', 'admin', 'tiki');
INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_admin_newsletters', 'Can admin newsletters', 'editors', 'newsletters');
INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_admin_newsletters', 'Can admin newsletters', 'admin', 'newsletters');
INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_admin_quizzes', 'Can admin quizzes', 'editors', 'quizzes');
INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_admin_received_articles', 'Can admin received articles', 'editors', 'comm');
INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_admin_received_pages', 'Can admin received pages', 'editors', 'comm');
......@@ -3908,7 +3908,7 @@ INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_
INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_rollback', 'Can rollback pages', 'editors', 'wiki');
INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_send_articles', 'Can send articles to other sites', 'editors', 'comm');
INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_send_instance', 'Can send instances after completion', 'registered', 'workflow');
INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_send_newsletters', 'Can send newsletters', 'admin', 'newsletters');
INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_send_newsletters', 'Can send newsletters', 'editors', 'newsletters');
INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_send_pages', 'Can send pages to other sites', 'registered', 'comm');
INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_sendme_articles', 'Can send articles to this site', 'registered', 'comm');
INSERT INTO users_permissions (permName, permDesc, level, type) VALUES ('tiki_p_sendme_pages', 'Can send pages to this site', 'registered', 'comm');
......@@ -4670,56 +4670,19 @@ CREATE TABLE tiki_score (
event varchar(40) NOT NULL default '',
score int(11) NOT NULL default '0',
expiration int(11) NOT NULL default '0',
category text NOT NULL,
description text NOT NULL,
ord int(11) NOT NULL default '0',
PRIMARY KEY (event),
KEY ord (ord)
) TYPE=MyISAM;
DROP TABLE IF EXISTS tiki_users_score;
CREATE TABLE tiki_users_score (
user char(40) NOT NULL default '',
event_id char(40) NOT NULL default '',
score int(11) NOT NULL default '0',
expire int(14) NOT NULL default '0',
tstamp timestamp(14) NOT NULL,
PRIMARY KEY (user,event_id),
KEY user (user,event_id,expire)
) TYPE=MyISAM;
INSERT INTO tiki_score VALUES ('login',1,0,'General','Login',1);
INSERT INTO tiki_score VALUES ('login_remain',2,60,'General','Stay logged',2);
INSERT INTO tiki_score VALUES ('profile_fill',10,0,'General','Fill each profile field',3);
INSERT INTO tiki_score VALUES ('profile_see',2,0,'General','See other user\'s profile',4);
INSERT INTO tiki_score VALUES ('profile_is_seen',1,0,'General','Have your profile seen',5);
INSERT INTO tiki_score VALUES ('friend_new',10,0,'General','Make friends (feature not available yet)',6);
INSERT INTO tiki_score VALUES ('message_receive',1,0,'General','Receive message',7);
INSERT INTO tiki_score VALUES ('message_send',2,0,'General','Send message',8);
INSERT INTO tiki_score VALUES ('article_read',2,0,'Articles','Read an article',9);
INSERT INTO tiki_score VALUES ('article_comment',5,0,'Articles','Comment an article',10);
INSERT INTO tiki_score VALUES ('article_new',20,0,'Articles','Publish an article',11);
INSERT INTO tiki_score VALUES ('article_is_read',1,0,'Articles','Have your article read',12);
INSERT INTO tiki_score VALUES ('article_is_commented',2,0,'Articles','Have your article commented',13);
INSERT INTO tiki_score VALUES ('fgallery_new',10,0,'File galleries','Create new file gallery',14);
INSERT INTO tiki_score VALUES ('fgallery_new_file',10,0,'File galleries','Upload new file to gallery',15);
INSERT INTO tiki_score VALUES ('fgallery_download',5,0,'File galleries','Download other user\'s file',16);
INSERT INTO tiki_score VALUES ('fgallery_is_downloaded',5,0,'File galleries','Have your file downloaded',17);
INSERT INTO tiki_score VALUES ('igallery_new',10,0,'Image galleries','Create a new image gallery',18);
INSERT INTO tiki_score VALUES ('igallery_new_img',6,0,'Image galleries','Upload new image to gallery',19);
INSERT INTO tiki_score VALUES ('igallery_see_img',3,0,'Image galleries','See other user\'s image',20);
INSERT INTO tiki_score VALUES ('igallery_img_seen',1,0,'Image galleries','Have your image seen',21);
INSERT INTO tiki_score VALUES ('blog_new',20,0,'Blogs','Create new blog',22);
INSERT INTO tiki_score VALUES ('blog_post',5,0,'Blogs','Post in a blog',23);
INSERT INTO tiki_score VALUES ('blog_read',2,0,'Blogs','Read other user\'s blog',24);
INSERT INTO tiki_score VALUES ('blog_comment',2,0,'Blogs','Comment other user\'s blog',25);
INSERT INTO tiki_score VALUES ('blog_is_read',3,0,'Blogs','Have your blog read',26);
INSERT INTO tiki_score VALUES ('blog_is_commented',3,0,'Blogs','Have your blog commented',27);
INSERT INTO tiki_score VALUES ('wiki_new',10,0,'Wiki','Create a new wiki page',28);
INSERT INTO tiki_score VALUES ('wiki_edit',5,0,'Wiki','Edit an existing page',29);
INSERT INTO tiki_score VALUES ('wiki_attach_file',3,0,'Wiki','Attach file',30);
#
# Community tables end
......
# $Header: /cvsroot/tikiwiki/tiki/db/tiki_1.8to1.9.sql,v 1.80 2004-06-27 03:05:48 mose Exp $
# $Header: /cvsroot/tikiwiki/tiki/db/tiki_1.8to1.9.sql,v 1.81 2004-06-28 16:16:25 mose Exp $
# The following script will update a tiki database from verion 1.8 to 1.9
#
......@@ -593,3 +593,31 @@ update `tiki_menu_options` set type='r' where `menuId`=42 and `name`='Admin (cli
#Added June 26th lfagundes aka batawata, making score db independent
alter table `tiki_users_score` modify `expire` int(14) not null;
#Added June 27th lfagundes, refactoring score to have static data in php instead of db
alter table `tiki_score` drop description;
alter table `tiki_score` drop category;
alter table `tiki_score` drop ord;
#Added June 27th lfagundes, removing uneeded
alter table `tiki_users_score` drop score;
#Added June 27th marclaporte, changing menu option to take into account new tiki_p_send_newsletters perm
# uncomment and use these if you didnt alter the default Application menu
#UPDATE tiki_menu_options SET perm = 'tiki_p_send_newsletters' WHERE position='905';
#UPDATE users_permissions SET level = 'admin' WHERE permName='tiki_p_admin_newsletters';
#UPDATE users_permissions SET level = 'editors' WHERE permName='tiki_p_send_newsletters';
CREATE TABLE tiki_searchsyllable(
syllable varchar(80) NOT NULL default '',
lastUsed int(11) NOT NULL default '0',
lastUpdated int(11) NOT NULL default '0',
PRIMARY KEY (syllable),
KEY lastUsed (lastUsed)
) TYPE=MyISAM;
CREATE TABLE tiki_searchwords(
syllable varchar(80) NOT NULL default '',
searchword varchar(80) NOT NULL default '',
PRIMARY KEY (syllable,searchword)
) TYPE=MyISAM;
#!/usr/bin/perl
# A problem with having to maintain translations of several versions of tiki is that the same strings
# have the same translation, but is not desirable to change twice the same strings
# This utility takes the translations for the old version, and if the string is in the new translation file
# it puts the old translation there.
if ($#ARGV==1) {
$fileold=$ARGV[0];
$filenew=$ARGV[1];
open OLD, "<$fileold";
while ($line=<OLD>) {
if ($line=~/^\s*\"(.*)\"\s*\=\>\s*\"(.*)\"\s*\,\s*$/) {
$orig=$1;
$trad=$2;
if ($orig ne $trad) {
$trads{$orig}=$trad;
}
}
}
close OLD;
open CURRENT,"<$filenew";
open NEW,">$filenew.new";
while ($line=<CURRENT>) {
if ($line=~/^\s*\"(.*)\"\s*\=\>\s*\"(.*)\"\s*\,\s*$/) {
$orig=$1;
$trad=$2;
if ($trads{$orig}) {
print NEW "\"$orig\" => \"" . $trads{$orig} . "\",\n";
} else {
print NEW "\"$orig\" => \"$trad\",\n";
}
} else {
print NEW $line;
}
}
close CURRENT;
close NEW;
} else {
print $#ARGV . "\n";
print "Usage: mergelang.pl oldlang.php currentlang.php\n";
print "This will generate a currentlang.php.new file with the content of the currentlang.php file but with the old translations for the matching strings from oldlang.php\n";
}
......@@ -1031,7 +1031,7 @@ $lang=Array(
"Rating" => "Wertung",
"Comment" => "Kommentar",
"Posting comments" => "Posting-Kommentare",
"Use" => "Nutzen",
"Use" => "Benutze",
"for links" => "f&uuml;r Links",
"HTML tags are not allowed inside comments" => "HTML-Tags innerhalb von Kommentaren nicht erlaubt",
"Year" => "Jahr",
......@@ -1642,6 +1642,7 @@ $lang=Array(
"left modules" => "Module links",
"right modules" => "Module rechts",
"edit/create" => "hinzuf&uuml;gen/bearbeiten",
"Edit/Create" => "hinzuf&uuml;gen/bearbeiten",
"clear cache" => "Cache leeren",
"\r\n<b>Note 1</b>: if you allow your users to configure modules then assigned\r\nmodules won't be reflected in the screen until you configure them\r\nfrom MyTiki->modules.<br />\r\n<b>Note 2</b>: If you assign modules to groups make sure that you\r\nhave turned off the option 'display modules to all groups always'\r\nfrom Admin->General\r\n" => "\r\n\n<b>Bemerkung 1</b>: Wenn sie den Benutzern erlauben, Module zu konfigurieren, \r\n\ndann werden die hier zugewiesenen Module f&uuml;r die Benuzer erst sichtbar,\r\n\nwenn sie sie in MeinTiki->Module konfigurieren.<br />\r\n\n<b>Bemerkung 2</b>: Wenn sie den Modulen Gruppen zuweisen, dann gehen sie\r\n\nsicher, da&szlig; sie die Option 'Module immer in allen Gruppen anzeigen'\r\n\nin Verwaltung->Allgemein abgestellt haben.\r\n\n",
"User Modules" => "Benutzer-Module",
......@@ -2863,7 +2864,7 @@ $lang=Array(
"Assign themes to sections" => "Bereichen Themen zuweisen",
"Assigned sections" => "Zugeordnete Bereiche",
"This is" => "Dies ist",
"by the" => "bei",
"by the" => "von der",
"Tiki community" => "Tiki Community",
"debug" => "Debug",
"Upload File" => "Datei hochladen",
......@@ -3842,8 +3843,16 @@ $lang=Array(
"assign perms to this group" => "dieser Gruppe Rechte zuweisen",
"Available groups" => "Verf&uuml;gbare Gruppen",
"click here to confirm your action" => "Zur Best&auml;tigung hier klicken",
"click to navigate" => "zum Navigieren anklicken",
"ShowUrls" => "URLs anzeigen",
"click here to send us an email" => "Hier klicken um uns eine EMail zu schicken",
"Post new reply" => "Neue Anwort schreiben",
"Posted replies" => "bisherige Anworten",
"Reply" => "Antwort",
"Replies below your current threshold" => "Antworten unter dem eingestellten Schwellenwert",
"Posting replies" => "Post-Antworten",
"HTML tags are not allowed inside posts" => "HTML-Tags sind in Posts nicht erlaubt",
/*
"ShowUrls" => "",
"assign xxxxx to groups" => "",
"Authoritative status for modified items" => "Authoritative status for modified items",
"Forward messages to this forum to this e-mail address, in a format that can be used for sending back to the inbound forum e-mail address" => "Forward messages to this forum to this e-mail address, in a format that can be used for sending back to the inbound forum e-mail address",
......
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -1011,7 +1011,7 @@ class Comments extends TikiLib {
$now = date("U");
$oldage = $now - $age;
$query = "select `threadId` from `tiki_comments` where
`parentId`=0 and commentDate<?";
`parentId`=0 and `commentDate`<?";
$result = $this->query($query, array( (int) $oldage ));
while ($res = $result->fetchRow()) {
......
<?
// Each element of $events is an array with (dependent features, category, event name, translated description, default score, default expiration)
$events = array(
//array("","General","login",tra("Login"),1,0),
//array("","General","login_remain",tra("Stay logged"),2,60),
//array("","General","profile_fill",tra("Fill each profile field"),10,0),
//array("","General","profile_see",tra("See other user's profile"),2,0),
//array("","General","profile_is_seen",tra("Have your profile seen"),1,0),
array("feature_friends","General","friend_new",tra("Make friends"),10,0),
//array("","General","message_receive",tra("Receive message"),1,0),
//array("","General","message_send",tra("Send message"),2,0),
//array("feature_articles","Articles","article_read",tra("Read an article"),2,0),
//array("feature_articles","Articles","article_comment",tra("Comment an article"),5,0),
//array("feature_articles","Articles","article_new",tra("Publish an article"),20,0),
//array("feature_articles","Articles","article_is_read",tra("Have your article read"),1,0),
//array("feature_articles","Articles","article_is_commented",tra("Have your article commented"),2,0),
array("feature_file_galleries","File galleries","fgallery_new",tra("Create new file gallery"),10,0),
array("feature_file_galleries","File galleries","fgallery_new_file",tra("Upload new file to gallery"),10,0),
array("feature_file_galleries","File galleries","fgallery_download",tra("Download other user's file"),5,0),
array("feature_file_galleries","File galleries","fgallery_is_downloaded",tra("Have your file downloaded"),5,0),
array("feature_galleries","Image galleries","igallery_new",tra("Create a new image gallery"),10,0),
array("feature_galleries","Image galleries","igallery_new_img",tra("Upload new image to gallery"),6,0),
array("feature_galleries","Image galleries","igallery_see",tra("See other user's gallery"),4,0),
array("feature_galleries","Image galleries","igallery_see_img",tra("See other user's image"),3,0),
array("feature_galleries","Image galleries","igallery_seen",tra("Have your gallery seen by other user"),2,0),
array("feature_galleries","Image galleries","igallery_img_seen",tra("Have your image seen"),1,0),
array("feature_blogs","Blogs","blog_new",tra("Create new blog"),20,0),
array("feature_blogs","Blogs","blog_post",tra("Post in a blog"),5,0),
array("feature_blogs","Blogs","blog_read",tra("Read other user's blog"),2,0),
//array("feature_blogs","Blogs","blog_comment",tra("Comment other user's blog"),2,0),
array("feature_blogs","Blogs","blog_is_read",tra("Have your blog read"),3,0),
//array("feature_blogs","Blogs","blog_is_commented",tra("Have your blog commented"),3,0),
array("feature_wiki","Wiki","wiki_new",tra("Create a new wiki page"),10,0),
array("feature_wiki","Wiki","wiki_edit",tra("Edit an existing page"),5,0),
array("feature_wiki","Wiki","wiki_attach_file",tra("Attach file"),3,0)
);
......@@ -28,21 +28,58 @@ class ScoreLib extends TikiLib {
// All event types, for administration
function get_all_events() {
$query = "select * from `tiki_score` order by `category`, `ord`";
$query = "select * from `tiki_score`";
$result = $this->query($query,array());
$ranking = array();
$index = array();
while ($res = $result->fetchRow()) {
$ranking[] = $res;
$index[$res['event']] = $res;
}
return $ranking;
// load $events
require('lib/score/events.php');
$event_list = array();
foreach ($events as $event_data) {
$features = preg_split('/(\s|,)+/',$event_data[0]);
$show = true;
foreach ($features as $feature) {
if (!empty($feature)) {
global $$feature;
if ($$feature != 'y') {
$show = false;
}
}
}
if ($show) {
$event = array('category' => $event_data[1],
'event' => $event_data[2],
'description' => $event_data[3],
'score' => $event_data[4],
'expiration' => $event_data[5]);
$event_name = $event_data[2];
if (isset($index[$event_name])) {
$event['score'] = $index[$event_name]['score'];
$event['expiration'] = $index[$event_name]['expiration'];
}
$event_list[] = $event;
}
}
return $event_list;
}
// Read information from admin and updates event's punctuation
function update_events($events) {
foreach ($events as $event_name => $event) {
$query = "update `tiki_score` set `score`=?, `expiration`=? where `event`=?";
$this->query($query,array((int) $event['score'], $event['expiration'], $event_name));
}
foreach ($events as $event_name => $event) {
$query = "delete from `tiki_score` where `event`=?";
$this->query($query, array($event_name));
$query = "insert into `tiki_score` (`event`,`score`,`expiration`) values (?,?,?)";
$this->query($query,array($event_name, (int) $event['score'], $event['expiration']));
}
}
}
......
......@@ -1813,8 +1813,6 @@ function get_included_groups($group) {
// TODO: if there's already a friendship request from friend to user, accept it
function request_friendship($user, $friend)
{
global $messulib;
if (empty($user) || empty($friend) || $user == $friend) {
return false;
}
......@@ -1833,8 +1831,6 @@ function get_included_groups($group) {
function accept_friendship($user, $friend)
{
global $messulib;
$exists = $this->getOne("select count(*) from `tiki_friendship_requests` where `userTo`=? and `userFrom`=?",
array($user, $friend));
......@@ -1860,21 +1856,11 @@ function get_included_groups($group) {
$this->score_event($user,'friend_new',$friend);
$this->score_event($friend,'friend_new',$user);
$messulib->post_message($friend,
$user,
$friend,
'',
tra('AcceptFriendshipSubject'),
tra('AcceptFriendshipMessage'),
3);
return true;
}
function refuse_friendship($user, $friend)
{
global $messulib;
$exists = $this->getOne("select count(*) from `tiki_friendship_requests` where `userTo`=? and `userFrom`=?",
array($user, $friend));
......@@ -1885,15 +1871,6 @@ function get_included_groups($group) {
$this->query($query, array($user, $friend));
$this->query($query, array($friend, $user));
$messulib->post_message($friend,
$user,
$friend,
'',
tra('RefuseFriendshipSubject'),
tra('RefuseFriendshipMessage'),
3);
return true;
}
......@@ -1928,19 +1905,11 @@ function get_included_groups($group) {
function break_friendship($user, $friend)
{
global $messulib;
$query = "delete from `tiki_friends` where `user`=? and `friend`=?";
$this->query($query, array($user, $friend));
$this->query($query, array($friend, $user));
$messulib->post_message($friend,
$user,
$friend,
'',
tra('BreakFriendshipSubject'),
tra('BreakFriendshipMessage'),
3);
}
......
<?php
// Includes a wiki page in another
// Includes articles listing in a wiki page
// Usage:
// {ARTICLES(max=>3,topic=>topicId)}{ARTICLES}
//
......@@ -31,10 +31,18 @@ function wikiplugin_articles($data,$params) {
}
$now = date("U");
include_once("lib/commentslib.php");
$commentslib = new Comments($dbTiki);
$listpages = $tikilib->list_articles(0, $max, 'publishDate_desc', '', $now, 'admin', '', $topic);
for ($i = 0; $i < count($listpages["data"]); $i++) {
$listpages["data"][$i]["parsed_heading"] = $tikilib->parse_data($listpages["data"][$i]["heading"]);
$comments_prefix_var='article:';
$comments_object_var=$listpages["data"][$i]["articleId"];
$comments_objectId = $comments_prefix_var.$comments_object_var;
$listpages["data"][$i]["comments_cant"] = $commentslib->count_comments($comments_objectId);
//print_r($listpages["data"][$i]['title']);
}
require_once ('lib/articles/artlib.php');
......
/*
$Header: /cvsroot/tikiwiki/tiki/styles/moreneat.css,v 1.55 2004-06-27 03:05:53 mose Exp $
$Header: /cvsroot/tikiwiki/tiki/styles/moreneat.css,v 1.56 2004-06-28 16:16:28 mose Exp $
MoreNeat theme
*/
......@@ -288,7 +288,7 @@ div.cbox-data {
background: white;
padding-left: 5px; padding-right: 5px;
font-size: 10px; color: black;
width: 100%; /*xenfasa added to fix IE formating*/
/* width: 100%; /*xenfasa added to fix IE formating*/
}
/* Some boxes are identified by an ID, for example the boxes in the main application menu, we set display to
......
......@@ -11,7 +11,7 @@
</div>
{/if}
<div id="tiki-mid">
<table border="0" cellpadding="0" cellspacing="0" >
<table border="0" cellpadding="0" cellspacing="0" id="tikimidtbl">
<tr>
{if $feature_left_column eq 'y'}
<td id="leftcolumn">
......
{* $Header: /cvsroot/tikiwiki/tiki/templates/modules/mod-who_is_there.tpl,v 1.8 2004-06-23 22:34:29 mose Exp $ *}
{* $Header: /cvsroot/tikiwiki/tiki/templates/modules/mod-who_is_there.tpl,v 1.9 2004-06-28 16:16:30 mose Exp $ *}
{tikimodule title="{tr}Online users{/tr}" name="who_is_there"}
<div>
......@@ -15,9 +15,9 @@
{/if}
{if $online_users[ix].user_information eq 'public'}
{math equation="x - y" x=$smarty.now y=$online_users[ix].timestamp assign=idle}
<a class="linkmodule" href="tiki-user_information.php?view_user={$online_users[ix].user}" title="{tr}More info about{/tr} {$online_users[ix].user} ({tr}idle{/tr} {$idle} {tr}seconds{/tr})">{$online_users[ix].user}</a><br />
<a class="linkmodule" href="tiki-user_information.php?view_user={$online_users[ix].user}" title="{tr}More info about{/tr} {$online_users[ix].user} ({tr}idle{/tr} {$idle} {tr}seconds{/tr})">{$online_users[ix].user|userlink}</a><br />
{else}
{$online_users[ix].user}<br />
{$online_users[ix].user|userlink}<br />
{/if}
{/section}
{/tikimodule}
......
......@@ -12,7 +12,7 @@
{if $is_categorized eq 'y' and $feature_categories eq 'y' and $feature_categorypath eq 'y'}
<tr>
<td align="right" colspan="2">
<td align="right" colspan="{if $feature_multilingual eq "y"}3{else}2{/if}">
{$display_catpath}
</td>
</tr>
......@@ -28,6 +28,7 @@
</td>
{if $print_page ne 'y'}
{if $feature_multilingual == 'y'}{include file="translated-lang.tpl" td='y'}{/if}
<td style="text-align:right;">
{if !$lock and ($tiki_p_edit eq 'y' or $page eq 'SandBox') and $beingEdited ne 'y'}
......@@ -93,7 +94,6 @@
</form>
{/if}
</td>
{if $feature_multilingual == 'y'}{include file="translated-lang.tpl" td='y'}{/if}
</tr>
{/if}
</table>
......
<div class="simplebox">{tr}Tip{/tr}: {tr}to add/remove blogs, go to "Create/Edit blog" under "Blogs" on the left menu, or{/tr} <a class="link" href="tiki-edit_blog.php">{tr}click here{/tr}</a>.</div><br />
{if $feature_help eq "y"}
<div class="simplebox">{tr}Tip{/tr}: {tr}to add/remove blogs, go to "Create/Edit blog" under "Blogs" on the application menu, or{/tr} <a class="link" href="tiki-edit_blog.php">{tr}click here{/tr}</a>.</div><br />
{/if}
<div class="cbox">
<div class="cbox-title">{tr}Blog settings{/tr}</div>
<div class="cbox-data">
......
<div class="simplebox">{tr}Tip{/tr}: {tr}look under "Articles" on the left menu for links to{/tr} "<a class="link" href="tiki-admin_topics.php">{tr}Admin topics{/tr}</a>" {tr}and{/tr} "<a class="link" href="tiki-article_types.php">{tr}Admin types{/tr}</a>".</div><br />
{if $feature_help eq "y"}
<div class="simplebox">{tr}Tip{/tr}: {tr}look under "Articles" on the application menu for links to{/tr} "<a class="link" href="tiki-admin_topics.php">{tr}Admin topics{/tr}</a>" {tr}and{/tr} "<a class="link" href="tiki-article_types.php">{tr}Admin types{/tr}</a>".</div><br />
{/if}
<div class="cbox">
<div class="cbox-title">{tr}Article/CMS settings{/tr}</div>
<div class="cbox-data">
......
<div class="simplebox">{tr}Tip{/tr}: {tr}to configure your directory, find "Admin directory" under "Directory" on the left menu, or{/tr} <a class="link" href="tiki-directory_admin.php">{tr}click here{/tr}</a>.</div><br />
{if $feature_help eq "y"}
<div class="simplebox">{tr}Tip{/tr}: {tr}to configure your directory, find "Admin directory" under "Directory" on the application menu, or{/tr} <a class="link" href="tiki-directory_admin.php">{tr}click here{/tr}</a>.</div><br />
{/if}
<div class="cbox">
<div class="cbox-title">{tr}Directory{/tr}</div>
<div class="cbox-data">
......@@ -36,4 +38,4 @@
</form>
</div>
</div>
</div>
\ No newline at end of file
</div>
<div class="simplebox">{tr}Tip{/tr}: {tr}to add/remove FAQs, look for "Admin FAQs" under "FAQs" on the left menu, or{/tr} <a class="link" href="tiki-list_faqs.php">{tr}click here{/tr}</a>.</div><br />
{if $feature_help eq "y"}
<div class="simplebox">{tr}Tip{/tr}: {tr}to add/remove FAQs, look for "Admin FAQs" under "FAQs" on the application menu, or{/tr} <a class="link" href="tiki-list_faqs.php">{tr}click here{/tr}</a>.</div><br />
{/if}
<div class="cbox">
<div class="cbox-title">{tr}FAQs settings{/tr}</div>
<div class"cbox-data">
......
{* $Header: /cvsroot/tikiwiki/tiki/templates/tiki-admin-include-features.tpl,v 1.55 2004-06-23 22:34:28 mose Exp $ *}
{* $Header: /cvsroot/tikiwiki/tiki/templates/tiki-admin-include-features.tpl,v 1.56 2004-06-28 16:16:30 mose Exp $ *}
{* this is the very top most box of the feature section in tiki-admin.php?page=features,
* each td is a cell,each tr is a row, not to be confused with tr-smarty-tag which means translate...
......@@ -656,13 +656,9 @@
<td><input type="checkbox" name="contact_anon"
{if $contact_anon eq 'y'}checked="checked"{/if}/></td>
<td>&nbsp;</td>
<td class="form">
{if $feature_help eq 'y'}<a href="{$helpurl}SearchStats" target="tikihelp" class="tikihelp" title="{tr}SearchStats{/tr}">{/if}
{tr}Search stats{/tr}
{if $feature_help eq 'y'}</a>{/if}
:</td>
<td><input type="checkbox" name="feature_search_stats"
{if $feature_search_stats eq 'y'}checked="checked"{/if}/></td>
<td class="form">&nbsp;
</td>
<td>&nbsp;</td>
</tr><tr>
......
<div class="simplebox">{tr}Tip{/tr}: {tr}to add/remove file galleries, go to "File Galleries" on the left menu, or{/tr} <a class="link" href="tiki-file_galleries.php">{tr}click here{/tr}</a>.</div><br />
{if $feature_help eq "y"}
<div class="simplebox">{tr}Tip{/tr}: {tr}to add/remove file galleries, go to "File Galleries" on the application menu, or{/tr} <a class="link" href="tiki-file_galleries.php">{tr}click here{/tr}</a>.</div><br />
{/if}
<div class="cbox">
<div class="cbox-title">{tr}File galleries{/tr}</div>
<div class="cbox-data">
......
{if $feature_help eq 'y'}
<div class="simplebox">{tr}Tip{/tr}: {tr}to add/remove forums, look for "Admin forums" under "Forums" on the left menu, or{/tr} <a class="link" href="tiki-admin_forums.php">{tr}click here{/tr}</a>.</div><br />
<div class="simplebox">{tr}Tip{/tr}: {tr}to add/remove forums, look for "Admin forums" under "Forums" on the application menu, or{/tr} <a class="link" href="tiki-admin_forums.php">{tr}click here{/tr}</a>.</div><br />
{/if}
<div class="cbox">
<div class="cbox-title">{tr}Forums{/tr}</div>
......
<div class="simplebox">{tr}Tip{/tr}: {tr}to add/remove image galleries, go to "Image Galleries" on the left menu, or{/tr} <a class="link" href="tiki-galleries.php">{tr}click here{/tr}</a>.</div><br />