ACC SHELL

Path : /srv/www/vhosts/petrikov/admin/pages/user/
File Upload :
Current File : /srv/www/vhosts/petrikov/admin/pages/user/index.php

<?php
	$query = "SELECT `autorized` FROM `hotels` WHERE `ID_user` = '". $_SESSION[ "ID" ]. "'";
			 
	$result = mysql_query( $query, $dbc );
		
	if ( mysql_num_rows( $result ) > 0 )
	{
		$row = mysql_fetch_row( $result );
		if ( $row[ 0 ] == 0 ) {
			message( "Hotel ještě nebyl autorizován" );
		}
	} else {
		message( "Hotel ještě nebyl vytvořen..." );
	}

	$query = "SELECT * FROM `users` WHERE `ID` = '". $_SESSION[ "ID" ]. "'";
			 
	$result = mysql_query( $query, $dbc );
		
	if ( mysql_num_rows( $result ) > 0 )
	{
		$row = mysql_fetch_row( $result );
		if ( $row[ 4 ] == '' && $row[ 5 ] == '' && $row[ 6 ] == '' && $row[ 7 ] == '' ) {
			message( 'Váš profil je prázdný.<br />'
				.'<a href="?action=user&make=edit" title="Upravit profil">Upravit profil</a>' );
		}
	} else {
		message( "Váš profil nebyl nalezen.<br />Informujte o tom prosím systémového administrátora." );
	}

	$query = "SELECT COUNT(*) FROM photos WHERE ID_user = ". $_SESSION[ 'ID' ];

	$result = mysql_query( $query, $dbc );
		
	$row = mysql_fetch_row( $result );

	message( "Počet uložených fotografií: <strong>". $row[ 0 ]. "</strong><br />"
		.'<a href="?action=photos&make=add" title="Vložit fotografii">Vložit fotografii</a>' );	
?>

ACC SHELL 2018