Adding multiple facebook page tabs from single facebook application using php - facebook-page

I have created a facebook application.
Now i want that using this application i need to add multiple pagetabs in a page.
and all of this i want to do in php
I have completed following steps
1) Logged in to facebook using my php script and got authenticaticationc code for managing pages.
2) Retrieved the list of pages i have in loged in users profile.
Now i don't know how to add a page tab in facebook programmatically.
I know there is a manual option and that is in applications settings to add a page tab
but I want to add it Programmatic using php.
Any help will be very appreciated.
regards

Applications are allowed to have one Page Tab. So if you need to have multiple tabs for same app on single page where is no way to achieve this.
If you desire to add tabs for other applications you just need to issue POST with page access_token (from accounts connection of user who is admin of that page) request to:
https://graph.facebook.com/PAGE_ID/tabs?app_id=APPLICATION_ID&access_token=...
You need either repeat that step for every APPLICATION_ID you want to be added as tab or Batch requests. Read more on page tabs creation in documentation for page object

Related

Can i have two Default ASPX pages?

Actually i've started to programm in ASPX using VB.NET as language i've made a client part website where the user can see different kind of products in the Default.aspx page and open a support ticket in another page.
Now i would make an admin part of the website and make a different Default page for it. So the question is it possible to show another Default.aspx page if an admin is logged?
Actually i'd accept all suggestion on how could i do it as better as possible.
Solved by using
FormsAuthentication.SetAuthCookie(username.Value, True)
Instead of
FormsAuthentication.RedirectFromLoginPage(username.Value, True)
It is not necessary.
You can have two pages and redirect or show the Admin's Page when the administrator is logged in.

Symfony feature to take screenshots of pages that require user to login

I have an app built with Symfony 2. It has a bunch of pages that are secured and require user to login. Once the user is logged in I want there to be a "Download Screenshots" Button. When they click that button, I would like a process to go through all the pages of the site and take screenshots. What tool should I use to take the screenshots? Thanks!
I haven't used this so I can't speak for how well it works, but check out https://github.com/microweber/screen

Tracking login in user time on page on Wordpress

I have a simple informative website built in Wordpress. Users must login befor they can view pages ,I would like to track the time each user is viewing each page. Is there a simple plugin or JavaScript I can use to make a database of this information.
Would something like the following suffice?
https://en-gb.wordpress.org/plugins/aryo-activity-log/

Easy way to track website user activity

We want to track all visitor activities for logged users so we can get better insight into visitor behavior and gather more data for each individual user.
What options are available for something like this that does not require us to add code to every single website page? Are there some existing libraries for this?
Here are couple different options you can try:
If your website uses one or more master pages you can try adding code only to master pages.
Create custom http module you will later integrate into IIS. Check this article for more details

Page Administration & Open Graph

I'm an Admin for this page
http://developers.facebook.com/tools/debug/og/object?q=http%3A%2F%2Fwww.westberks.gov.uk%2Findex.aspx%3Farticleid%3D23789
and I've also specified that my App can administer it too. I've Liked this page so I thought I should be able to access the admin screen for the page but I can't seem to. Any ideas on how I access the admin screen for this page in FB, so I can manually publish updates?
Additionally, when I try to update page programmatically I get the message
(OAuthException) (#200) The user hasn't authorized the application to perform this action
but the page has my App listed here
http://graph.facebook.com/10150303466842688
This was definitely a bug rather than a programming or setup issue. The bug has been marked fixed by Facebook as of 1/18/2012 and everything now works as it is supposed to! Bug report:
http://developers.facebook.com/bugs/308356579205492?browse=search_4f0f1475c470b2076799347
Until this recent fix, there was a problem where OpenGraph pages did NOT allow the admins of those pages to retrieve page access tokens for them. Which means they were locked out of posting "as the page" and apparently also locked out of the Admin area for their own pages as well.
I know that this is fixed for me now with this bugfix, and hopefully it will also be fixed for everyone else.
You will need to ask for manage_pages, read_stream and publish_stream. Once your admin accepts those permissions, the app can call me/accounts on the Graph (play here https://developers.facebook.com/tools/explorer). In there will be a list of all the pages they admin. In each listing will be a unique access token. This is called the page access token. Using that token you should be able to read and write to the me/feed for that page.

Resources