Do I need back-end and database for single page app using Facebook Connect? - database

I want to create a one page site that will use Facebook Connect and allow my friends to reserve a spot for an upcoming event. Using there Facebook ID I would like my friends to pay(reserve) a spot and then show their Facebook picture in the spot they reserved. Sort of like Meetup.com when you RSVP except its a one page site and for a one time event. Can I build this only using front-end technologies or do I need a backend?

The answer is yes, you will need a back end system to store the paid registrants, print out a list of paid users to have at the door of the event to make sure they paid, store the user id to be able to display their picture, etc. etc. etc.

Related

Tracking visitors who visited website with a code in url with Google Analytics

I have a React website, I want to build a system that first a code is created for example its "my-special-code-100". I want to track website visitors who entered the website from a url like https://mywebsite.com/../?code=my-special-code-100 and need to track if or if not X 'not signed in' visitor do a successful payment - a button click on specific page - also need to store an account id of the wallet, payment that happened, and need to see trackings of how many visitors of website came with "my-special-code-100"(and other codes) and how many of them made a payment and stored wallet id should be visible for that visited user.
I couldn't be sure how to and is Google Analytics correct tool for this and could you give example what can I use to achieve something like this ? Thanks

Create a multiple messenger chat from the API

I want to create a "social" service of meetings between groups of strangers.
Since people do not know each other before meeting, I wish they could communicate before and especially before the appointment in case someone wants to prevent a delay or can not find others, or is first come on the scene for example...
This service would be accessible on the Web (no mobile application).
I told myself that integrating an available solution "offsite" would be a good idea because it allows to be used also on the phone. I thought of Messenger that is convenient because everyone or almost has facebook.
My idea is that people who sign up for a meeting are automatically added to a messenger group (or at least if the API does not allow it to create a group chat link they can join of their own chief...)
I have researched the API messenger and I have not found for the moment a way to create a group with Facebook IDs eg targeted.
Do you know if this is possible or something that has come closer in case it is not ?
for example a bot that creates a chat link with the users affected by the event ...
The Messenger API is for communication between Pages and (single) Users only. There is no API for User to User chats. You would have to create your own solution - Node.js with Socket.IO is perfect for that, for example.

2 apps with the same database in Firebase

My project is to create an app similar to Uber.
There are 2 APPs, one for partners and the other for clients and I saw that I can create more than one app within the same Firebase project,that way I can use the same database for both APPs.
What I did not understand, how to do is differentiate the partners and the clients?
In the "Auth" menu, I would have to differentiate them with a Boolean.
Can I do this using Firebase? If not, does anyone know show me another way to do? or another database?
Another question I have is in relation to part of the payment, How I store the data of the credit card at Firebase? It support for this? Does anyone know show me a library to make payments straight through the app?
I don't think you can do that from the "Auth" Menu. This "Auth" function is only there for the sole purpose of letting user signup and login to your app.
You just need to implement the user category in your Real time database.
Store the user's uID, with key:value "userType":"client" or "userType":"partner".
And whenever the associated uID logs into your app succesfully. you need to read from the Real Time database to determine whether this user is a "client" or "partner" and show the appropriate functionality accordingly (or direct them to a different View controller eg: ClientViewController / PartnerViewController). Or if you have 2 entirely separate apps. Then this can act as a verification, just to make sure if this user is indeed a partner / client.
I'm not sure what to do with the payment system. But you can look at library like Braintree or something.

Integrate SurveyMonkey in an existing community

I have a cakePHP community. User are able to signup and login. I like to create a survey using SurveyMonkey.
Therefor I create the survey and make it available to my members using the direct URL. In my member database I have to save the information "did completed the survey = yes/no".
Is there any way to identify the user filling in the survey and write this information into the database?
SurveyMonkey has an API https://developer.surveymonkey.com/ , that let you collect info from your survey (completedf or not).
This is the only way i think, (if it s not include in your website).
I know that you can simply do this with Examinare Survey Tool. What you do first is that you use the API inside Examinare to add a recipient for all the users in the survey base.
Use the PHP Wrapper library in their developer site.
Loop it through and use the https://developer.examinare.com/php-wrapper-library/ and use the example code.
If you let people register with same email more than 1 time then save the ContactID into your database on the recipient.
Then to not create an email invite you use this : markrecipientstosurvey
The surveyID is available inside the Examinare account.
When you done this script part then make it as a cronjob for instance inside the crontab -e
I would run it every 30 minutes or 1 per hour.
Next part you create a page for the survey redirect where you use the function: listsurveysbyuser
to get the survey version and url
(there is a special link for the mobile user that even works for the normal mobile phone NOT only smartphones)
Now you just redirect them to the survey. If you want them to return to your site after then you use the redirect_url parameter that is added to the url or use the redirect inside your account. Ask support about that if you need :) They are fast... Never had to wait more than a couple of minutes.
When the person return then just check if they are marked as complete with the same api call: listsurveysbyuser
Looks much but it is very easy to implement and if you have any problems then just ask the support at support#examinare.com I have asked alot and never had them to say that it can not be done. Really nice!
EDIT:
I see that they just released a tutorial much better than my example:
https://developer.examinare.com/how-to-use-surveys-in-cakephp-with-very-little-development/
One option:
Use unique Custom Variables in the URL that is visited by each member of the community
For example, https://www.surveymonkey.com/s/your_survey?userid=$my_user_id
Note that you can create weblink or email collectors with the API (endpoints: create_flow or create_collector).
Then track the responses using the get_respondent_list or get_responses endpoints of the API.
Note: Please confirm with the Survey Monkey API team that the custom variables can be read via the API.
Another option:
Use the email collector (create_flow) API endpoint and send it to your members' email addresses.

Access VisualForce Page without salesforce account

I'd like to create visualforce page that inserts a record into salesforce account object. However, I expect some of the page users won't have salesforce accounts. Can they still access it? If not, what are the alternatives that can be used to visualforce page in this case? (Please don't consider Web to Lead Forms).
Thanks,
Yes, it's possible. Go read about Salesforce Sites. For a start:
http://wiki.developerforce.com/page/Websites
http://wiki.developerforce.com/page/An_Introduction_to_Force.com_Sites
(of course it's also possible to write that page in say Java/.NET/PHP and use integration via SOAP or REST to talk to Salesforce... but these 2 main links will keep the whole solution within SF so no need to need to learn new language, have extra maintenance effort etc)
Sites are VF pages that expose a bit of your company's data without need to log in. You can use them to input data too, just remember that in theory anybody could learn the link and spam you (not too different from web2lead, inbound email handlers etc). You specify security in a way similar to Profiles, the records will have "Created By = {site name} Guest User".
I don't think there's anything out of the box to restrict visibility, they're open to whole world. So if you would want something similar to login IP ranges (so only sales reps from your office's network can enter data) - you might have to write some logic in the controller.

Resources