apache2

Prevent PHP From Waiting for mail() function

夙愿已清 提交于 2021-02-07 08:36:30
问题 In my web application, when a user makes a change to their account, I call the php mail() function to send that user an email notification. After implementing this, I found that the account change action takes a very large amount of time (>20 seconds) to complete. I suspect that this is because PHP waits for the mail() function to send the email. Is there any way to make this call without waiting and immediately continue to the next line of code? Thanks, Paul 回答1: Create another PHP script

Apache serves old versions of files [closed]

自作多情 提交于 2021-02-07 07:15:16
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 8 years ago . Improve this question I am debugging js code on localhost and I need to prevent the caching of files by the browser. I can't use a timestamp appended to the url because it erases chrome debugger breakpoints. Usually I don't have to refresh the cache, but everyone in a while I do. It is a large problem because I

Apache serves old versions of files [closed]

ぃ、小莉子 提交于 2021-02-07 07:10:39
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 8 years ago . Improve this question I am debugging js code on localhost and I need to prevent the caching of files by the browser. I can't use a timestamp appended to the url because it erases chrome debugger breakpoints. Usually I don't have to refresh the cache, but everyone in a while I do. It is a large problem because I

Apache: how to hide server version and operation system from users?

我们两清 提交于 2021-02-06 08:46:57
问题 I've read on one site that I need to add two lines to httpd.conf file: ServerSignature Off ServerTokens Prod But when I've added them nothing changed. As previously I can see in my browser Apache/2.2.16 (Debian) Maybe that's important: When I opened file (I mean before adding above lines) httpd.conf I saw it's empty. I use VPS. Thanks! 回答1: you didnt give enough information about os/distribution etc but in ubuntu's apache installation apache2.conf looks like this: <cut> Include httpd.conf

Apache: how to hide server version and operation system from users?

≯℡__Kan透↙ 提交于 2021-02-06 08:43:27
问题 I've read on one site that I need to add two lines to httpd.conf file: ServerSignature Off ServerTokens Prod But when I've added them nothing changed. As previously I can see in my browser Apache/2.2.16 (Debian) Maybe that's important: When I opened file (I mean before adding above lines) httpd.conf I saw it's empty. I use VPS. Thanks! 回答1: you didnt give enough information about os/distribution etc but in ubuntu's apache installation apache2.conf looks like this: <cut> Include httpd.conf

Apache: how to hide server version and operation system from users?

天大地大妈咪最大 提交于 2021-02-06 08:43:05
问题 I've read on one site that I need to add two lines to httpd.conf file: ServerSignature Off ServerTokens Prod But when I've added them nothing changed. As previously I can see in my browser Apache/2.2.16 (Debian) Maybe that's important: When I opened file (I mean before adding above lines) httpd.conf I saw it's empty. I use VPS. Thanks! 回答1: you didnt give enough information about os/distribution etc but in ubuntu's apache installation apache2.conf looks like this: <cut> Include httpd.conf

Which one to use : Expire Header, Last Modified Header or ETags

久未见 提交于 2021-02-05 12:43:11
问题 I am running PHP on Apache, and am confused about how to implement server-side caching, in order to make the site load faster. What is the difference between the Expires , Last-Modified and ETag headers, and which one should be used in what situation? 回答1: You can use the Expires header in conjunction but regardless of the other two. It's universally supported by proxies and browser caches. The difference between ETag and Last-Modified stamps is more semantic. ETags are opaque to clients. It

SSL on Apache HTTP Server

醉酒当歌 提交于 2021-02-05 11:30:41
问题 I have 2 crt files for Apache server: 1_root_bundle.crt 2_my_domain_name.com.crt And other bundle: 1_Intermediate.crt 2_my_domain_name.com.crt root.crt I have modified /etc/apache2/sites-available/default-ssl.conf And tried various combinations of above mentioned files but after Apache2 service restart SSL does not work, browser shows "Connection is not secure": SSLEngine on SSLCertificateFile /etc/apache2/ssl/1_Intermediate.crt SSLCertificateKeyFile /etc/apache2/ssl/2_my_domain_name.com.crt

SSL on Apache HTTP Server

半城伤御伤魂 提交于 2021-02-05 11:29:53
问题 I have 2 crt files for Apache server: 1_root_bundle.crt 2_my_domain_name.com.crt And other bundle: 1_Intermediate.crt 2_my_domain_name.com.crt root.crt I have modified /etc/apache2/sites-available/default-ssl.conf And tried various combinations of above mentioned files but after Apache2 service restart SSL does not work, browser shows "Connection is not secure": SSLEngine on SSLCertificateFile /etc/apache2/ssl/1_Intermediate.crt SSLCertificateKeyFile /etc/apache2/ssl/2_my_domain_name.com.crt

Microsoft Azure Web App - How to update apache vhost config?

丶灬走出姿态 提交于 2021-01-29 11:12:21
问题 We have a PHP (Laravel) app hosted in microsoft web app service using debian 9 and apache2. We were able to make the app work by cloning our code in /var/www/html folder. However, since we are using laravel the document root should be in /var/www/html/public instead otherwise many of the features will not work properly. We tried changing the conf file in /etc/apache2/sites-enabled/000-default.conf and reloaded the configuration however, upon checking using apache2ctl -S it's still using the