コード例 #1
0
ファイル: _pb_og.php プロジェクト: JosephsPlace/PccBay
function pb_og($call = null, $data = null)
{
    $openGraphPages = array('feed', 'products', 'questions', 'discussions', 'comments', 'tags', 'users', 'images', 'notify', 'smartsearch');
    $return = null;
    if ($call == 'token') {
        if ($data === null) {
            $data = OG_APP;
        }
        $data = explode(':', $data);
        $return = pb_graph_token($data[0], $data[1]);
    }
    if ($call == 'access_token') {
        $data = explode(':', $data);
        $token = pb_time('token:' . $data[0], array('expire' => $data[1], 'key' => md5($data[1])));
        $return = array('token' => $token, 'expire' => $data[1], 'key' => md5($data[1]));
    }
    if ($call == 'site') {
        $return = domain($data);
    }
    if (in_array($call, $openGraphPages)) {
        $return = pb_og_fgc($call, 'q=' . $data);
    }
    return $return;
}
コード例 #2
0
ファイル: index.php プロジェクト: JosephsPlace/PccBay
				post.find('.pb-post-tags ul').empty();
				$.each( tagsHTML, function( key, tag ) { 
					post.find('.pb-post-tags ul').append('<li><a href="/s/'+tag+'">'+tag+'</a></li>'); 
				});
			}
			
			post.find('.pb-post-foot-fill').append(foot);
		}
	});
}	
$(document).ready(function(){
	var tail='null';
	if(thispage().indexOf('@') !== -1){ tail=thispage().substring(1); userUrl(tail); }
	var ini_gridCount=0;
	var JsonURI = '/graph/feed?accessToken=<?php 
print pb_graph_token('9827354187582375129873', '712638715312875');
?>
&loop=20&q='+tail;
	$( 'div#freewall' ).lazyjson({
	    api: {
	        uri: JsonURI
	    },
	    afterLoad: function (res) {
		    clearTimeout(iniTimer);
		    ini_grid_ext(JsonURI);
		    if(ini_gridCount===0){
			    ini_grid(ini_gridCount);
		    }
		    ini_gridCount++;
	    },
	   pagination: {