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 7 years ago.
Improve this question
So my question is that for example lets say a
customer receives an email
and then they click on the link which is in the email that they receive
What I want to do is that when they click on the link
this link will take them to a webpage where there will be a form
What the webpage should do is automatically fill in the customers details depending on who the customer was so for example their email address, firstname and lastname.
What is the best way to do this? I was thinking of using PHP but is it possible to do using Javascript or any other languages?
you can pass user email or any other information in url using abc.com?data=email and then you retrieve details from your db and don't forget to escape the get parameter for security reasons
set url data like http://localhost/dispatch.php?link=www.google.com
so here link will be your get parameter check on the link given below
refer this link:GET URL parameter in PHP
Only GET data can be sent from an email.
So you can pass the email : mylandingpage.com?email#email.com
Then you could retrieve the user informations from your database (PHP/MySQL)
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 2 years ago.
Improve this question
Passing user credential from Angular to PHP, they are totally visible in developer tools > Network > Headers > Form data, see below image:
I am using Https everywhere but still my credentials are seen in plain text.
What am I doing wrong?
There are 4 ways to "hide" parameters from appearing in the developers tools:
1st (weakest) encode it
Depending on the algorithm, the data is unreadable afterwards but can easily be decoded to the plaintext
2st Hash the data
The data is unreadable afterwards but you cannot read it yourself too.
3rd Encrypt data
Requires passwords / keys to be sent, leaving you with a dilemma.
4th and probably strongest: Don't send the data at all
Store the secret on the server and link it to the public session id.
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 have a registration form and I would like to check if the email is already in database (PSQL) without submitting the form. Vanilla javascript or jQuery only please. No PHP
Create a blur event on your email input field
https://www.w3schools.com/jquery/event_blur.asp
When it will be called (user clicked out of email input field) make AJAX call to API which will check if email exists and return feedback that you can then present to user via notification. All that can be done without any submitting of form, but you need PHP for API or something similar on the server side.
About AJAX calls:
https://api.jquery.com/jQuery.ajax/
You don't have to submit the form, You can build an API on Your server to tell you if a certain email is already in the system. Then from the front end you request this API to check whether this email is already registered or not.
Obviously on your server once the form is submitted, you need to check again for that, because front-end validations are meant just to make the experience more smooth, and everything important should also be validated on the back end.
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 5 years ago.
Improve this question
I have an application wanted to implement this scenario in Postman - where i have to create and get the Key and pass the same key to another API to delete
Usually you have an endpoint to generate your key, like a login post request which returns your user information and token.
Do you have something like that? Let me show you how this could be done:
After that you get this key/token and use it in the Header tab to send this value in your next request. Something like this:
When you get the token/key in your response body of the first request, set it into an environment variable in Tests section like this.
var body = JSON.parse(responseBody);
postman.setEnvironmentVariable("AccessKey", body[accessKey]);
After that you can use it in your next request URL as
http://your-api-endpoint/{{AccessKey}}
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 8 years ago.
Improve this question
I have a form inside a page A, with 2 fields, user and password, the action of my form is a page B.
I would like to get the form values of the request header using javascript when the page B is loaded. Is this possible? Or something similar?
Thanks.
No. Expect for a few exceptions (useragent) the HTTP request headers are not available in client-side Javascript.
The only way to access the values of the POST:ed form would be to place them in the document when processing the request server side.
This however does not apply to Ajax requests, where the entire request and response are exposed to Javascript.
But, if the form uses the GET method the form values are encoded as query parameters and are available by parsing window.location.
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 9 years ago.
Improve this question
I want to developing a simple yet fail-proof online registration system using JSP and ORACLE 10g. I want online users to give their basic details in step1 , insert the data, redirect to step 2 , allow the user to enter rest of the details and finally submit the form. But in the second step data will be updating against a serial number which is kept as variable via form hidden field. Such applications are not new, and I am asking how to do it. But my concern is the pros and cons of this strategy. I would also welcome opinions if all data be inserted once into the database rather than in steps. Thanks in advance.
You can go with a 2 step approach for user registration.
In the first step, ask the most basic of information like user's name, email, country, etc.
In the second step, you can ask for additional fields like city, address, contact no., twitter handle, etc.
Having a long form broken down into 2 smaller ones has its own advantages. You just need to put up a small registration form that encourages user to sign up.
From the backend perpective, you'll need a service like 'AddUpdateUserDetails'.
This service can always return userId & status.
When you submit the first form to AddUpdateUserDetails with userId as zero/blank. It creates a new user, makes an entry into the database & returns the newly generated userId.
You can then store this into a invisible form field in the secondary form.
When you submit this form, since the userId is already present, the service will only update the user details in the database & return the same userId in response.