Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
I am building a web browser text base RPG game with PHP/Javascript/HTML and CSS.
Each user has some information like his Name, Level, Experience, Gold and more. All the data is saved in the database.
When moving from pages in the game what will be the right method to store the data to be use in all the pages?
I thought about the following options:
PHP SESSION
Cookie
Using GET with the info in the link.
What do you think is the right way to do it?
In aspect of data security, hacking, easy etc.
Currently I am thinking about using PHP SESSION.
Assuming that most of your game logic is executed on the server side, keep the game state in the PHP session. Other than cookies and GET parameters, the session information is stored on server side and for this reason out of reach for manipulations by the user.
In addition to that, save consistent states to the database often to make the game information persistent.
Related
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed last year.
Improve this question
I’m a front end dev on my way to backend and this is a personal project. It was meant to be static so all users see the same information on their page but now I want to be able to change some details based on the clients who signs up. For example. All users were meant to see a $20 bill for a community project but now I want to be able to increase or decrease that amount on different client user page.
Ok peww. I can't explain all of it in one single post but what are talking about is a database and backend code like php or node.js etc....
is a dynamic website rather than static cuz things change
if you want to take time and learn about it i recommend you check youtube 'Dani Krossing is a good php teacher ' or w3schools both have great free courses but if you dont want to spend time learning and you need your project done like today you will need a backend dev to help you learn and do it for you.
I am not advertising myself but if you want i will do it for you for free cuz i like working on random projects.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 1 year ago.
Improve this question
I am creating an application in the MERN technology stack. This project is a gallery of graphics. Some of the graphics are paid and some are free. I am wondering which way to store these paid images will be the most secure ? I put the free graphics in a static uploads folder stored on the server where the application is running. The path to the file is stored in the database.
Easiest way to do it is to have the paid images in some storage that is not publicly accessible. Then you put some form of a api/proxy in front of it that can verify users. If user is verified you show the picture, if not you show something else.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 2 years ago.
Improve this question
I am developing a VR game in unity. I want the players to make decisions in a scene and once they have completed the scene, their decisions would be sent to a website where the data is converted into a graph. The idea is that every time they run and complete a scene, the data is automatically sent as a new session under their unique ID on the website side. This to be able to see if decisions improve with the user over time. Is this possible and if so, where do I need to look to make this happen. I am new to this so thank you in advance!
You should consider reading about REST or SOAP
https://en.wikipedia.org/wiki/Representational_state_transfer
https://www.restapitutorial.com/
https://www.smashingmagazine.com/2018/01/understanding-using-rest-api/
https://smartbear.com/blog/test-and-monitor/soap-vs-rest-whats-the-difference/
https://raygun.com/blog/soap-vs-rest-vs-json/
https://en.wikipedia.org/wiki/SOAP
https://www.w3schools.com/xml/xml_soap.asp
https://searchapparchitecture.techtarget.com/definition/SOAP-Simple-Object-Access-Protocol
Basically you send messages from your app to a web server and viceversa... each message is an order to the server requesting data or the modification of existing data, this also needs security and OAuth to prevent hacking
https://en.wikipedia.org/wiki/OAuth
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 3 years ago.
Improve this question
I think it might be a silly question to ask but trust me I am really confused and stuck. Actually I have an object array where I am showing different events in a calendar. Object array is stored in localstorage. I want to do something like when a user opens a page, I want to store that array on the user's computer. I know I am storing the array in localstorage so if the same user visits the page from another computer, then the array will be erased. I want data that will persist.
Can you please help me?
Because security reasons it's impossible to manipulate files into the file system in a web application, the browser doesn't have this kind of permission.
What you can do is to save your array into a backend, and when the user login, you retrieve this information from your backend.
If I understood you correctly you want the same users to be able to retrieve their data regardless of the machine they access the site from. In order to do so you need to implement some sort of backend that will persist the data. LocalStorage is only local to that computer and won't be accessible from other machines.
AWS Amplify and Firebase are two tools that you might find useful for building backends for persisting user information.
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 8 years ago.
Improve this question
I'm trying to make a web application which uses a mobile phone as a controller (an example of this kind of thing: http://chrome.com/supersyncsports/). It isn't something very complicated, I just need to send text which was entered in the phone to the computer. I don't need any database, I just need to send text from one device to another. Is there a way to do this with AJAX and without PHP?
Thanks,
bhc11
This is possible but it's not simple. You will need to setup a browser-to-browser peer-to-peer connection.
See WebRTC and Wikipedia for a high overview of the technology.
You are going to need some server back-end to process this. You will make your ajax call to the server which reads and determines the location to send the text on to. Since you are using mobile, you will need to either send a push notification to the second user, or you need to have the users polling for new content.