I have a script that get the $_SERVER['HTTP_REFERER'] when a user visits my page. This works great if it is used on facebook for desktop. But if a user click the link in the mobile app facebook messenger it can't get any HTTP_REFERER.
Anyone have a solution for getting info about if the user clicked a link in the facebook messenger app?
The problem is that when a user clicks on a link the the facebook app, it isn't being redirected, but opened. Since the app isn't a web browser.
If you wanna track where people open your site from, you could parse in a UTM code (just a _GET parameter, but globally used to track origin, many sites like google also uses these, and some even auto append them.).
For more info, see the following article: http://www.launchdigitalmarketing.com/seo-definitions/what-are-utm-codes/
Related
We can get the referrer site with "$_SERVER['HTTP_REFERER']". However, if the incoming person clicked on the link in an application, how can I detect it? For example, how can I detect if the visitor came to my page by clicking on the link in the whatsapp message. Here, the link address clicked with "$_SERVER['HTTP_REFERER']" is obtained. How can I get the information that the person who came here has come from applications such as whatsapp, telegram, messenger.
Thanks.
I am currently running several ads on facebook and I have just started using the facebook-click-id to replace facebook-pixels for the tracking. For some reason I have found that there are a lot of clicks coming in through the ads without the fbclid-parameter attached to the url as a get-parameter.
Through a google search I have found out that the only reasons the fbclid-parameter would not be attached to the url would be that the user clicking on the ad is not logged in to facebook or that the user is using his/her browser with the incognito-mode activated.
It seems odd to me that so many clicks could happen under those circumstances. Which is why I am wondering if there are other reasons why the facebook-click-id (fbclid-parameter) would not be attached to the url.
Are there any other reasons why the fbclid-parameter would not be attached to the outgoing url of a facebook ad? Thanks!
after doing some tests trying to solve the same problem, what I noticed is that fbclid parameter did not appear in outbound links when using the browser built into the mobile Facebook app.
So, I think that this is a Facebook limitation.
Hope it helps,
I want to link a user to make a share post on my fb company page without having to authenticate. Currently I can get them to share on their own wall with:
But I'm not sure how I can get this to share to a page's wall rather than their timeline.
I got somewhat close by using the dialog feature:
https://www.facebook.com/dialog/feed?app_id=xxx&link=xxx&picture=xxx&name=xxx&caption=xxx&description=xxx&redirect_uri=xxx
But that just showed it as a normal share but done "via appName", unless there is a step I'm missing to link my app to my facebook page?
Thank you!
Unfortunately, the sharer.php method is used only to share only on the user's timeline.
If you want to ask the user to post on a page's timeline, you have to create an app, ask the user to authenticate it and then use the Facebook APIs to post on their behalf. I guess that will be cumbersome in your case, so I would just suggest you redirect to the particular Facebook page.
You can't !
To publish on YOUR page timeline, users need to have the rights to do it (be admin, writer, ...) : it's a manual requirement on the Facebook interface.
I'm new to Facebook API. Upon reading the developers page, there are 3 types of apps to choose from. I'm trying to create something very similar to Dailymotion app whereas when the user watched a video on dailymotion, it is automatically posted on their wall.
I know the basics of authentication, what I would want to know is how to start doing this app. I found the dailymotion app and whenever I try to go to it, it just redirects to their homepage (how was it done by the way? clicking the 'go to app' button leads to their site).
here's the app: http://www.facebook.com/apps/application.php?id=96937694899&ref=ts
I just found out how to do it. In facebook app page, you must uncheck everything under: "Select how your app integrates with Facebook" - Thats how I set it and when you click the app, it just redirects to the homepage and not an iframe FB app.
Regarding the "_ watched a video on Dailymotion". Those are actions and objects using open graph as stated by Dhiraj.
Its a reveal page app and
The app check if the user likes the fanpage through signed_request, if not it shows an image that says like us, else it shows the content to the fan.
This works fine when someone comes to the fanpage i.e. app is running within the fanpage as a tab. e.g. http://www.facebook.com/myfanpage?sk=app_xxxxxxxxxxxxxx
If someone comes to the app directly e.g. http://apps.facebook.com/myappname it always shows the image that says like us whether user already likes or not.
Is there a way to check how the app is being accessed? directly or as a tab in the fan page? I can not use 'top.location.href' in javascript, it returns null I guess because of obvious reasons of cross domains, i.e. app is running from some other domain and not on facebook.
Regards
You can use the Facebook JavaScript SDK to call the Graph API URL in the form https://graph.facebook.com/PROFILE_ID/likes/PAGE_ID and see if the user likes your page.
See this link for documentation: http://developers.facebook.com/docs/reference/api/user/#likes