I realize we need forms to submit a POST or perhaps with the help of a button. However, how do we do it using tags? Example code: I’m trying use PHP to read a text file for a number of variables (names of each picture that I’ve saved). From the text file, this PHP will then convert the variables into
Tag: http
Preventing http access in Laravel 8
I have a question about force using HTTPS in laravel, i’ve added a condition inside AppServiceProvider.php, creating a middleware and modifying the .htaccess file. But I can still access the http page. Is there any other way to get laravel to redirect to https instead of http, and how to prevent user to acces the http addres? thank you! my
Is it possible to have web index outside public html?
Say a website has this folder structure And when someone visits the website I want the physical web root to point to /public, like mywebsite.com/dikpic.jpeg (without url rewrites). This can be achieved with the root /myuser/public; command. But I also want to load the index.php file from outside this directory: The problem is with the location try files block that
PHP: How to play random mp4 videos in static url .php
I have a code in PHP language hosted in webcindario.com (free hosting), that shows on click a video randomly. But it works ONLY in VLC Player for Windows. The result is that the Chrome browser or Android donĀ“t show the video: And I have these questions: Is there a way to get the code to work on Android devices and
How do I set up my server to work with PHP
I want to use PHP with a server that i’ve coded my self. (Not Apache etc) I guess I have to send the http request and some additional data from my server to php, but I dont know how to make that connection and how to format that message. I know I can run scripts with php.exe, the problem is
Laravel 8 custom headers run only for home page
I want to add custom headers for every response from my Laravel project. I created a middleware using php artisan make:middleware customheaders then I used this code in customheaders middleware then I added my class to kernel Now if I run my application home page localhost:8000 I can see my custom headers but if I go to any other page
java.net.ConnectException: Failed to connect to /localhost:8080
So, I’m trying to send a POST request from my android phone to my server (laptop) both on the same network. I am getting the error as shown above. I thought this could be something about the firewall …
Is it possible to have session/cookies if the request comes from a different origin?
I am using a payment API. When I click on pay, it opens a new page in the browser, I do the payment on their platform and then, the user is redirected back to my website using a POST request. However, even if he was logged in when he quit my website, when he gets redirected back to my website
How to make URL from Laravel routes
I’ve got Laravel backend and I’m trying to make iOS to it, but there is no documentation. It is my first time with Laravel, so confused with the routes and middlewares. How do I compose URL from code …
PHP get_headers function always HTTP/1.1
The PHP get_headers function returns an array, eventually including a string like HTTP/1.1 200 OK. The URLs I pass to the function are https. For some reason the successful response of get_headers always has HTTP/1.1, but Firefox devtools – network tab says it’s HTTP/2. I call the function like $headers = get_headers(“https://SOME_URL”, 1);. The second parameter just affects the format