Fixed : news feed in admin panel
Added : new video SEO URL option Added : custom video url option Added : direct view channel option
This commit is contained in:
parent
6d817d2d4a
commit
946f1f390f
9 changed files with 137 additions and 25 deletions
|
@ -41,6 +41,10 @@ RewriteRule ^videos/(.*)/(.*)/(.*)/(.*)/(.*) videos.php?cat=$1&sort=$3&time=$4&p
|
|||
RewriteRule ^videos/([0-9]+) videos.php?page=$1 [L]
|
||||
RewriteRule ^videos videos.php?%{QUERY_STRING} [L]
|
||||
RewriteRule ^video/(.*)/(.*) watch_video.php?v=$1&%{QUERY_STRING} [L]
|
||||
#Alternate watch video links
|
||||
RewriteRule ^(.*)\_v([0-9]+) watch_video.php?v=$2&%{QUERY_STRING} [L]
|
||||
RewriteRule ^video/([0-9]+)_(.*) watch_video.php?v=$1&%{QUERY_STRING} [L]
|
||||
|
||||
|
||||
#
|
||||
#Users, Channel & Management
|
||||
|
@ -88,9 +92,9 @@ RewriteRule ^photos photos.php [L]
|
|||
RewriteRule ^collection/(.*)/(.*)/(.*) view_collection.php?cid=$1&type=$2&%{QUERY_STRING} [L]
|
||||
|
||||
#Photo Section
|
||||
RewriteRule ^item/(.*)/(.*)/(.*)/(.*) view_item.php?item=$3&type=$1&collection=$2 [L]
|
||||
RewriteRule ^photo_upload/(.*) photo_upload.php?collection=$1 [L]
|
||||
RewriteRule ^photo_upload photo_upload.php [L]
|
||||
RewriteRule ^item/(.*)/(.*)/(.*)/(.*) view_item.php?item=$3&type=$1&collection=$2 [L]
|
||||
RewriteRule ^photo_upload/(.*) photo_upload.php?collection=$1 [L]
|
||||
RewriteRule ^photo_upload photo_upload.php [L]
|
||||
#
|
||||
RewriteRule ^sitemap.xml$ sitemap.php
|
||||
RewriteRule ^signup signup.php
|
||||
|
@ -101,6 +105,8 @@ ErrorDocument 403 /403.php
|
|||
|
||||
########## End - Rewrite rules For SEO urls ######################
|
||||
RewriteRule ^rss$ rss.php [nc]
|
||||
RewriteRule ^rss/([a-zA-Z0-9].+)$ rss.php?mode=$1&%{QUERY_STRING} [nc]
|
||||
RewriteRule ^rss/([a-zA-Z0-9].+)$ rss.php?mode=$1&%{QUERY_STRING} [nc]
|
||||
|
||||
########## End - Rewrite rules For SEO urls ######################
|
||||
########## End - Rewrite rules For SEO urls ######################
|
||||
|
||||
RewriteRule ^([a-zA-Z0-9-]+)/?$ view_channel.php?uid=$1&seo_diret=yes [NS]
|
|
@ -167,6 +167,7 @@ if(isset($_POST['update'])){
|
|||
'srate',
|
||||
'site_slogan',
|
||||
'seo',
|
||||
'seo_vido_url',
|
||||
'search_list_per_page',
|
||||
'server_friendly_conversion',
|
||||
'support_email',
|
||||
|
|
|
@ -378,6 +378,30 @@ $(document).ready(function(){
|
|||
<option value="embed_object" {if $row.embed_type=='embed_object'} selected="selected"{/if}>Embed object</option>
|
||||
</select></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Seo video url pattern</td>
|
||||
<td>
|
||||
<label>
|
||||
<input type="radio" name="seo_vido_url" value="0" id="seo_vido_url_0"
|
||||
{if !$row.seo_vido_url || $row.seo_vido_url==0} checked="checked"{/if} />
|
||||
{$baseurl}/video/ABCDXYZ/video-title</label>
|
||||
<br />
|
||||
<label>
|
||||
<input type="radio" name="seo_vido_url" value="1" id="seo_vido_url_1"
|
||||
{if $row.seo_vido_url==1} checked="checked"{/if}/>
|
||||
{$baseurl}/video-title-v123</label>
|
||||
<br />
|
||||
<label>
|
||||
<input type="radio" name="seo_vido_url" value="2" id="seo_vido_url_2"
|
||||
{if $row.seo_vido_url==2} checked="checked"{/if}/>
|
||||
{$baseurl}/video/123/video-title</label>
|
||||
<br />
|
||||
<label>
|
||||
<input type="radio" name="seo_vido_url" value="3" id="seo_vido_url_3"
|
||||
{if $row.seo_vido_url==3} checked="checked"{/if}/>
|
||||
{$baseurl}/video/123_video-title</label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> </td>
|
||||
<td> </td>
|
||||
|
@ -467,22 +491,28 @@ $(document).ready(function(){
|
|||
</select></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Allow videos ratings</td>
|
||||
<td><input name="video_rating" type="checkbox" id="video_rating" value="1" {if $row.video_rating=='1'}checked="checked"{/if} />
|
||||
- Allow user to rate own videos
|
||||
<input name="own_video_rating" type="checkbox" id="own_video_rating" value="1" {if $row.own_video_rating=='1'}checked="checked"{/if} /></td>
|
||||
<td colspan="2"><input name="video_rating" type="checkbox" id="video_rating" value="1" {if $row.video_rating=='1'}checked="checked"{/if} />
|
||||
Allow videos ratings
|
||||
|
||||
-
|
||||
<input name="own_video_rating" type="checkbox" id="own_video_rating" value="1" {if $row.own_video_rating=='1'}checked="checked"{/if} />
|
||||
Allow user to rate own videos </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Allow collection ratings</td>
|
||||
<td><input name="collection_rating" type="checkbox" id="collection_rating" value="1" {if $row.collection_rating=='1'}checked="checked"{/if} />
|
||||
- Allow user to rate own collections
|
||||
<input name="own_collection_rating" type="checkbox" id="own_collection_rating" value="1" {if $row.own_collection_rating=='1'}checked="checked"{/if} /></td>
|
||||
<td colspan="2"><input name="collection_rating" type="checkbox" id="collection_rating" value="1" {if $row.collection_rating=='1'}checked="checked"{/if} />
|
||||
Allow collection ratings
|
||||
|
||||
-
|
||||
<input name="own_collection_rating" type="checkbox" id="own_collection_rating" value="1" {if $row.own_collection_rating=='1'}checked="checked"{/if} />
|
||||
Allow user to rate own collections </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Allow channel ratings</td>
|
||||
<td><input name="channel_rating" type="checkbox" id="channel_rating" value="1" {if $row.channel_rating=='1'}checked="checked"{/if} />
|
||||
- Allow users to rate own channels
|
||||
<input name="own_channel_rating" type="checkbox" id="own_channel_rating" value="1" {if $row.own_channel_rating=='1'}checked="checked"{/if} /></td>
|
||||
<td colspan="2"><input name="channel_rating" type="checkbox" id="channel_rating" value="1" {if $row.channel_rating=='1'}checked="checked"{/if} />
|
||||
Allow channel ratings
|
||||
|
||||
-
|
||||
<input name="own_channel_rating" type="checkbox" id="own_channel_rating" value="1" {if $row.own_channel_rating=='1'}checked="checked"{/if} />
|
||||
Allow users to rate own channels </td>
|
||||
</tr>
|
||||
</table>
|
||||
</fieldset>
|
||||
|
|
|
@ -1429,8 +1429,8 @@ if(!empty($mode))
|
|||
{
|
||||
echo '<div class="item news">';
|
||||
echo '<div class="news_title">
|
||||
<span class="title"><a href="{$news.link}">'.$n['title'].'</a></span>
|
||||
<span class="date">'.date("m-d-Y",time($n['pubDate'])).'</span></div>
|
||||
<span class="title"><a href="'.$n['link'].'">'.$n['title'].'</a></span>
|
||||
<span class="date">'.date("m-d-Y",strtotime($n['pubDate'])).'</span></div>
|
||||
<span class="clearfix"></span>';
|
||||
echo '<div>';
|
||||
echo $n['description'];
|
||||
|
|
|
@ -226,6 +226,7 @@ INSERT INTO `{tbl_prefix}config` (`configid`, `name`, `value`) VALUES
|
|||
(NULL,'max_topic_title','300');
|
||||
|
||||
|
||||
|
||||
INSERT INTO `{tbl_prefix}languages` (`language_id`, `language_code`, `language_name`, `language_regex`, `language_active`, `language_default`) VALUES
|
||||
(5, 'en', 'English', '/^en/i', 'yes', 'yes');
|
||||
|
||||
|
@ -239,3 +240,8 @@ INSERT INTO `{tbl_prefix}validation_re` (`re_id`, `re_name`, `re_code`, `re_synt
|
|||
INSERT INTO `{tbl_prefix}config` (`configid` ,`name` ,`value`)VALUES
|
||||
(NULL , 'comments_per_page', '15'),
|
||||
(NULL, 'embed_type', 'iframe');
|
||||
|
||||
-- Addition for 2.6
|
||||
INSERT INTO `{tbl_prefix}config` (`configid`, `name`, `value`) VALUES (NULL, 'facebook_embed', 'yes');
|
||||
INSERT INTO `{tbl_prefix}config` (`configid`, `name`, `value`) VALUES (NULL, 'seo_vido_url', '1');
|
||||
|
||||
|
|
|
@ -1058,4 +1058,8 @@ ADD `display` ENUM( 'yes', 'no' ) NOT NULL DEFAULT 'yes' AFTER `page_order` ;
|
|||
ALTER TABLE `{tbl_prefix}users` ADD `voted` TEXT NOT NULL AFTER `last_commented`;
|
||||
|
||||
-- Alterations for 2.5.5
|
||||
ALTER TABLE `{tbl_prefix}groups` ADD `group_admins` TEXT NOT NULL AFTER `userid`;
|
||||
ALTER TABLE `{tbl_prefix}groups` ADD `group_admins` TEXT NOT NULL AFTER `userid`;
|
||||
|
||||
-- Alterations for 2.6
|
||||
ALTER TABLE `{tbl_prefix}video` CHANGE `category` `category` VARCHAR( 200 ) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT '0';
|
||||
ALTER TABLE `{tbl_prefix}collections` CHANGE `category` `category` VARCHAR( 200 ) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL ;
|
|
@ -1,3 +1,4 @@
|
|||
ALTER TABLE `{tbl_prefix}video` CHANGE `category` `category` VARCHAR( 200 ) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT '0';
|
||||
ALTER TABLE `{tbl_prefix}collections` CHANGE `category` `category` VARCHAR( 200 ) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL ;
|
||||
INSERT INTO `{tbl_prefix}config` (`configid`, `name`, `value`) VALUES (NULL, 'facebook_embed', 'yes');
|
||||
INSERT INTO `{tbl_prefix}config` (`configid`, `name`, `value`) VALUES (NULL, 'facebook_embed', 'yes');
|
||||
INSERT INTO `{tbl_prefix}config` (`configid`, `name`, `value`) VALUES (NULL, 'seo_vido_url', '0');
|
|
@ -108,7 +108,7 @@
|
|||
{
|
||||
$id = stripslashes($id);
|
||||
}
|
||||
$id = htmlspecialchars(mysql_real_escape_string($id), ENT_COMPAT, 'UTF-8');
|
||||
$id = htmlspecialchars(mysql_real_escape_string($id));
|
||||
if($replacer)
|
||||
$id = Replacer($id);
|
||||
return $id;
|
||||
|
@ -822,11 +822,58 @@
|
|||
if(!empty($vid))
|
||||
$vdetails = $myquery->get_video_details($vid);
|
||||
|
||||
//calling for custom video link functions
|
||||
$functions = cb_get_functions('video_link');
|
||||
if($functions)
|
||||
{
|
||||
foreach($functions as $func)
|
||||
{
|
||||
$array = array('vdetails'=>$vdetails,'type'=>$type);
|
||||
if(function_exists($func['func']))
|
||||
{
|
||||
$returned = $func['func']($array);
|
||||
if($returned)
|
||||
{
|
||||
$link = $returned;
|
||||
return $link;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$plist = "";
|
||||
if(SEO == 'yes'){
|
||||
|
||||
if($vdetails['playlist_id'])
|
||||
$plist = '?&play_list='.$vdetails['playlist_id'];
|
||||
$link = BASEURL.'/video/'.$vdetails['videokey'].'/'.SEO(clean(str_replace(' ','-',$vdetails['title']))).$plist;
|
||||
|
||||
switch(config('seo_vido_url'))
|
||||
{
|
||||
default:
|
||||
$link = BASEURL.'/video/'.$vdetails['videokey'].'/'.SEO(clean(str_replace(' ','-',$vdetails['title']))).$plist;
|
||||
break;
|
||||
|
||||
case 1:
|
||||
{
|
||||
$link = BASEURL.'/'.SEO(clean(str_replace(' ','-',$vdetails['title']))).'_v'.$vdetails['videoid'].$plist;
|
||||
}
|
||||
break;
|
||||
|
||||
case 2:
|
||||
{
|
||||
$link = BASEURL.'/video/'.$vdetails['videoid'].'/'.SEO(clean(str_replace(' ','-',$vdetails['title']))).$plist;
|
||||
}
|
||||
break;
|
||||
|
||||
case 3:
|
||||
{
|
||||
$link = BASEURL.'/video/'.$vdetails['videoid'].'_'.SEO(clean(str_replace(' ','-',$vdetails['title']))).$plist;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
}else{
|
||||
if($vdetails['playlist_id'])
|
||||
$plist = '&play_list='.$vdetails['playlist_id'];
|
||||
|
|
|
@ -86,8 +86,25 @@ if($udetails)
|
|||
|
||||
assign('profile_item',$profileItem);
|
||||
}else{
|
||||
e(lang("usr_exist_err"));
|
||||
$Cbucket->show_page = false;
|
||||
|
||||
if($_GET['seo_diret']!='yes')
|
||||
{
|
||||
e(lang("usr_exist_err"));
|
||||
$Cbucket->show_page = false;
|
||||
}else{
|
||||
header("HTTP/1.0 404 Not Found");
|
||||
if(file_exists(LAYOUT."/404.html")) {
|
||||
template_files('404.html');
|
||||
} else {
|
||||
$data = "404_error";
|
||||
if(has_access('admin_access'))
|
||||
e(sprintf(lang("err_warning"),"404","http://docs.clip-bucket.com/?p=154"),"w");
|
||||
e(lang($data));
|
||||
}
|
||||
|
||||
display_it();
|
||||
exit();
|
||||
}
|
||||
}
|
||||
add_js(array('jquery_plugs/compressed/jquery.jCarousel.js'=>'view_channel'));
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue