예제 #1
0
<?php

/**
 * Developed by Jay Gaha
 * http://jaygaha.com.np
 */
include 'includes/inc.php';
include "includes/classes/class.company.php";
$company = new Company();
$email = $_SESSION['email'];
$checkRow = $company->getCompanyByEmail($email);
if (!$checkRow) {
    header('HTTP/1.1 404 Not Found');
    exit('404, Invalid ID');
}
$data['formStatus'] = 'edit';
$data['row'] = $checkRow;
/*echo "<pre>";
	print_r($data['row']);*/
$data['id'] = $checkRow['id'];
$data['logo'] = checkImagexists('../../uploads/', 'companylogo_' . $checkRow['id']);
$data['pic'] = checkImagexists('../../uploads/', 'companypic_' . $checkRow['id']);
$data['pic1'] = checkImagexists('../../uploads/', 'companypic1_' . $checkRow['id']);
$data['pic2'] = checkImagexists('../../uploads/', 'companypic2_' . $checkRow['id']);
layout('form_company', $data);
예제 #2
0
				      <p><?php 
        echo substr(stripcslashes($value['details']), 0, 130) . '...';
        ?>
</p>
				    </li>
				<?php 
    }
}
?>
				</ul>
				<ul id="video" class="tabwml-content">
				<?php 
if ($data['wmlWMLVideo']) {
    foreach ($data['wmlWMLVideo'] as $key => $value) {
        $id = $value['id'];
        $isExistImg = checkImagexists('uploads/', 'post_' . $id);
        // print_r($value);
        $imgurl = $isExistImg ? 'uploads/post_' . $id . '.jpg' : './directorypage/music.png';
        ?>
				    <li>
				      <img src="<?php 
        echo $imgurl;
        ?>
">
				      <h3><a href="post.php?id=<?php 
        echo $id;
        ?>
"><?php 
        echo $value['name'];
        ?>
</a></h3>
예제 #3
0
					  	<th>Picture</th>
					</tr>
				</thead>
				<tbody>
				<?php 
    foreach ($data['artListing'] as $key => $value) {
        // echo "<pre>"; print_r($value);
        $art_id = $value['id'];
        $com_id = $value['com_id'];
        $art_name = $value['aname'];
        $com_name = $value['cname'];
        $art_add = $value['address'] != '' ? $value['address'] . ',<br /> ' : '';
        $art_city = $value['city'] != '' ? $value['city'] . ',<br /> ' : '';
        $art_state = $value['state'] != '' ? $value['state'] . ',<br /> ' : '';
        $art_nation = $value['country'] != '' ? $value['country'] : '';
        $isExistImg = checkImagexists('uploads/', 'artistcover_' . $art_id);
        $imgurl = $isExistImg ? 'uploads/artistcover_' . $art_id . '.jpg' : './directorypage/music.png';
        $genre = '-';
        $field = '-';
        $category = '-';
        if (isset($value['properties'])) {
            $properties = $value['properties'];
            $genre = isset($properties['genre']) ? $properties['genre'] : '';
            $field = isset($properties['field']) ? $properties['field'] : '';
            $category = isset($properties['category']) ? $properties['category'] : '';
            if (is_array($genre)) {
                $genop = array();
                foreach ($genre as $id => $name) {
                    $genop[] = sprintf('<a href="wml_directory.php?genre_id=%s">%s</a>', $id, htmlentities($name));
                }
            }
예제 #4
0
<?php

/**
 * Developed by Jay Gaha
 * http://jaygaha.com.np
 */
include '../master_admin/includes/inc.php';
include "../master_admin/includes/classes/class.post.php";
$post = new Post();
//new
$data['formStatus'] = 'new';
$data['id'] = 0;
if ($_SERVER['REQUEST_METHOD'] == 'GET') {
    $id = isset($_GET['id']) ? $_GET['id'] : 0;
    $checkRow = $post->get_row($id);
    if (is_array($checkRow)) {
        $data['formStatus'] = 'edit';
        $data['row'] = $checkRow;
        $data['id'] = $checkRow['id'];
        $data['post'] = checkImagexists('../../uploads/', 'post_' . $checkRow['id']);
    }
}
layout('post_form', $data);
예제 #5
0
if ($data['comListing']) {
    $mp_id = $data['cat_row']['mp_id'];
    $mp_type = $data['cat_row']['mp_type'];
    foreach ($data['comListing'] as $key => $value) {
        $com_id = $value['com_id'];
        $com_name = $value['cname'];
        $com_phone1 = $value['phone1'] != '' ? ', ' . $value['phone1'] : '';
        $com_phone2 = $value['phone2'] != '' ? ', ' . $value['phone2'] : '';
        $com_add = $value['address'] != '' ? $value['address'] . ', ' : '';
        $com_city = $value['city'] != '' ? $value['city'] . ', ' : '';
        $com_state = $value['state'] != '' ? $value['state'] . ', ' : '';
        $com_nation = $value['country'] != '' ? $value['country'] : '';
        $com_phone = $value['phone'] != '' ? '<br/>Phone: ' . $value['phone'] . $com_phone1 . $com_phone2 : '';
        $com_fax = $value['fax_no'] != '' ? '<br/>Fax No: ' . $value['fax_no'] : '';
        $com_url = $value['website'] != '' ? '<br/>Website: ' . $value['website'] : '';
        $isExistImg = checkImagexists('../uploads/', 'companylogo_' . $com_id);
        // print_r($value);
        $imgurl = $isExistImg ? '../uploads/companylogo_' . $com_id . '.jpg' : '../directorypage/music.png';
        ?>
                              <div class="cols1">
                                <div class="four columns alpha ">
                                  <div class="col1">
                                    <div class="pic">
                                      <a  href="artist_directory.php?id=<?php 
        echo $com_id;
        ?>
&type_id=<?php 
        echo $mp_id;
        ?>
" style="color: rgb(255, 134, 4);">
                                        <img src="<?php 
예제 #6
0
/**
 * Developed by Jay Gaha
 * http://jaygaha.com.np
 */
include 'includes/inc.php';
include "includes/classes/class.artist.php";
$artist = new Artist();
if ($_SERVER['REQUEST_METHOD'] == 'GET') {
    $del_id = isset($_GET['del_id']) ? $_GET['del_id'] : 0;
    $checkRow = $artist->get_row($del_id);
    if (is_array($checkRow)) {
        $data['cover'] = checkImagexists('../../uploads/', 'artistcover_' . $checkRow['id']);
        $data['pic'] = checkImagexists('../../uploads/', 'artistpic_' . $checkRow['id']);
        $data['pic1'] = checkImagexists('../../uploads/', 'artistpic1_' . $checkRow['id']);
        $data['pic2'] = checkImagexists('../../uploads/', 'artistpic2_' . $checkRow['id']);
        $deleteRow = $artist->delete_row($del_id);
        //delete from properties
        $artist->delete_rows_properties($del_id);
        //delete from social
        $artist->delete_rows_social($del_id);
        if ($data['cover']) {
            unlink('../../uploads/artistcover_' . $checkRow['id'] . '.jpg');
        }
        if ($data['pic']) {
            unlink('../../uploads/artistpic_' . $checkRow['id'] . '.jpg');
        }
        if ($data['pic1']) {
            unlink('../../uploads/artistpic1_' . $checkRow['id'] . '.jpg');
        }
        if ($data['pic2']) {
예제 #7
0
/**
 * Developed by Jay Gaha
 * http://jaygaha.com.np
 */
include 'includes/inc.php';
include "includes/classes/class.music_properties.php";
$properties = new Music_Properties();
if ($_SERVER['REQUEST_METHOD'] == 'GET') {
    $del_id = isset($_GET['del_id']) ? $_GET['del_id'] : 0;
    $id = isset($_GET['id']) ? $_GET['id'] : 0;
    $currentId = $del_id > 0 ? $del_id : $id;
    $checkRow = $properties->get_row($currentId);
    if (is_array($checkRow)) {
        $data['row'] = $checkRow;
        $data['image'] = checkImagexists('../../uploads/', $checkRow['mp_type'] . '_' . $checkRow['mp_id']);
        //delete command
        if ($del_id) {
            $deleteRow = $properties->delete_row($del_id, $checkRow['mp_type']);
            //delete from artist properties
            $properties->delete_rows_properties($del_id);
            if ($data['image']) {
                unlink('../../uploads/' . $checkRow['mp_type'] . '_' . $checkRow['mp_id'] . '.jpg');
            }
            header('Location: ' . $checkRow['mp_type'] . '.php');
        }
    }
}
$data['rows'] = $properties->get_all_rows('genre');
$data['categories'] = $properties->get_all_rows('category');
layout('genre', $data);
예제 #8
0
echo ucwords($data['cat_row']['mp_name']);
?>
</h1>
		<hr />
	</div>
    
  	<div id="tab1" class="tab active">
  		<?php 
if ($data['catListing']) {
    ?>
		<ul class="products">
		<?php 
    foreach ($data['catListing'] as $key => $value) {
        $cat_id = $value['mp_id'];
        $cat_name = $value['mp_name'];
        $isExistImg = checkImagexists('uploads/', 'category_' . $cat_id);
        // print_r($value);
        $imgurl = $isExistImg ? 'uploads/category_' . $cat_id . '.jpg' : './directorypage/music.png';
        ?>
    		<li>
    			<a href="company_directory.php?id=<?php 
        echo $cat_id;
        ?>
">
		            <div class="image" style="background-image:url(<?php 
        echo $imgurl;
        ?>
);"></div>
		            <h1><?php 
        echo ucwords($cat_name);
        ?>
예제 #9
0
include 'tpl/social.php';
?>
                  
              <div class="content">
                    <div id="gallery" class="content_resize"> 
                        <!-- content start -->                  
                          <div class="content_full_size">
                            <h2><?php 
echo $data['post_row']['name'];
?>
</h2>
                            <div class="clr"></div>
                            <div class="sep"></div>
                            <div class="clr"></div>
                            <?php 
$isExistImg = checkImagexists('../uploads/', 'post_' . $data['post_row']['id']);
$imgurl = $isExistImg ? '../uploads/post_' . $data['post_row']['id'] . '.jpg' : '../directorypage/music.png';
?>
						  	<?php 
if ($isExistImg) {
    ?>
                            <div class="pic">
                            	<img alt="Image" src="<?php 
    echo $imgurl;
    ?>
" style="visibility: visible; opacity: 1;"></div>
                            <?php 
}
?>
                            <p><?php 
echo $data['post_row']['details'];
예제 #10
0
<?php

/**
 * Developed by Jay Gaha
 * http://jaygaha.com.np
 */
include 'includes/inc.php';
include "includes/classes/class.banner.php";
$banner = new Banner();
//new
$data['formStatus'] = 'new';
$data['id'] = 0;
if ($_SERVER['REQUEST_METHOD'] == 'GET') {
    $id = isset($_GET['id']) ? $_GET['id'] : 0;
    $checkRow = $banner->get_row($id);
    if (is_array($checkRow)) {
        $data['formStatus'] = 'edit';
        $data['row'] = $checkRow;
        $data['id'] = $checkRow['id'];
        $data['banner'] = checkImagexists('../../uploads/', 'banner_' . $checkRow['id']);
    }
}
layout('banner_form', $data);
예제 #11
0
        $one_day = 86400 + time();
        setcookie('star_' . $arrData['parent_id'], true, $one_day);
        //set cookie for one day
    }
    return false;
}
if (!$id) {
    // === 0 || === null
    header('HTTP/1.1 404 Not Found');
    exit('404, page not found');
}
$data['artist_row'] = $directory->get_artist($id);
if (!$data['artist_row']) {
    header('HTTP/1.1 404 Not Found');
    exit('404, Invalid ID');
}
$rate = $directory->rate($id);
$data['rate'] = $rate['rate'];
$data['total'] = $rate['total'];
$data['page_title'] = 'World Music Listing: ' . $data['artist_row']['aname'] . 'Profile';
$data['id'] = $id;
$data['rate_type'] = 'artist';
$data['musicListing'] = $directory->getMusicDirectoryListing();
$data['special_head'] = true;
$data['social'] = $directory->get_all_social_rows('artist', $id);
$data['pic'][] = checkImagexists('../../uploads/', 'artistcover_' . $id);
$data['pic'][] = checkImagexists('../../uploads/', 'artistpic_' . $id);
$data['pic'][] = checkImagexists('../../uploads/', 'artistpic1_' . $id);
$data['pic'][] = checkImagexists('../../uploads/', 'artistpic2_' . $id);
// echo "<pre>"; print_r($data); exit;
layout('single_profile', $data);