infrastructure for future stuff

This commit is contained in:
friendica 2013-06-19 18:06:14 -07:00
parent 9d03da1348
commit 4f06905a18
5 changed files with 33 additions and 18 deletions

View file

@ -41,7 +41,7 @@ require_once('include/features.php');
define ( 'RED_PLATFORM', 'Red Matrix' );
define ( 'RED_VERSION', trim(file_get_contents('version.inc')) . 'R');
define ( 'ZOT_REVISION', 1 );
define ( 'DB_UPDATE_VERSION', 1044 );
define ( 'DB_UPDATE_VERSION', 1045 );
define ( 'EOL', '<br />' . "\r\n" );
define ( 'ATOM_TIME', 'Y-m-d\TH:i:s\Z' );
@ -117,7 +117,7 @@ define ( 'DEFAULT_DB_ENGINE', 'MyISAM' );
define ( 'SSL_POLICY_NONE', 0 );
define ( 'SSL_POLICY_FULL', 1 );
define ( 'SSL_POLICY_SELFSIGN', 2 );
define ( 'SSL_POLICY_SELFSIGN', 2 ); // NOT supported in Red
/**
@ -313,18 +313,24 @@ define ( 'XCHAN_FLAGS_HIDDEN', 0x0001);
* Tag/term types
*/
define ( 'TERM_UNKNOWN', 0 );
define ( 'TERM_HASHTAG', 1 );
define ( 'TERM_MENTION', 2 );
define ( 'TERM_CATEGORY', 3 );
define ( 'TERM_PCATEGORY', 4 );
define ( 'TERM_FILE', 5 );
define ( 'TERM_SAVEDSEARCH', 6 );
define ( 'TERM_OBJ_POST', 1 );
define ( 'TERM_OBJ_PHOTO', 2 );
define ( 'TERM_UNKNOWN', 0 );
define ( 'TERM_HASHTAG', 1 );
define ( 'TERM_MENTION', 2 );
define ( 'TERM_CATEGORY', 3 );
define ( 'TERM_PCATEGORY', 4 );
define ( 'TERM_FILE', 5 );
define ( 'TERM_SAVEDSEARCH', 6 );
define ( 'TERM_HAVETHING', 7 );
define ( 'TERM_WANTTHING', 8 );
define ( 'TERM_LIKETHING', 9 );
define ( 'TERM_NOLIKETHING', 10 );
define ( 'TERM_OBJ_POST', 1 );
define ( 'TERM_OBJ_PHOTO', 2 );
define ( 'TERM_OBJ_PROFILE', 3 );
define ( 'TERM_OBJ_CHANNEL', 4 );
define ( 'TERM_OBJ_OBJECT', 5 );
define ( 'TERM_OBJ_THING', 6 );
/**

View file

@ -826,13 +826,15 @@ CREATE TABLE IF NOT EXISTS `term` (
`type` tinyint(3) unsigned NOT NULL,
`term` char(255) NOT NULL,
`url` char(255) NOT NULL,
`imgurl` char(255) NOT NULL,
PRIMARY KEY (`tid`),
KEY `oid` (`oid`),
KEY `otype` (`otype`),
KEY `type` (`type`),
KEY `term` (`term`),
KEY `uid` (`uid`),
KEY `aid` (`aid`)
KEY `aid` (`aid`),
KEY `imgurl` (`imgurl`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
CREATE TABLE IF NOT EXISTS `tokens` (

View file

@ -1,6 +1,6 @@
<?php
define( 'UPDATE_VERSION' , 1044 );
define( 'UPDATE_VERSION' , 1045 );
/**
*
@ -548,3 +548,11 @@ ADD INDEX ( `comment_policy` ) ");
return UPDATE_SUCCESS;
return UPDATE_FAILED;
}
function update_r1044() {
$r = q("ALTER TABLE `term` ADD `imgurl` CHAR( 255 ) NOT NULL ,
ADD INDEX ( `imgurl` ) ");
if($r)
return UPDATE_SUCCESS;
return UPDATE_FAILED;
}

View file

@ -102,8 +102,7 @@ function like_content(&$a) {
$post_type = (($item['resource_type'] === 'photo') ? $t('photo') : t('status'));
$links = array(array('rel' => 'alternate','type' => 'text/html',
'href' => z_root() . '/display/' . $item['mid']));
$links = array(array('rel' => 'alternate','type' => 'text/html', 'href' => $item['plink']));
$objtype = (($item['resource_type'] === 'photo') ? ACTIVITY_OBJ_PHOTO : ACTIVITY_OBJ_NOTE );
$body = $item['body'];

View file

@ -1 +1 @@
2013-06-18.348
2013-06-19.349