示例#1
0
$wrap_limit = 80;
$blog_id = (int) mysql_real_escape_string($_GET['id']);
$show_v = 0;
$tag_cloud = make_tag_cloud('blogs');
$tag_cloud_block = $tag_cloud[1];
$load_ajax = 1;
$small_block_background = $config['color_tellafriend'];
// this is per each template from config.inc.php advanced config settings
$page_display_small_width = $config['read_blog_member_thumb_width'];
// 65
// declare media type for ratings
$media = 'blogs';
if ($user_id == "") {
    $ajax_rating = pullRating($media, $blog_id, false, true, true, 'novote');
} else {
    $ajax_rating = pullRating($media, $blog_id, true, false, true, $user_id);
}
include_once 'includes/enabled_features.php';
// get blog categories
$all_categories = array();
$sql = "SELECT * FROM blog_categories WHERE has_blogs = 'yes' ORDER BY category_id ASC";
$query = @mysql_query($sql);
while ($result = @mysql_fetch_array($query)) {
    $category_id = $result['category_id'];
    $sql_cnt = "SELECT indexer FROM blogs WHERE category_id = '{$category_id}' AND approved = 'yes' AND public_private = 'public' ORDER BY indexer DESC";
    $query_cnt = @mysql_query($sql_cnt);
    $count_blogs = mysql_num_rows($query_cnt);
    $blog_count = array('category_count' => $count_blogs);
    $new_array = @array_merge($result, $blog_count);
    $all_categories[] = $new_array;
}
$result = mysql_query($query);
$category1 = mysql_result($result, 0, "category");
$query2 = "SELECT name FROM fas_categories WHERE ID='{$category1}'";
$result2 = mysql_query($query2);
$name = mysql_result($result2, 0, "name");
echo '<b>Category:</b> ' . $name . '<br /><br />
		<b>Total Views:</b> ' . $r['views'] . '<br /><br />';
if ($seo_on == 1) {
    $playlink = '' . $domain . '/play/' . $r['ID'] . '-' . $gamename . '.html';
} else {
    $playlink = '' . $domain . '/index.php?action=play&amp;ID=' . $r['ID'] . '';
}
echo '<div class="fb-like" data-href="' . urlencode($playlink) . '" data-layout="standard" data-action="like" data-show-faces="false" data-share="false" data-colorscheme="dark"></div>
       <br /><br />
	   <div align="left">';
echo pullRating($ID, true, false, true);
echo '</div><br />
      </td>';
echo '</tr>
	    </table>
	    <table  width="100%">
            <div class="content_nav2">Bored of this game? check these out!</div>
	<tr>
		<td class=\'content\' colspan=\'2\'>
		<div align=\'center\' style=\'padding:5px;\'>';
$rrb = $db->query('SELECT * FROM fas_games WHERE `active`=\'1\' ORDER BY RAND() LIMIT 0,8');
echo '<table align=\'center\'>
	<tr>';
while ($ro = $db->fetch_row($rrb)) {
    $gamename = preg_replace('#\\W#', '-', $ro['name']);
    if ($seo_on == 1) {
示例#3
0
    public function beerList(array $beers)
    {
        foreach ($beers as $index => $beer) {
            //$beer =
            ?>
	    <div class="beer_listings">
	        <div><?php 
            echo $this->Html->tag('label', 'Name : ');
            ?>
&nbsp; <?php 
            echo $this->Html->link($beer['Beer']['name'], array('controller' => 'beers', 'action' => 'view', $beer['Beer']['id']));
            ?>
&nbsp;</div>
	        <div>
		    <?php 
            echo $this->Html->tag('label', 'Brewery ');
            ?>
 : <?php 
            echo $this->Html->link($beer['Brewery']['name'], array('controller' => 'breweries', 'action' => 'view', $beer['Brewery']['id']));
            ?>
	        </div>
		<?php 
            if (isset($beer['Category']['cat_name'])) {
                ?>
		    <div>
			<?php 
                echo $this->Html->tag('label', 'Category : ');
                echo $this->Html->link($beer['Category']['cat_name'], '/beers/canvas/category_id:' . $beer['Category']['id']);
                ?>
		    </div>
		<?php 
            }
            ?>
		<?php 
            if (isset($beer['Style']['style_name'])) {
                ?>
		    <div>    
			<?php 
                echo $this->Html->tag('label', 'Style : ');
                echo $this->Html->link($beer['Style']['style_name'], '/beers/canvas/style_id:' . $beer['Style']['id']);
                ?>
		    </div>
		<?php 
            }
            ?>
	        <div><?php 
            echo $this->Html->tag('label', 'ABV %');
            ?>
&nbsp;<?php 
            echo h($beer['Beer']['abv']);
            ?>
&nbsp;
		    <?php 
            echo $this->Html->tag('label', 'IBU');
            ?>
&nbsp;<?php 
            echo h($beer['Beer']['ibu']);
            ?>
&nbsp;
		    <?php 
            echo $this->Html->tag('label', 'SRM');
            ?>
&nbsp;<?php 
            echo h($beer['Beer']['srm']);
            ?>
&nbsp;</div>
	        <!--<div><?php 
            echo h($beer['Beer']['upc']);
            ?>
&nbsp;</div>
	        <div><?php 
            echo h($beer['Beer']['filepath']);
            ?>
&nbsp;</div>
	        <div><?php 
            echo h($beer['Beer']['descript']);
            ?>
&nbsp;</div>-->
	        <div class=" b_actions c_actions" style="width:140px;text-align:right;background:white;border:3px groove #CDCDCD;margin:3px;">

		    <?php 
            echo $this->Html->link(__('View ' . substr($beer['Beer']['name'], 0, 8) . '...'), array('action' => 'view', $beer['Beer']['id']));
            ?>
		    <?php 
            echo pullRating($beer['Beer']['id'], true, false, false, NULL);
            ?>

	    	<div style="clear:both">&nbsp;</div>
	        </div>
	        <div style="clear:both">&nbsp;</div>
	    </div>
	    <div style="clear:both">&nbsp;</div>
	    <?php 
        }
    }
示例#4
0
/**
 * FUNCTION USED TO GET VIDEO RATING IN SMARTY
 * @param : array(pullRating($videos[$id]['videoid'],false,false,false,'novote');
 */
function pullSmartyRating($param)
{
    return pullRating($param['id'], $param['show5'], $param['showPerc'], $aram['showVotes'], $param['static']);
}
function writebody()
{
    global $db, $domain, $suserid, $cachelife, $ir, $ir2, $r, $cname, $sponsor, $ads1, $ads2, $ads3, $headerspace, $footerspace, $ID, $sitename, $domain, $template, $gamesfolder, $thumbsfolder, $limitboxgames, $seo_on, $blogentriesshown, $enabledcode_on, $comments_on, $fbcomments_on, $taf_on, $directorypath, $autoapprovecomments, $gamesonpage, $abovegames, $belowgames, $showwebsitelimit, $supportemail, $showblog, $blogentriesshown, $blogcharactersshown, $blogcommentpermissions, $blogcommentsshown, $blogfollowtags, $blogcharactersrss, $usrdata, $userid, $avatar_on, $gender_on, $aimg, $fimg, $mimg, $gamename;
    if (!$ID) {
        echo '<div class=\'error\'>No game selected.</div>';
        return;
    }
    if (!$r['name']) {
        echo '<div class=\'error\'>Game does not exist.</div>';
        return;
    }
    $ir = $db->query(sprintf('SELECT * FROM fas_games WHERE ID=\'%u\'', $ID));
    $r = $db->fetch_row($ir);
    $cname = preg_replace('#\\W#', '-', $cname);
    if (isset($_POST['commentsubmit'])) {
        $commenter = $usrdata['userid'];
        $gameid = $ID;
        $comment = clean($_POST['comment']);
        $date = time();
        if ($autoapprovecomments == 1) {
            $approved = 1;
        } else {
            $approved = 0;
        }
        $db->query(sprintf('INSERT INTO fas_comments SET
						gameid=\'%u\',
						commenter=\'%u\',
						comment=\'%s\',
						date=\'%u\',
						approved=\'%u\'
				        ', $ID, $commenter, $comment, $date, $approved));
        if ($autoapprovecomments == 1) {
            $msgcom = 'Comment Posted.';
        } else {
            $msgcom = 'Comment Posted, Awaiting admin approval.';
        }
        echo '<div class=\'msg\'>' . $msgcom . '</div><br />';
    }
    echo '<div id="container">
<div id="content-container">
<div id="side">';
    include "includes/blocks.php";
    echo '</div>

<div id="content">
<div class="content_nav">' . $r['name'] . '</div>';
    echo '<table width=\'100%\' align=\'center\'>';
    if (!$abovegames == "") {
        echo '<tr>
			<td class=\'content\' colspan=\'2\' ><div align=\'center\'>' . $abovegames . '<p></div></td>
	</tr>';
    }
    echo '<tr>
		<td class=\'content\' align=\'center\' colspan=\'2\'>
		<div align=\'center\'>';
    if ($r['type'] == 1) {
        /**echo '<object width=\''.$r['width'].'\' height=\''.$r['height'].'\'>
        				<param name=\'movie\' value=\''.$domain.'/'.$gamesfolder.'/'.$r['file'].'\' />
        				<embed src=\''.$domain.'/'.$gamesfolder.'/'.$r['file'].'\' width=\'695\' height=\''.$r['height'].'\'></embed>
        			</object>';**/
        echo '<object type="application/x-shockwave-flash" data="' . $domain . '/' . $gamesfolder . '/' . $r['file'] . '" width="695" height="' . $r['height'] . '">
 				<param name="movie" value="' . $domain . '/' . $gamesfolder . '/' . $r['file'] . '" />
 			</object>';
    } else {
        echo $r['enabledcode'];
    }
    echo '
		</div>
		</td>
	</tr>
	<tr>';
    echo '<td class=\'content\' colspan=\'2\'><div align=\'center\'>';
    echo '<a href=\'' . $domain . '/' . $gamesfolder . '/' . $r['file'] . '\' target="_blank" /><img src=\'' . $domain . '/templates/' . $template . '/images/fullscreen.png\' border=\'0\' alt=\'Full Screen\' title=\'Full Screen\' /></a> ';
    if ($seo_on == 1) {
        echo '<a href=\'' . $domain . '/addtofavorites/' . $ID . '/\'><img src=\'' . $domain . '/templates/' . $template . '/images/favorite.png\' border=\'0\' alt=\'Add to my Favorites\' title=\'Add to My Favorites\' /></a> ';
    } else {
        echo '<a href=\'' . $domain . '/index.php?action=addtofavorites&amp;cmd=' . $ID . '\'><img src=\'' . $domain . '/templates/' . $template . '/images/favorite.png\' border=\'0\' alt=\'Add to my favorites\' title=\'Add to My Favorites\' /></a> ';
    }
    if ($usrdata['user_level'] == 1) {
        if ($seo_on == 1) {
            echo '<a href=\'' . $domain . '/report/' . $ID . '/\'><img src=\'' . $domain . '/templates/' . $template . '/images/report.png\' border=\'0\' alt=\'Report Broken Game\' title=\'Report Broken Game\' /></a> ';
        } else {
            echo '<a href=\'' . $domain . '/index.php?action=report&amp;cmd=' . $ID . '\'><img src=\'' . $domain . '/templates/' . $template . '/images/report.png\' border=\'0\' alt=\'Report Broken Game\' title=\'Report Broken Game\' /></a> ';
        }
    }
    if ($usrdata['user_level'] == 2) {
        echo '<a href=\'' . $domain . '/index.php?action=admin&amp;case=managegames&amp;cmd=edit&amp;ID=' . $r['ID'] . '&amp;type=' . $r['type'] . '\' onclick="return confirm(\'Are you sure you want to edit the game ' . $r['name'] . '?\')"><img src=\'' . $domain . '/templates/' . $template . '/images/edit.png\' title=\'Edit Game\' alt=\'edit game\' border=\'0\' /></a> ';
        echo '<a href=\'' . $domain . '/index.php?action=admin&amp;case=managegames&amp;cmd=delete&amp;ID=' . $r['ID'] . '\' onclick="return confirm(\'Are you sure you want to delete the game ' . $r['name'] . '?\')"><img src=\'' . $domain . '/templates/' . $template . '/images/delete.png\' title=\'Delete Game\' alt=\'delete game\' border=\'0\' /></a> ';
    }
    echo '</div></td>';
    echo '</tr>
	</table>

	<table width=\'100%\'>
        <div class="content_nav">' . $r['name'] . ' Details</div>
	<tr>
		<td class=\'content\' colspan=\'2\'><div align=\'center\'>' . $belowgames . '</div></td>
	</tr>

	<tr>
		<td class=\'content\' width=\'70%\' valign=\'top\'><b>Description:</b> ' . $r['description'] . '
		<br /><br />';
    $query = "SELECT category FROM fas_games WHERE ID='{$ID}'";
    $result = mysql_query($query);
    $category1 = mysql_result($result, 0, "category");
    $query2 = "SELECT name FROM fas_categories WHERE ID='{$category1}'";
    $result2 = mysql_query($query2);
    $name = mysql_result($result2, 0, "name");
    echo '<b>Category:</b> ' . $name . '<br /><br />
		<b>Total Views:</b> ' . $r['views'] . '<br /><br />';
    if ($seo_on == 1) {
        $playlink = '' . $domain . '/play/' . $r['ID'] . '-' . $gamename . '.html';
    } else {
        $playlink = '' . $domain . '/index.php?action=play&amp;ID=' . $r['ID'] . '';
    }
    echo '<div class="fb-like" data-href="' . urlencode($playlink) . '" data-layout="standard" data-action="like" data-show-faces="false" data-share="false" data-colorscheme="dark"></div>
       <br /><br />
	   <div align="left">';
    echo pullRating($ID, true, false, true);
    echo '</div><br />
      </td>';
    echo '</tr>
	    </table>
	    <table  width="100%">
            <div class="content_nav">Bored of this game? check these out!</div>
	<tr>
		<td class=\'content\' colspan=\'2\'>
		<div align=\'center\' style=\'padding:5px;\'>';
    $rrb = $db->query('SELECT * FROM fas_games WHERE `active`=\'1\' ORDER BY RAND() LIMIT 0,8');
    echo '<table align=\'center\'>
	<tr>';
    while ($ro = $db->fetch_row($rrb)) {
        $gamename = preg_replace('[^A-Za-z0-9]', '', $ro['name']);
        if ($seo_on == 1) {
            $playlink = '' . $domain . '/play/' . $ro['ID'] . '-' . $gamename . '.html';
        } else {
            $playlink = '' . $domain . '/index.php?action=play&amp;ID=' . $ro['ID'] . '';
        }
        if ($ro['type'] == 1) {
            $imgg = '' . $domain . '/' . $thumbsfolder . '/' . $ro['thumb'] . '';
        } else {
            $imgg = $ro['thumburl'];
        }
        echo '<td>
	<div align=\'center\'><a href=\'' . $playlink . '\'>
	<img src=\'' . $imgg . '\' border=\'0\' width=\'65\' height=\'65\' alt=\'' . $gamename . '\' title=\'' . $gamename . '\' /><br />
	</a>
	</div>
	</td>
		<td width=\'2%\'></td>';
    }
    echo '</tr>
			</table>
		</div>
		</td>
	</tr>
	</table>';
    if ($enabledcode_on == 1 && $usrdata['user_level'] >= 1) {
        echo '<table width="100%">
          <div class="content_nav">Enabled Code</div>
	<tr>
		<td class=\'content\' colspan=\'2\'>
		<div align=\'center\' style=\'padding:5px;\'>
		<textarea cols=\'60\' rows=\'5\'>';
        if ($r['type'] == 1) {
            echo '
&lt;object width=&quot;' . $r['width'] . '&quot; height=&quot;' . $r['height'] . '&quot;&gt;
&lt;param name=&quot;movie&quot; value=&quot;' . $domain . '/' . $gamesfolder . '/' . $r['file'] . '&quot;&gt;
&lt;embed src=&quot;' . $domain . '/' . $gamesfolder . '/' . $r['file'] . '&quot; width=&quot;' . $r['width'] . '&quot; height=&quot;' . $r['height'] . '&quot;&gt;
&lt;/embed&gt;
&lt;/object&gt;	';
        } else {
            echo '
' . $r['enabledcode'] . '
';
        }
        echo '</textarea>
		</div>
		     </td>
	    </tr>
	    </table>';
    }
    $gamename = preg_replace('#\\W#', '-', $r['name']);
    if ($seo_on == 1) {
        $playlink = '' . $domain . '/play/' . $r['ID'] . '-' . $gamename . '.html';
    } else {
        $playlink = '' . $domain . '/index.php?action=play&amp;ID=' . $r['ID'] . '';
    }
    if ($fbcomments_on == 1) {
        echo '<table  width="100%">
       <div class="content_nav">Comments</div>
	    <tr>
        <td><div class="fb-comments" data-href="' . $playlink . '" data-numposts="5" data-colorscheme="light" data-width="100%"></div></td>
        </tr>
        </table>';
    } else {
    }
    if ($comments_on == 1) {
        echo '<table  width="100%">
        <div class="content_nav">Comments</div>
	    <tr>
		     <td  width=\'70%\' valign=\'top\' colspan=\'2\' align=\'center\'>
		<div align=\'center\'>
		<table width=\'100%\' border=\'0\'>';
        $gamename = preg_replace('#\\W#', '', $r['name']);
        if ($seo_on == 1) {
            $comlink = '' . $domain . '/play/' . $ID . '-' . $gamename . '.html';
        } else {
            $comlink = '' . $domain . '/index.php?action=play&amp;ID=' . $ID . '';
        }
        if (!isset($suserid)) {
            $commentvar = 'You must be logged in to post a comment';
        } else {
            $commentvar = '
				<form action=\'' . $comlink . '\' method=\'post\'>
				<textarea cols=\'60\' rows=\'5\' name=\'comment\'></textarea>
				<br />
				<input type=\'submit\' name=\'commentsubmit\' value=\'Add Comment\' />
				</form>';
        }
        echo '<tr>
				<td colspan=\'2\' class=\'content\'>
				<div align=\'center\'>' . $commentvar . '</div>
				</td>
        </tr>';
        $rrr2 = "SELECT * FROM fas_comments WHERE gameid='{$ID}' AND approved='1' ORDER BY date DESC LIMIT 3";
        $sqltitle = "gamecomments-" . $ID;
        if ($rrr1 = sqlcache($sqltitle, $cachelife, $rrr2)) {
            foreach ($rrr1 as $row) {
                $date = date('M-d-Y', $row['date']);
                $useridc = $row['commenter'];
                $rra2 = "SELECT * FROM fas_users WHERE userid='{$useridc}'";
                $sqltitle = "userprofile-" . $row['commenter'];
                $rra1 = sqlcache($sqltitle, $cachelife, $rra2);
                foreach ($rra1 as $rra) {
                    $useridl = $row['commenter'];
                    $avatarfileurl = get_avatar($useridc);
                    if ($seo_on == 1) {
                        $urlp = '' . $domain . '/showprofile/' . $useridl . '.html';
                    } else {
                        $urlp = '' . $domain . '/index.php?action=showprofile&amp;profile=' . $useridl;
                    }
                    if ($row['commenter'] == '0') {
                        $commenter = 'Guest';
                    } else {
                        $commenter = $rra['username'];
                    }
                    echo '<tr>
		     <td width=\'20%\' class=\'content\' style=\'padding:4px;\' valign=\'top\'>
		                <div align="center"> <b>Posted By:</b> <a href="' . $urlp . '">' . $commenter . '</a><br />
		                <a href="' . $urlp . '"><img src=\'' . $domain . '/avatars/' . $avatarfileurl . '\' height=\'50\' width=\'50\' title=\'' . $commenter . '\'/></a><br />
                        <small><i><b>Posted On:</b> ' . $date . '</i></small></div>
		     </td>
		     <td valign=\'top\' class=\'content\'>' . $row['comment'] . '';
                    if ($usrdata['user_level'] == 2) {
                        echo '<div style="float: right; padding-right: 20px;">
	        <a href=\'' . $domain . '/index.php?action=admin&amp;case=managegamecomments&amp;cmd=edit&amp;ID=' . $row['ID'] . '\'  onclick="return confirm(\'Are you sure you want to edit this comment?\')"><img src=\'' . $domain . '/templates/' . $template . '/images/edit.png\' border=\'0\' alt=\'Edit Comment\' title=\'Edit Comment\' /></a>
	        <a href=\'' . $domain . '/index.php?action=admin&amp;case=managegamecomments&amp;cmd=delete&amp;ID=' . $row['ID'] . '\'  onclick="return confirm(\'Are you sure you want to delete this comment?\')"><img src=\'' . $domain . '/templates/' . $template . '/images/delete.png\' border=\'0\' alt=\'Delete Comment\' title=\'Delete Comment\' /></a>
	        </div>';
                    }
                    echo '</td>
        </tr>
        <tr>
		     <td width=\'100%\' colspan=\'2\' class=\'content\'>&nbsp;</td>
	    </tr>';
                }
            }
        } else {
            echo '<tr><td colspan=\'2\' class=\'content\'>No Comments Yet!</td></tr>';
        }
        if ($seo_on == 1) {
            $urco = '' . $domain . '/showcomments/' . $cname . '/' . $ID . '/1.html';
        } else {
            $urco = '' . $domain . '/index.php?action=showcomments&amp;name=' . $cname . '&amp;ID=' . $ID . '&amp;page=1';
        }
        echo '<tr>
				<td width=\'100%\' colspan=\'2\' class=\'content\'><a href=\'' . $urco . '\'><small><i><b>More Comments</b></i></small></a></td>
		</tr>';
        echo '</table>';
    }
    if ($seo_on == 1) {
        $taf1 = '' . $domain . '/taf/';
    } else {
        $taf1 = '' . $domain . '/index.php?action=taf';
    }
    if ($taf_on == 1) {
        echo '<table width="100%">
           <div class="content_nav">Tell a Friend</div>
	    <tr>
				<td  width=\'70%\' valign=\'top\' colspan=\'2\' class=\'content\' align=\'center\'>
		<div align=\'center\'>
        <form action =\'' . $taf1 . '\' method=\'POST\'>
	    <tr>
				<td class=\'content\'>Your Name: </td>
				<td class=\'content\'><input type=\'text\' name=\'sender\' size=\'50\'></td>
	    </tr>
	    <tr>
				<td class=\'content\'>Your friend\'s e-mail: </td>
				<td class=\'content\'><input type=\'text\' name=\'recipient\' size=\'50\'></td>
	    </tr>
	    <tr>
				<td class=\'content\' colspan=\'2\'>
				<input type=\'hidden\' name=\'gamei\' value=\'' . $ID . '\'>
				<input type=\'hidden\' name=\'gamen\' value=\'' . $gamename . '\'>
				<input type=\'submit\' value=\'Send\'>
				</td>
	    </tr>
	    </div>
        </table>';
    } else {
    }
    echo '</div>
				</td>
	    </tr>
	    </table>';
    echo '</div></div></div>';
    $useridp = $usrdata['userid'];
    if ($useridp == '0' or $useridp == '') {
        $useridp = '-1';
    }
    $db->query(sprintf('UPDATE fas_games SET views=views+1 WHERE ID=\'%u\'', $ID));
    if ($useridp != '-1') {
        $db->query('UPDATE fas_users SET plays=plays+1 WHERE userid=\'' . $useridp . '\'');
    }
    $db->query('UPDATE fas_gamestats SET total_played = total_played + 1,played_today = played_today + 1');
    // adds a play to the total plays and played today stats
}
示例#6
0
    public function lastFiveBeersSidebar(array $beers, $id = '')
    {
        ?>
	<h3 id="<?php 
        echo $id;
        ?>
_toggle">Last 5 Beers Viewed</h3>
	<div class="sidebar" id="<?php 
        echo $id;
        ?>
">
	    <?php 
        foreach ($beers as $index => $beer) {
            //$beer =
            ?>
	        <div>
		    <?php 
            echo $this->Html->link($beer['Brewery']['name'], array('controller' => 'breweries', 'action' => 'view', $beer['Brewery']['id']));
            ?>
<br />
		    <?php 
            echo $this->Html->link($beer['Beer']['name'], array('controller' => 'beers', 'action' => 'view', $beer['Beer']['id']));
            ?>
	        </div>
	        <div style="width:140px;text-align:right;background:white;border:3px groove #CDCDCD;margin:3px;">
		    <?php 
            echo pullRating($beer['Beer']['id'], true, false, false, NULL);
            ?>
	        </div>
	        <div style="clear:both">&nbsp;</div>
	    <?php 
        }
        ?>
	</div>
	<?php 
        $this->Js->get("#" . $id . "_toggle")->event('click', '$("#' . $id . '").toggle()');
    }
示例#7
0
 $album_name = $result['gallery_name'];
 $date_uploaded = $result['date_uploaded'];
 $allow_comments = $result['allow_comments'];
 $allow_embedding = $result['allow_embedding'];
 $public_private = $result['public_private'];
 $number_of_views = mysql_real_escape_string($result['number_of_views']);
 $image_id = $result['indexer'];
 $image_view = $result['image_id'];
 $member_id = $result['user_id'];
 $social_image_url = $config['site_base_url'] . "/view-image/" . $image_id . "/" . $title_seo;
 $page_title = $title;
 $media = 'images';
 if ($user_id == "") {
     $ajax_rating = pullRating($media, $image_id, false, true, true, 'novote');
 } else {
     $ajax_rating = pullRating($media, $image_id, true, false, true, $user_id);
 }
 list($width, $height) = getimagesize("addons/albums/images/{$image_view}");
 $page_display_width = 400;
 $page_display_height = 386;
 //308;
 if ($width <= $page_display_width && $height <= $page_display_height) {
     $new_width = $width;
     $new_height = $height;
 }
 if ($width > $page_display_width) {
     $large_img_ratio = $width / $height;
     if ($large_img_ratio > 1) {
         $new_width = $page_display_width;
         $new_height = $page_display_width / $large_img_ratio;
     } else {
示例#8
0
$audio_js = 1;
$progress_bar_width = 0;
$blk_notification = '';
$small_block_background = $config['color_tellafriend'];
$default_album_pic = $config['default_album_pic'];
$load_ajax = 1;
$wrap_limit = 80;
$codes = (int) mysql_real_escape_string($_GET['code']);
$proceed = true;
$enabled_audio_comments = $config['enabled_features_audio_comments'];
$audio = (int) mysql_real_escape_string($_GET['audio']);
$media = 'audios';
if ($user_id == "") {
    $ajax_rating = pullRating($media, $audio, false, true, true, 'novote');
} else {
    $ajax_rating = pullRating($media, $audio, true, false, true, $user_id);
}
//________________________________________________________
//___Enabled Features Check_______________________________
include_once 'includes/enabled_features.php';
//START-----------------------
if ($config['allow_download'] == 'yes') {
    $allow_download = 1;
}
$sql = "UPDATE audios SET playtime = NOW() WHERE indexer = {$audio}";
$query = @mysql_query($sql);
$sql = "SELECT * FROM audios WHERE indexer = {$audio} AND approved = 'yes'";
$query = @mysql_query($sql);
$result = @mysql_fetch_array($query);
$active = $result['approved'];
$public_private = $result['public_private'];