I am using Hybris 6.5. I have published yform on storefront.
Now problem is, When I click on submit(save) button for saving form data I want to fetch customer data which is currentlly logged in System but for getting data I need to fetch cookies first.
To fetch cookies I need http request which comes from submitting save button on published form.
Related
I currently have an issue where i am sending formData from the UI through Ajax to the backend, however, i also created an helper function within the form to allow Image compression whilst it receives the data from the frontend. When the form encounters an exception while compressing, it doesn't return the error to the User until the AJAX request has gotten a response from the server and then i reload the page, I am thinking of using JS to reload the page if the response if false to display the error. Is this a better implementation or how should i go about it?
Hello By sending the value received from the dropdown and sending it to the server via ajax, I filtered my data and sent the result to the template. However, I can see the result through the web developer tools in the response tab, but the result is not visible on the web page. What is the reason?
I have set up a webhook to receive POST requests from the Active Campaign API in order to update my CRM data.
The problem is that Active Campaign doesn't send any token or credential information with the POST request, so I cannot be sure that the request is really coming from them.
Is there a way in Django to check where the request is coming from, in order to prevent anyone from sending POST data to this webhook?
The use case:
User makes order his payment gets accepted and his details are getting post to a django's view. Using these details django's view creates user and everything that is necessary (Username and password is provided by me). Then before returning it sends email to clients email with his data (Username and password for now).
But sometimes I get a gateway timeout error from apache(app is deployed on openshift). Because the user is created I assume that the timeout comes from the email sending part. How can I make sure everything went ok and inform the user? How can I make sure that if the email isn't sent I can resend it? What is the best practice at that?
If you have timeouts with an API or Service, you should fire your POST / sendmail request with AJAX...
Serialize the whole form (like jQuery's serialize())
Send that data via AJAX (with jQuery's ajax())
Inform the User of success or error (alert() or jQuery UI dialog)
You can find a lot of examples on this website.
Another "dirty" approach would be to add the attribute target="_blank" to your form tag what opens your lazy request in a new tab / window.
The question is related to securely transferring data to a webpage. I need to transfer some data to a webpage/website. Assume that for all the mentioned scenarios, I am using HTTPS as the protocol.
Do I need to append data/Parameter to URL. Do I need to encrypt it so that it does not transmit as plain text?
Do I make a POST request to website and it will return me the rendered HTML page?
Security is the major concern for me and I have to use HTTP or restful web services for the purpose.
Query string data will be encrypted, but it will also be visible in the browser address bar and could be logged in browser history. Even if it is a server side request, query string data could be logged in server logs.
Sending the data via POST is preferred - it is not guaranteed to not be logged, but by POSTing the data you are implying that it is used to create a change in state and that it should not be replayed or cached.