I am very new to Facebook applications and have very basic questions.
I use javascript SDK for my application, that loads friends' names and their profile pics.
How can I store this data into a MySQL database?
Since you want to store data in a databes you need to have the server process the information and put it there, thus a server script is required.
Most commonly people use php, so what you need to look at is how to get the data from facebook:
https://developers.facebook.com/docs/reference/php/
and then how to store the date you got from facebook:
http://www.w3schools.com/php/php_mysql_intro.asp
(you can do a google search there are loads of resources)
Keep the facebook guidelines on storing data in mind (not quite sure what they look like anymore)
Happy coding!
Related
I want to host a clean, branded site that allows users to submit data which I will post process on some regular cadence and send custom emails based on data processing results. I can write code and have extensive experience with AWS, but am looking for the fastest solution.
Any experienced web developers have suggestions of which hosting solution to use? Wix, Squarespace, WordPress. I would prefer Squarespace but am not finding clear documentation stating I can create a form which writes to a database (I.e. DynamoDB, Redshift).
Any suggestions would be great! Thanks!
Having a good deal of experience with Squarespace, I will address the question "Is it possible to connect a Squarespace form to a third-party database and, if so, by what means?". While I won't address Wix or Wordpress, hopefully it will provide some objective answers and provide some help to your larger context/question.
Squarespace doesn't support any server-side code; it only supports supports the addition of HTML, CSS and Javascript within Code Injection, Code Blocks, and Developer Mode.
Therefore, your options are:
Send the data client-side with JavaScript. Write your own HTML form and insert it via code block, markdown block, of developer mode. Then write the corresponding JavaScript to send the data, on submit, to your external database. Alternatively, use a Squarespace form block, prevent the default submission from executing and use your own methods instead.
Connect the Squarespace form block to a Google Sheet and the sheet to the external DB via Apps Script. Once connected, use Apps Script (set to trigger when a row is added to the sheet) to obtain the submission from the sheet and send it to your external database (similar to this or this, but you'll be going "the other way", sending data to the external DB from Apps Script).
Use Zapier (or similar service) to bridge the gap, either using Squarespace's built-in integration or setting up Zapier on your own and setting the Zapier email address as the email recipient. You can use Zapier to send form submissions to a new item in DynamoDB, for example. It appears that, at a minimum, you'd have to pay for Zapier as that is a "Premium Integration". For Squarespace, if you were to use their built-in Zapier integration, you'll have to pay for a higher-cost plan (which could be avoided by using the email storage option instead, as mentioned previously).
I think you should choose WordPress, they have a huge documentation, a big community, you can get a ton of support from Wordpress's users when you run into a problem.
Okay so I’m need guidance on where to start.
What I want to do is upon clicking a button in my web app which will be labelled “search” the web app will connect to my realism database and search the data base for the “search criteria” and the once found all matching cases it will create div blocks with the information inside it, in a list view and assign the ID of the div to the UID it gets back from the database.
database:
Users
--> Country
---->State
----->City
------>Post/ZipCode
------->UID
--------> Users informantion
Welcome to StackOverflow!
A great place to get started is the Firebase Realtime Database doocumentation or searching for Firecasts on YouTube (linked below).
As requested, here are some questions to ask yourself to get started and help scope out and define your new Firebase project.
What language are you going to use?
Are you planning on using any frameworks/libraries? e.g. For Javascript, these would include things like jQuery, Polymer, and React
What information are you storing in your database? e.g. user profiles, private user data/settings, public indexes, username lists, etc.
How is your database structured?
What data is being searched? The entire database? Values in a certain location?
What data needs to be displayed in your view?
Is the data accessible for just the current user or is it a public database that anyone can use?
What search criteria will be used? Is it just one filter at a time or many?
The answers to these questions aren't set in stone, but are to help you start thinking about the future of your project. They can be changed at any time as this isn't SQL where everything has to have its own schema.
If you intend on using "advanced searches" where you'll filter by multiple parameters at the same time, consider using Cloud Firestore instead.
I recommend looking at some Firecasts to help guide you through these questions. Here are some links to them:
Firebase YouTube Channel
Video: Getting Started with the Firebase Realtime Database on the Web
Playlist: Firebase on the Web
ok guys, im pretty confused with a class project i've been assigned. I need to make an app that allows the user to take a picture, and then send it to a database. I also need to create a webpage where all the pictures taken with the app will be shown. so, the user takes the picture with the app, and then it sends it to the page, where its displayed. I guess is something like a pseudo-instagram.
the part that really confuses me is the database/server part of the app. i think the app will send the pictures to the database, from where the website will retrieve the latest ones (or some other sorted way). after reading a little about databases i found couchbase and i think thats the way to go.
The part i dont really understand about couchbase is where is the data stored. does couchbase just gives me the database and i have to store all the information (photos) somewhere like a computer that acts as a server or in the cloud; or its stored in some kind of server provided by couchbase?
also, is what i described the way to go in this app? the basic idea is to send information from the app to a database/server and then retrieve that data to the webpage. any advice is truly appreciated. Thank you in advance.
couchbase provides key value store. Data is stored within the couchbase. In your case you need to store the images as value. CouchBase is capable of storing binary data. So, you probably want to convert your images in the binary data and store it.
CouchBase has great API, which you can query to retrive your images.
Not sure if this helps you. good luck with your project.
I am using grails and as my projects requirement I want to store companies database in my own project database.In order to do that I want to use companies database api's, but i don't know much about database api's.Can someone suggest me a way.thanks in advance..
tl;dr: build a REST service to deal with the other data source
I was having similar scenario, so let me tell that if it can help you.
scenario:
In the company I work for, we are building a Grails app for another company (lets call it company_b). So company_b has its own data warehouse and they want to push some of the data to the application I built.
N.B has its own developers.
The solution I came up with:
Looking at their database I designed the appropriate tables, and shared my db schema with the developers on company_b, then I build kind of REST API to expose the tables I designed( the domain objects). So then the developers on company_b developed an API to consume the rest API I built and they are now able to send any record or any operation(delete,update,etc..).
I used json, its structure looks like this.
{
"user": {
"username":"username",
"password":"password"
},
"operation":"INSERT",
"objectName":"Employee",
"objectId":"employeeId",
"object": {
"employeeId":"1212",
"phoneNumber":"0923335227",
"dateOfBirth":"12/7/1982"
}
}
Look at the user object above ^.
The requests that come to consume the REST API are skipped from the spring authentication and I use the user object to manually authenticate each request.
I hope it will give you some insight, but this might not be the right fit for your scenario. Refer the web a lot docs out there.
I am somewhat new to programming, have some experience with VBA, but thats it. I am learning Filemaker at the moment and I am getting along quite nicely. I want to let FM automaticly enter certain appointments and reminders into my google calendar.
Now, I know that the calendar has an API, and I know that that API is the interface with which I can communicate with it. But I am lacking a step in my knowledge ladder, because the documentation is thoroughly confusing. I need to know what to use, in order to tell the calendar what to enter where. Is it like some compound url I construct? How do I login?
These are all questions that pop up. I don't expect you to answer those, but rather if you can point me to the right tutorials I can read to get this knowledge.
I hope I didn't burden you guys too much.
thx in advance
I'm one of the authors of Zulu, a product we built specifically to sync FileMaker to Google Calendar, using a bi-directional sync. You can also turn Zulu into your own CalDAV server if you want to go that route.
Good luck!
Don't take this wrong but you may be biting off too much. I have been programming for 30 years and it took me a couple of days to gather the information needed to interact with the Google APIs (the OAuth2 authentication can be really confusing at first).
My sugestion would be to look at importing calendars into Google Calendars using either CSV (https://support.google.com/calendar/answer/45656) or ICS (https://support.google.com/calendar/answer/45656) format. You should be able to generate those formats with a little bit of Filemaker scripting.
But since you asked:
You need the OAUTH2 offline access, with a refresh token you would
store somewhere.
You will use the refresh token to get an auth token
You will make requests using HTTPS GETS or POSTS (see the Calendar
API explorer), with the auth token in the Authorization header.
Since there is no Google Calendar API for FileMaker :-), you would
have to know some details of the HTTP protocol to send a properly
formatted request, you will be working at a lower level than you
would be if using a Python, Java or .NET library.
You will get back
JSON responses which you will have to parse.
There are a couple of ways you can try to do this quickly:
Use Zapier (http://zpr.io/VhK - affiliate link) to create a webhook, then use a hidden webviewer in FileMaker to create the event. Try this as an example: http://zpr.io/fqg7
Use a plug-in, like this one https://www.feedzon.com/products/fmgcal/. I've never used that particular one before, but it looks fairly straightforward.
If you want to go whole-hog, it is also possible to use scripts in FileMaker to write to the Google Calendar API, but it's a lot more work. The plugin is probably the easiest route to go.
If you don't want to use a plugin, I would recommend starting with a Zapier webhook, as it greatly simplifies the work needed to hook into the Google Calendar API.