I am trying to make a webpage that only new users can see if a returning viewer returns he will be redirected to another webpage I found this on stackoverflow but I am unable to figure it out.
I have made a HTML and CSS page which showcases the features of my web app. I want this page to load only for new visitors. If a returning visitor visits my domain, it should redirect him/her to the web platform. Essentially, the new user should see "Landing Page" while a returning user should be redirected to "Web Platform"
The answer was
How do I make a web page show up only once?
I am unable to use it because I don't know what to do and how to create localstorage
You should use PHP code to make a webpage only available once with SESSION and log.
Related
I have a simple online shopping website and i want to ensure that the user is coming from the payment page not open the success page directly. I am using PayuMoney
Please take a look at this example of someone asking a similar question:
Creating a Secure File Hosting Server for PDFs
Redirecting in most ways is unreliable and can be spoofed easily.
I'm relatively certain after reading the facebook Open Graph documentation that I can't have a web site 'subscripe' to a public page, unless that page installs my app. Let me know if that is wrong.
What I am trying to make is a photo gallery, pretty simple, but it grabs photos from a public 'page' such as a college or university.
I would like it to update itself anytime there is a change. I was hoping I could do it through the API, possibly using API updates/subscription
Facebook App Subscriptions -
but I don't think that will work. I'm using PHP, are there other ways to listen and see if there has been a change? Other than just firing off a function every now and then, using CRON or some other such server tool. I would think that facebook would probably also not like that behavior, though I'm not sure.
As of right now, I am able to grab JSON from a public page's photo gallery using the API and the photo gallery works just fine, I'm mostly just wondering what the optimal of having it update itself automatically is.
You are correct in assuming that real-time updates for pages require admin access to the page to work. You need a page access token to be able to subscribe to updates for a specific page, and such a page access token you can only get from users that have admin privileges for that page. (The page does not need to install your app as a tab any more, they changed the subscription process in that regard; but the page access token is still necessary. Basically you can say, you can not subscribe to updates for just any arbitrary page, it has to be “your” page.)
Apart from that, all you can do is check for new content by requesting the current data in a sensible interval.
you need to get page access token, which is granted when the user is one of the Page Admin, check the documentation on Facebook
https://developers.facebook.com/docs/graph-api/reference/page
look for this line
"access_token": "The access token you can use to act as the Page. Only visible to Page Admins"
I am developing a web+app system and I would like to know if there is any way that Facebook tells me how many likes has an URL I post in a user wall.
What I would like is that when some users hits like, a GET (or POST) Request to my server is called so I can store the external hit in my database without having to update it every time.
Does it even exist?
Maybe FB.Event.Subscribe can help you?
From the docs:
FB.Event.subscribe allows you to define callbacks that will be called
when certain events take place on your site. These events include:
Logging in or logging out via Facebook Login
Someone likes or unlikes a page via an embedded like button
Rendering of social plugins
Comments are added or removed
Someone sending a message to your page or a friend via an embedded send button
I have a webpage hosted in my local server being displayed inside a Page Viewer Web Part in SharePoint 2007.
I would like to include a user check inside the pages in my server, so when an user tried to access some page through the SharePoint web part, the page would first check who is the user logged in SharePoint trying to access the page, and then check if the specific user is allowed to see that page.
I have tried the most common solutions found online using js and/or php: SPAPI, SPContext and Jquery SPServices, but wasn't able to make any of them work with the php pages in my local server.
Is there a practical way to get the user who is accessing the page? I am new to web development, so I would appreciate any help.
in your case the problem is how to pass user identity from SharePoint to your PHP page as SharePoint user (as well as any other SP information) is not accessible directly in page displayed within Page Viewer webpart. Page Viewer webpart uses IFRAME to display specified page.
I suggest you to use ContentEditor webpart to include your own IFRAME and some javascript to the SharePoint page. Within the javascript you can use SPServices to get user info and pass it to SRC attribute of IFRAME as the part of PHP page URL .
Drawback of this is that advanced user can construct the the URL by itself and pass username of another user.
I'm trying to do something similar to the login/registration flow described on this page but via php only.
http://developers.facebook.com/docs/plugins/registration/
What I want to do is display a register link if a user is logged in to facebook but not registered with my site, and a login link if they're not logged in to facebook, however I want to do this all on my side in php, and not using the fb:login-button widget. Is this possible?
I have the login url working, i just want to change the name of the button based on the users status.
You can't do it without loading the javascript lib. If you load nothing from Facebook on the client, then there is no way to do cross domain communication (security). Which means there is no way to tell who the user is, much less if they are logged into Facebook. By loading the javascript API on the client, the javascript code can check for a Facebook cookie and determine who they are and whether they are logged into Facebook or not.
Check through javascript and do a page reload if need be. Better yet, just use css to show/hide what you want.
http://developers.facebook.com/docs/reference/javascript/FB.getLoginStatus/
Yes, it is possible. Here's a tutorial:
Tutorial,
Example tutorial