All Questions
Tagged with javascript php
132,253
questions
0
votes
1
answer
14
views
Display an Alert When User Session Expires in Laravel
I am using the Laravel framework and would like to create an alert when the session expires. I tried implementing a JavaScript code that checks if the user is logged in every three seconds as follows:
...
-2
votes
0
answers
26
views
Mapbox display pins from point A to point B [closed]
I have a mapbox with multiple pins.
How can i display only pins from specific A point to specific B point within a radius of 10 km?
Specific points will be typed by the user from two text inputs (A ...
0
votes
0
answers
24
views
Remove backslash from escaped forward slash in a string
I have an array(imageURLS) of string in js. Used 'fetch' to send the array as JSON.stringify(imageURLS) to savedesign.php. The array elements are like ['shop/2.png' , 'shop/3.png']. But each elements ...
0
votes
1
answer
28
views
AlpineJS submit a form without refreshing the page
I am working with Hyva theme with AlpineJs on Magento and using a <form> with the needed inputs to add a product to the shopping cart.
This is part of the form code:
<form method="...
0
votes
0
answers
34
views
Handling Fetch API Errors in JavaScript: Displaying API Response in a Popup
I'm working on a payment integration using the Payway API in a Symfony application with Twig templates. When I submit expired credit card details, the API correctly returns a JSON response indicating ...
-3
votes
0
answers
36
views
Implementation of Loading Bar on Specific Pages of a Website [closed]
Problem Description:
I am trying to add a loading bar to certain pages on my website. I have the pieces of code that I think will do the job, but I'm having trouble integrating them into the original ...
-3
votes
0
answers
50
views
Why is javascript not working on this page? [closed]
This is a PHP project, and I'm trying to use JavaScript to toggle my navigation bar in mobile view. By clicking on the navigation bar(hamburger), it will drop down or close the menu using an event ...
1
vote
1
answer
46
views
PHP Ratchet Websocket clients do not receive messages
I'm using Ratchet and I like its implementation. I'm trying to send a message to all clients connected using chat example class with MessageComponentInterface but after executing php script, nothing ...
0
votes
1
answer
42
views
form serialize is not working after ajax request
I have a modal window that is populated using an AJAX request, and it successfully fills all the fields as expected. The issue is not with the AJAX request itself, as it correctly retrieves the data ...
1
vote
0
answers
32
views
I have a view more button for my container but i cant expand fully my video
i have a view more function and it works well with only paragraph and image.
when i have insert paragraph and video together in one container. the expand cannot cover the video
In result, the video ...
-3
votes
3
answers
75
views
How to decrypt data encrypted using crypto-js in laravel?
I have this bit of code in my js :
export const encrypt = (data, key) => {
const encrypted = CryptoJS.AES.encrypt(
JSON.stringify(data),
key
).toString();
return ...
-2
votes
1
answer
37
views
Typing the text ".htaccess" (no quotes) into a html5 input text or textarea field causes 403 page on form submit [closed]
while testing my html5,js,php project form, i discovered that if i type .htaccess into a text input field or a textarea field that it causes the 403 forbidden page when i submit the form.
I understand ...
-2
votes
0
answers
33
views
SyntaxError: JSON.parse: unexpected non-whitespace character after JSON data at line 1 column 16 of the JSON data [duplicate]
So, I'm new to PHP and SQL. I wanted to select the highscore of the user on the database and overwrite the highscore variable with it, so it doesn't start by 0 everytime I reload. I already managed to ...
1
vote
1
answer
45
views
Php Content-Length header not send
I'm facing an issue since few days with my download file feature.
Content-Length is not set anymore and my XMLHttpRequest progress event function doesn't get lengthComputable correctly. My apache ...
0
votes
0
answers
17
views
Understanding the work together and howto for <button type="submit" between HTML js and php [duplicate]
I searched around for the last few days, but couldn't get the entry point of understanding.
How the work together between HTML, Js and PHP for the submit button is.
Especially for my case, I want a ...