Changing privacy of old Facebook posts using the Graph API
Date : March 29 2020, 07:55 AM
hop of those help? 1) Nope. 2) Yes, you can use the Graph API and HTTP Get me/feed?until={date}
|
How to show own posts if privacy is set to friends
Date : March 29 2020, 07:55 AM
it should still fix some issue Without more info (sample data, for example), I'd say: try the following: $result = mysql_query("
SELECT t.tid, t.title, t.time, t.authorid, t.photo, f.fuid, f.myuid, u.username as writer
FROM topics as t, friends as f, users as u
WHERE cid='$cid'
AND u.id=t.authorid
AND (
f.fuid=t.authorid AND f.myuid='$myid'
OR
f.myuid=t.authorid AND f.fuid='$myid'
OR
t.autorid='$myid'
)
ORDER BY tid DESC
LIMIT $start, $perpage
");
|
Load all posts and check if the post is liked or not in laravel
Date : March 29 2020, 07:55 AM
will be helpful for those in need First, I would change up your initial query a little bit. I'd get the posts liked by the user like this (assuming the Post has a likes relationship): $profileLikedPosts = Post::whereHas('likes', function($query) use ($user) {
return $query->where('user_id', $user->id);
})
->get();
// The "whereIn" just limits the results to those posts already retrieved
// for the profile user. Not required, but gives a little performance boost
// if this collection doesn't need the non-profile-liked posts.
$authUser = Auth::user();
$authLikedPosts = Post::whereHas('likes', function($query) use ($authUser) {
return $query->where('user_id', $authUser->id);
})
->whereIn('id', $profileLikedPosts->lists('id'))
->get();
@foreach ($profileLikedPosts as $post)
// ...
@if ($authLikedPosts->contains('id', $post->id))
// this post is liked by both; show your icon
@endif
// ...
@endforeach
|
Facebook Graph API - How to read posts privacy
Date : March 29 2020, 07:55 AM
Does that help The error message is very clear, there is no field called "value" in the user table - which is exactly what you are trying to access with the /me endpoint. This would be the API call to get the privacy setting of a specific post: https://graph.facebook.com/{post-id}?fields=privacy{value}&access_token={user-token}
|
How to publish posts depend on privacy?
Tag : mongodb , By : Sergio Rudenko
Date : March 29 2020, 07:55 AM
|