Example #1
0
<style>
	video {
		border:none;
		border-radius: 2px;
		cursor: pointer;
		box-shadow: 5px 5px 20px #101010;
	}
</style><?php 
include_once '/kunden/homepages/0/d643120834/htdocs/config/index.php';
$config = new Blog($_SERVER['HTTP_HOST']);
// add these stats in here somehwere in the layout
$stats = $config->getStatsByUser($site['user']['name']);
$current_page = '0';
$user = $config->getUserData($site['user']['name']);
$files = $config->getVideosByUser('admin', 1);
echo $config->display_feed($files, true, 0);
$files = $config->getVideosByUser('admin', 6);
echo $config->display_feed($files, false, 0);
// echo $files['posts'];
// var_dump($files);
?>
<script>
function playVideo(elem) {
	elem.get(0).play();
	elem.get(0).volume = 0.5;
}

$('video').bind('click',function(){
	// alert('now playing video');
	playVideo($(this));
	$('video').unbind('hover');
Example #2
0
$config = new Blog($_SERVER['HTTP_HOST']);
// get all users
// $users = $config->getUsers();
$users = $config->getFollowing(Session::get('user_name'));
?>
<style>
	.card-social {
		min-height:200px;
		padding:2em;
	}
</style>
<?php 
// var_dump($users);
$select_user = '******';
foreach ($users as $key => $user) {
    $userdata = $config->getUserData($user['following']);
    if ($userdata['photo'] == '') {
        $photo = 'https://myspace.com/common/images/user.png';
    } else {
        $photo = $userdata['photo'];
    }
    $select_user .= '<div value="' . $user['following'] . '" class="card card-inverse card-social text-center col-md-4">

			<a href="http://freelabel.net/u/' . $user['following'] . '" target="_blank">
				<img src="' . $photo . '" height="90" width="90" alt="Avatar" class="img-circle">
				<h4>' . $user['following'] . '</h4>
			</a>
			<button class="btn btn-danger-outline unfollow-trigger" data-user="******" data-username="******">Unfollow</button>
			<div class="card-block container">
		      <div class="row">
		        <div class="col-md-4 card-stat">
Example #3
0
$config = new Blog();
$s = $config->getStatsByUser($user_name);
$stats = $s['count'];
$tracks = $config->getPostsByUser(0, 300, $user_name);
$events = $config->getEventsByUser($user_name, 500);
$promos = $config->getPromosByUser(Session::get('user_name'), 300);
$num_tracks = count($tracks);
$num_events = count($events);
$num_promos = count($promos);
if ($num_tracks == '300') {
    $num_tracks = $num_tracks . "+";
}
// earnings calculator
$score = 0.001 * $stats * 0.001 * $num_tracks;
$photo = $config->getProfilePhoto($user_name);
$user = $config->getUserData($user_name);
if (isset($tracks)) {
    foreach ($tracks as $key => $value) {
        $post_date = date('m-d', strtotime($value['submission_date']));
        $todays_date = date('m-d');
        $yesterdays_date = date('m-d', '-1 day');
        $two_days_ago = date('m-d', strtotime('-2 days', time()));
        $three_days_ago = date('m-d', strtotime('-3 days', time()));
        if ($post_date == $todays_date) {
            $today[] = $value['blogtitle'];
        } elseif ($post_date == $yesterdays_date) {
            $yesterday[] = $value['blogtitle'];
        } elseif ($post_date == $two_days_ago) {
            $two_days_ago_arr[] = $value['blogtitle'];
        } elseif ($post_date == $three_days_ago) {
            $three_days_ago_arr[] = $value['blogtitle'];
Example #4
0
if (isset($_POST['following'])) {
    if ($config->checkIfAlreadyFollowing($_POST['user_name'], $_POST['following']) == false) {
        echo $config->add_relationship($_POST);
    } else {
        echo 'ALREADY FOLLOWING THIS USER!';
    }
    // var_dump($_POST);
    // echo 'okay 2 bizznes';
    exit;
}
$users = $config->getUsers();
$user_name = Session::get('user_name');
// var_dump($users);
$select_user = '******';
foreach ($users as $key => $user) {
    $userdata = $config->getUserData($user['user_name']);
    if ($userdata['photo'] == '') {
        $photo = 'https://myspace.com/common/images/user.png';
    } else {
        $photo = $userdata['photo'];
    }
    $select_user .= '<div value="' . $user['following'] . '" class="card card-inverse card-social text-center col-md-4">

	<a href="http://freelabel.net/u/' . $user['following'] . '" target="_blank">
		<img src="' . $photo . '" height="90" width="90" alt="Avatar" class="img-circle">
		<h4>' . $user['user_name'] . '</h4>
	</a>
	<button data-user="******" data-username="******" class="follow-trigger btn btn-sm btn-success-outline">Follow</button>
	<div class="card-block container">
      <div class="row">
        <div class="col-md-6 card-stat">
Example #5
0
$result = mysqli_query($con, "SELECT * \nFROM  `users` \nWHERE  `user_name` LIKE  '%" . $uid . "%'\nLIMIT 1");
while ($row = mysqli_fetch_assoc($result)) {
    $user['settings'] = $row;
    include_once ROOT . 'inc/connection.php';
    $result = mysqli_query($con, "SELECT * FROM  `user_profiles` WHERE  `id` =  '" . $uid . "' LIMIT 1");
    if ($row = mysqli_fetch_assoc($result)) {
        // echo 'found!';
        $user['profile'] = $row;
        $user['media']['feed'] = $config->getPostsByUser(0, 24, $_GET['uid']);
        //print_r($user);
    } else {
        echo 'Not Found';
    }
}
/* GET USER PROFILE DATA */
$user['profile'] = $config->getUserData($uid);
$meta_tag_photo = str_replace(' ', '%20', $row['image']);
include_once ROOT . 'inc/connection.php';
$result = mysqli_query($con, "SELECT * FROM  `images` WHERE  `user_name` = '" . $_GET['uid'] . "' AND `type` NOT LIKE '%private%' ORDER BY `id` DESC LIMIT 10");
$i = 0;
while ($row = mysqli_fetch_assoc($result)) {
    $todays_date = date('Ymd_H:i');
    $id = $row['id'];
    $title = $row['title'];
    $user_name = $row['user_name'];
    $desc = $row['desc'];
    $image = $row['image'];
    $twitpic = $row['twitpic'];
    $bae_description = $row['bae_description'];
    $date = $todays_date;
    if ($bae_description == false) {