define ( 'FRIENDICA_PLATFORM', 'Friendica');
define ( 'FRIENDICA_VERSION', '3.0.1384' );
define ( 'DFRN_PROTOCOL_VERSION', '2.23' );
-define ( 'DB_UPDATE_VERSION', 1149 );
+define ( 'DB_UPDATE_VERSION', 1150 );
define ( 'EOL', "<br />\r\n" );
define ( 'ATOM_TIME', 'Y-m-d\TH:i:s\Z' );
`religion` char(255) NOT NULL,
`pub_keywords` text NOT NULL,
`prv_keywords` text NOT NULL,
+ `likes` text NOT NULL,
+ `dislikes` text NOT NULL,
`about` text NOT NULL,
`summary` char(255) NOT NULL,
`music` text NOT NULL,
if($txt = prepare_text($a->profile['interest'])) $profile['interest'] = array( t('Hobbies/Interests:'), $txt);
+ if($txt = prepare_text($a->profile['likes'])) $profile['likes'] = array( t('Likes:'), $txt);
+
+ if($txt = prepare_text($a->profile['dislikes'])) $profile['dislikes'] = array( t('Dislikes:'), $txt);
+
+
if($txt = prepare_text($a->profile['contact'])) $profile['contact'] = array( t('Contact information and Social Networks:'), $txt);
if($txt = prepare_text($a->profile['music'])) $profile['music'] = array( t('Musical interests:'), $txt);
$politic = notags(trim($_POST['politic']));
$religion = notags(trim($_POST['religion']));
+ $likes = fix_mce_lf(escape_tags(trim($_POST['likes'])));
+ $dislikes = fix_mce_lf(escape_tags(trim($_POST['dislikes'])));
+
$about = fix_mce_lf(escape_tags(trim($_POST['about'])));
$interest = fix_mce_lf(escape_tags(trim($_POST['interest'])));
$contact = fix_mce_lf(escape_tags(trim($_POST['contact'])));
if($withchanged) {
$changes[] = '[color=#ff0000]♥[/color] ' . t('Romantic Partner');
$value = strip_tags($with);
- }
+ }
+ if($likes != $orig[0]['likes']) {
+ $changes[] = t('Likes');
+ $value = $likes;
+ }
+ if($dislikes != $orig[0]['dislikes']) {
+ $changes[] = t('Dislikes');
+ $value = $dislikes;
+ }
if($work != $orig[0]['work']) {
$changes[] = t('Work/Employment');
}
`religion` = '%s',
`pub_keywords` = '%s',
`prv_keywords` = '%s',
+ `likes` = '%s',
+ `dislikes` = '%s',
`about` = '%s',
`interest` = '%s',
`contact` = '%s',
dbesc($religion),
dbesc($pub_keywords),
dbesc($prv_keywords),
+ dbesc($likes),
+ dbesc($dislikes),
dbesc($about),
dbesc($interest),
dbesc($contact),
'$lbl_religion' => t('Religious Views:'),
'$lbl_pubkey' => t('Public Keywords:'),
'$lbl_prvkey' => t('Private Keywords:'),
+ '$lbl_likes' => t('Likes:'),
+ '$lbl_dislikes' => t('Dislikes:'),
'$lbl_ex2' => t('Example: fishing photography software'),
'$lbl_pubdsc' => t("\x28Used for suggesting potential friends, can be seen by others\x29"),
'$lbl_prvdsc' => t("\x28Used for searching profiles, never shown to others\x29"),
'$religion' => $r[0]['religion'],
'$pub_keywords' => $r[0]['pub_keywords'],
'$prv_keywords' => $r[0]['prv_keywords'],
+ '$likes' => $r[0]['likes'],
+ '$dislikes' => $r[0]['dislikes'],
'$music' => $r[0]['music'],
'$book' => $r[0]['book'],
'$tv' => $r[0]['tv'],
<?php
-define( 'UPDATE_VERSION' , 1149 );
+define( 'UPDATE_VERSION' , 1150 );
/**
*
return UPDATE_FAILED;
return UPDATE_SUCCESS;
}
+
+
+function update_1149() {
+ $r1 = q("ALTER TABLE profile ADD likes text NOT NULL after prv_keywords");
+ $r2 = q("ALTER TABLE profile ADD dislikes text NOT NULL after likes");
+ if (! ($r1 && $r2))
+ return UPDATE_FAILED;
+ return UPDATE_SUCCESS;
+}
</dl>
{{ endif }}
+{{ if $profile.likes }}
+<dl id="aprofile-likes" class="aprofile">
+ <dt>$profile.likes.0</dt>
+ <dd>$profile.likes.1</dd>
+</dl>
+{{ endif }}
+
+{{ if $profile.dislikes }}
+<dl id="aprofile-dislikes" class="aprofile">
+ <dt>$profile.dislikes.0</dt>
+ <dd>$profile.dislikes.1</dd>
+</dl>
+{{ endif }}
{{ if $profile.contact }}
<dl id="aprofile-contact" class="aprofile">
</div>
+<div id="likes-jot-wrapper" >
+<p id="likes-jot-desc" >
+$lbl_likes
+</p>
+
+<textarea rows="10" cols="72" id="likes-jot-text" name="likes" >$likes</textarea>
+
+</div>
+<div id="likes-jot-end"></div>
+</div>
+
+
+<div id="dislikes-jot-wrapper" >
+<p id="dislikes-jot-desc" >
+$lbl_dislikes
+</p>
+
+<textarea rows="10" cols="72" id="dislikes-jot-text" name="dislikes" >$dislikes</textarea>
+
+</div>
+<div id="dislikes-jot-end"></div>
+</div>
+
+
<div id="contact-jot-wrapper" >
<p id="contact-jot-desc" >
$lbl_social