Questions tagged [apache]

If you have programming questions specifically related to the Apache HTTP Server, feel free to include this tag along with an appropriate programming-language tag. However, please avoid using this tag for inquiries concerning other Apache Foundation products. It's important to note that if you have server configuration questions, they will likely receive better responses on apache instead.

Enable both FTP transfers and php-fpm file uploads

Currently running a CentOS 7 server with Apache 2.4 and enabled PHP-FPM. The Apache server is operating under the apache:apache user configuration, and in the php-fpm pool config file, the user/group and listen user/group parameters are set to apache:apach ...

Requests sent to the Nodejs backend server are not forwarded by Apache

After trying numerous configurations in my vhost.conf file to set up proxying without success, I am seeking help. I have a nodejs backend server running on port 3000, but despite my efforts, I can't seem to forward requests to it properly. When I remove ...

Experiencing a 502 error upon loading a page in a CodeIgniter project hosted on AWS using Bastion as

My Codeigniter project hosted on AWS was functioning properly. In order to enhance security, we implemented a bastion and created a test domain where all existing code was transferred. Although this new test domain appears to be working well, there are cer ...

Is there a way to use htaccess to make a subfolder behave as the main document root?

Here is the site location: http://localhost/~username/website This website has numerous images loaded with an absolute url like /image/image.png. What I'm looking to achieve is that when a request comes in for: http://localhost/~username/website/image/im ...

I am experiencing difficulties with URL rewriting in apache2 and cannot get it

I've been attempting to rewrite the URL for my PHP application, but it just isn't working as expected. Here is a look at my directory structure: /var/www/html/test| |---.htaccess |---index.php Within my .hta ...

Can a secure port be used to run both a web server and socket.io simultaneously?

My Apache webserver is currently serving pages on port 443, while socket.io is responding on port 8888. I am wondering if there is a way to consolidate everything onto the secure port (443) and close all other ports, ensuring that both webpages and socket ...

Would it be beneficial to host a React application on Apache web server?

We understand that the standard method is to use node.js, but our server-side API is built on Apache. Therefore, we prefer to stick with Apache. Can React be run effectively on Apache without needing to install node.js? For setting up .dotenv pack ...

Redis enhances performance in PHP applications by alleviating bottlenecks commonly associated with PHP

I have successfully installed Redis 2.4 on my Ubuntu Desktop 11.10, equipped with 8 cores and 8 GB of RAM. Upon using the redis-benchmark tool, I consistently achieve a performance of 100K SETS and GETS per second with a 4096 byte package. Comparatively, ...

Uploading files to a local server using PHP

Currently, I am utilizing an Apache Server that operates in localhost. However, since I am not well-versed in PHP, I attempted to utilize code from the W3Schools website without success. Below is the HTML code : <!DOCTYPE html> <html> <bod ...

How can JavaScript allow access to files outside of a web server environment? Could .htaccess provide a

Currently, I'm facing a challenge with my local server on Mac 10.8. I am trying to serve files such as videos and images from an external hard drive. The path for the external hard drive is HD: /Volumes/ while the web server's path is /Library/Server/Web/D ...

Attempting to access a shared php/javascript library using mod_rewrite

Let's dive into a fresh perspective on a question I previously raised: I've crafted a mod_rewrite snippet that checks for the existence of JavaScript, CSS, and PHP files on the subdomain they are called from (e.g., subdomain.example.com). If these files d ...

Node.js has the ability to establish internal connections, however it cannot establish connections

I'm having an issue connecting to a JavaScript file on my local server. I'd like to input the external IP address and port in order for it to run externally. This functionality currently works when accessed locally. Below is the code from my serv ...

The attempt to access a URL was unsuccessful due to a failure to open the stream, along

All my requests are modified to point to index.php. Have a look at my .htaccess file provided below. IndexIgnore * <IfModule mod_rewrite.c> #Options +FollowSymLinks RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-d RewriteCond % ...

A Guide to Launching and Hosting a React Application on an Apache Server

After completing my dashboard project using "React js" for Frontend and "Node js" for Backend, I encountered an issue when trying to deploy and host it on an Apache server. Despite running "npm run build" and transferring all the files from the build folde ...

Apache error: mod_access_compat.so file could not be loaded

Every time I attempt to launch a PHP App, I face difficulties setting up Apache 2.4. The error message that pops up reads: httpd: Syntax error on line 72 of C:/Apache24/Apache24/conf/httpd.conf cannot load modules/mod_access_compat.so into server ...

Having trouble loading @font-face fonts

I am experiencing an issue where my downloaded fonts are not showing up in Chrome. I am utilizing scss which gets compiled to css using gulp. If I directly visit http://project-name.localhost/data/fnt/Shermlock.ttf I can successfully download the font. ...

.htaccess rewrite rule not functioning properly in the absence of a trailing slash in

I have the following URLs: www.website.com/index.php?section=index www.website.com/index.php?section=freebies www.website.com/index.php?section=deals www.website.com/index.php?section=articles and the pagination URL parameter for each page is set as "pag ...

Activating the OCS Inventory WebService interface to facilitate the retrieval of asset information

Is there a way to activate the OCS Inventory interface as detailed in the OCS WebServices documentation? Are there any PHP sample codes available for utilizing this Web Service? ...

AJAX calls experience delays when made in rapid succession

When running an app on my laptop that makes 7 AJAX GET requests simultaneously to a single PHP script, everything works perfectly with all requests returning the desired results. However, after moving the script to a Windows Server running Apache and PHP, ...

Using htaccess to restrict access to a specific URL path based on IP Address

(I don't believe the previous link addresses this question; please refer to the comment below) I am currently utilizing a CMS platform that utilizes a database instead of the usual file-directory structure for managing webpages. Due to the absence of indi ...

What is the process for connecting a folder in an express app to my Apache 000-default.conf file on a Ubuntu server?

I already have a domain and I am looking to connect my folder to my Apache configuration file so that I can use certbot. However, I am not sure how to properly set up the connection. This is what I have tried so far: <VirtualHost *:80> # The ...

Occasionally experiencing intermittent 404 status code from admin-ajax.php

I recently launched a new website using Wordpress on a shared hosting platform, but I'm encountering some issues with the theme customization panel. Every time I try to save changes, a window pops up with an error message saying, "Looks like something ...

Guide on forwarding from one HTML page to another in the local disk

Currently, I am working on an employee appraisal application where users can submit appraisals that are stored in the backend. The initial page is a login screen. Once the user successfully logs in, they should be redirected to another page displaying in ...

Securing Public Folders with htaccess配置

While I may not be an expert on .htaccess, I do have remote access to an Apache server that is hosting a running php website. My goal is to create a data folder and allow public access to it. However, when I try to access http://thewebsite.com/data, I am g ...

Error in refreshing the deployment package of angular 4 on an Apache server

At the moment, my Angular application runs on an Apache server at the 'http://localhost' root or index page. However, when I refresh the inner page 'http://localhost/dms-data/summary-of-findings', the browser displays Page Not Found The requested URL /dm ...

Restricting requests to only .json files is possible on an Apache server by using the

I am looking to implement a specific functionality on my live underdeveloped website that is accessible on the internet with remote access. This website produces both php/html content for human visitors and .json output for the API. My current requirement ...

Production environment causing issues with router.url functionality

Encountering an issue in production (server with Apache) with the Router component of Angular version 4.4.6. Below is the code snippet: import { Component, OnInit } from '@angular/core'; import { ActivatedRoute, Params, Router} from '@angular/router'; imp ...

Why am I receiving a 404 error stating that the requested resource was not found after executing `php -S localhost:8888`?

What could be the reason behind receiving a 404 error for the requested resources when running php -S localhost:8888? It was functioning properly earlier, but after deleting a specific project (a Laravel project), this issue began to occur. Any suggestio ...

Is it possible to run Node and Apache on the same port concurrently?

Currently, I have an application running on Node.js and PHP. I am using different ports for each. Is it possible to run both Node and Apache on the same port 8080? Is there any method to run multiple applications on port 8080 simultaneously? Thank you. ...

Discover the steps to redirect a www to a non-www Next.js app on a cPanel hosting account using an Apache

After successfully deploying my next.js app to cpanel as a standalone build, I encountered an issue where everything works properly when accessing my domain without the www prefix like this: example.com. However, if I try to access it with the www prefix l ...

Server experiences latency due to scipy.signal import

I am currently running a Flask server on AWS with Apache, mainly focusing on functional programming and APIs for a mobile application. In order to perform signal processing for the app, I rely heavily on scipy. While I can easily import scipy without any ...

Redirecting htaccess based on folders and file extensions with capitalization variations

Transitioning content from an old Windows site to a new CMS setup presents some challenges, particularly when it comes to preserving certain pdfs/images that are linked from external sources. To maintain these links without redirection, some folders and fi ...

What could be causing the lack of access to the prerender.io service in this particular setup?

I am the owner of a Angular application running on an Apache server. To enable prerendering, I added <meta name="fragment" content="!" /> in the <head> section and set $locationProvider.html5Mode(true); In my Apache server's .htaccess fi ...

Unable to Load Firebird Extension

I have been attempting to utilize the Firebird extension within PHP. I have placed the extension files (php_pdo_firebird.dll, php_interbase.dll) in my ext directory. In my php.ini file, I am including them as follows: ... [PHP_PDO_FIREBIRD] extension=php_ ...

PHP functioning on one server yet malfunctioning on a different server

Currently in the process of transferring a WordPress website from JustHost server to VPS (Debian 8). The installation of WordPress was successful, and all pages are functioning correctly, except for the homepage, which appears blank. This is the only page ...

Rendertron always renders base routes as empty

I'm running into an issue while trying to use rendertron via an Apache proxy - all the base routes are showing up as "null." Could this be due to a configuration error on my part? Any help would be greatly appreciated. The Rendertron service is currently ...

Is your Node.js application ready for deployment in a production environment?

I am looking to set up and launch my node.js and express application on a production server like Apache, Wamp, or Tomcat. My node.js app mainly consists of backend components such as API endpoints and database connectivity. This backend will handle all A ...

The URL for the Javascript chunk includes colons at https://example.com/js/chunk-vendors.b3792e11.js:18:16400

I recently completed a Vue application and used npm run build to generate the files. Upon uploading the dist folder to my Apache server, I encountered an issue where Apache was unable to locate the file when trying to access a specific part of the app (:18 ...

Eliminate the presence of index.php in your CodeIgniter URLs

I've been attempting to access CodeIgniter URLs without using 'index.php'. Below are the steps I have taken: Verified mod_rewrite is enabled - I tested a rule to redirect all requests to Google, which was successful. I also confirmed tha ...

URL rewriting does not retrieve information from the $_GET superglobal

I have defined certain rules for URL rewriting on my website. Currently, I am working on localhost I have configured this in the .htaccess file php_flag output_buffering on Options +FollowSymlinks RewriteEngine On RewriteRule ^p/([^/]*)\.html$ /?p= ...

How can I enable browser caching for test.json, which is generated by json.php using Apache's rewrite feature?

How can I configure browser caching for test.json, which is generated by json.php? Unfortunately, the response headers for test.json are set as if it were a .php file and not a .json file. How do I correctly apply .htaccess rules so that the generated tes ...

Page not found: The requested file does not exist

Apache web server is claiming that the page we are attempting to reach is missing, even though we are certain it is not. It gets even more puzzling as only directory names seem to be causing issues. It's not a file permissions problem be ...

PHP error: Unable to grant access to the user 'jobportal' on localhost with the provided password

When attempting to access the index page of my website (index.php) through the link localhost:80/web/index.php, I encountered a blank page in Chrome displaying the following error message: Warning: Declaration of SugarDateTime::setTime($hour, $minute, $ ...

Secretly stashed away on internet browsers but easily found on Windows Explorer

I seem to be facing a problem that is reminiscent of this After cloning a Laravel project from Github and setting it up on my local Wamp server with a designated hostname, I encountered a "500 internal server error" when trying to access the project throu ...

Experiencing connectivity issues with Apache Server on XAMPP

Just recently, I decided to set up the XAMPP Control Panel for my PHP project. However, I encountered an issue where it is not allowing me to connect to the Apache server. The XAMPP Control Panel keeps displaying an error message whenever I try to establis ...

Can a PHP script be run and its result included in another script before being displayed?

I have a PHP script located at http://example.com/myapp/myscript.php that is currently running on an Apache server. When this URL is accessed from a mobile app, the script performs its logic and sets HTTP headers and body with data in JSON format, which th ...

Using Apache to rewrite a subdomain for PHP

My website is currently set up as follows: The domain www.mysite.com directs to the static website at /var/www/sites/mysite/www, while manager.mysite.com redirects to the PHP framework located at /var/www/sites/mysite/admin/siteroot. This configuration w ...

Unable to connect to phpMyAdmin through the command line

After successfully installing MAMP, I am able to access it from localhost:8888 and phpmyadmin from localhost:8888/MAMP. Currently, I am working on a project using zend framework 2 and running the basic Album module on my local host. However, I have encount ...

What is causing the echo PHP output to be missing the space after the first word when viewed in MS Edge?

Whenever I execute the php script, the space gets automatically removed from the string that is printed using echo. I attempted to use echo in another place and noticed that the space remains intact. It's just in this specific case that the space disappea ...

What could be the reason behind the absence of $_SERVER['ORIG_PATH_INFO']?

MAIN_ROOT/files/test.php includes the script below and is accessed through https://example.com/updates/test.php/some/stuff?foo=bar <?php echo('PATH_INFO: '.($_SERVER['PATH_INFO']??'UNSET').PHP_EOL); echo('ORIG_PATH_INFO: '.($_SERVER['ORIG_PATH_INF ...

Setting up the CodeIgniter .htaccess file on your Apache Server

After setting up Apache 2.2, Php 5.4.5 and Mysql 5.5.27 on my Windows 7 Operating System, I located my localhost at G:/local_server. Following that, I downloaded CodeIgniter_2.1.3, extracted it into the local_server, renamed it to CodeIgniter, and created ...

Setting up reverse proxy rules for GitLab on a Node.js Express server can be achieved using the following

I am currently in the process of developing a Node.js application to serve a private GitLab server. Initially, I had it set up with Apache, but now I am looking to switch over to using my Node.js application instead. Most of the functionality is there. Th ...

The SSL Client Certificate is Not Being Requested by Apache

Hello there! I must admit that configuring SSL is a new task for me. In the past, I've always relied on my IT department to handle it for me. So, please bear with me if I need some clarification on your answers. ...

Two applications installed on a single server, each running on its own port. The first application is unable to communicate with the second

I have two applications running on the same VPS (Ubuntu) and domain. The first is a Node.js app running on port 80, while the second is a Python (Flask) app running under Apache on port 3000. The Python app has a simple API with one endpoint /test. When I ...

Is it possible to obtain the Apache server status (mod_status) output in JSON or XML format?

Exploring Apache's "mod_status" Feature: One of the functionalities provided by Apache is the "mod_status", which allows users to monitor the current status of their server. When accessed, it presents a wealth of information similar to the sample page ava ...

Error: Page cannot be located 404 (GET /) • Directory not found: C:/wamp/www/fatfree-master/index.php:111 Base->execute()

Recently, I decided to give the php fat free framework (also known as F3) a try in order to quickly construct a web application. Despite reading through the documentation and thinking it would be straightforward, I have been encountering a single issue th ...

The PHP version displayed on phpinfo() is behind the version shown on the terminal

Recently, I encountered a versioning issue with my PHP on macOS. Surprisingly, the terminal displays PHP 7.4.2 as expected; however, when I pulled up phpinfo() on my project, it showed PHP 7.1.23. All the resources and posts I came across discussed discre ...

Refreshing product names in URLs

I am looking to rewrite a rule for my products. My goal is to utilize the id and name in the URL, separated by a dash like this: 123-name translates to product id = 123 and name = name This way, in my PHP code, I can fetch the $_GET[id] and then query ...

Issue in PHP Wordpress when trying to access an index that is

I seem to be facing a common issue that others have experienced, but I can't quite figure out where the problem lies. (I've double-checked the isset() function in my code and it appears fine, yet it's still not allowing an email message to be sent) I crea ...

Troubleshooting: Issue with Docker PHP 5.6.23 setup - mysqli_connect function not working even after extension addition

Despite serving files in the docker environment, I am facing an issue with establishing a database connection using mysqli_connect($host, $username, $password, $dbName). It keeps throwing an error stating that mysqli_connect is not recognized as a function ...

Resolve CORS issue by implementing WPGraphQL plugin as the back end and integrating NextJS as the front end

Recently, I encountered a challenging error after transferring a website from Google Cloud. Initially running on Nginx, the site is now hosted on an Apache server. The website comprises two parts: front-end (hosted on Vercel NextJS) and a backend WordPres ...

Ensuring a continuous operation of Node.js on AWS EC2 even after exiting the console

Currently, I am using aws ec2 for hosting a web server with node.js and apache. I find it inconvenient that I have to log in to ec2 through the terminal each time to run npm start. I want to set it up so that it continues running even when I'm not o ...

Perform a secondary AJAX request to the database while the initial request is still processing

When I have two AJAX calls, the first one starts a long-running script and the second one polls a database table for a percentage field. Strangely, when making the second AJAX call, the database query will always return false until after the first one is c ...

Subdirectory hosting for Apache PHP and Rails

Currently, I am facing an issue with setting up rails in a subdirectory while keeping Phusion Passenger PHP in the root directory. Although I have managed to get it to work, the static files for Rails are returning a 404 error. Below is the Apache configur ...

Setting up a Node application on a server with the help of Apache, npm, and pm

            I recently deployed a Node.js application (myapp.js) on a server with a specific IP address. The installation and startup process using npm went smoothly this time around, unlike past experiences with Apache which were much more complic ...

Steps to activate CORS using .htaccess in a ZURB Foundation Project

Embarking on my first website development project from scratch, I took on the task of handling front-end, back-end, and database integration. Utilizing the ZURB Foundation Framework (ZURB Template), I structured my project to be modular with Webpack4, Babe ...

Defend your system from potential PHP file intrusion

Our server recently experienced a cyber attack, as evidenced by the following entries in the system logs: [Mon Feb 18 09:18:43 2019] [IP_ADDRESS] script '/var/www/ynm.php' not found or unable to stat [Mon Feb 18 09:18:43 2019] [IP_ADDRESS] script '/var/ww ...

Authentication with NTLM in PHP with Apache

Is there a way to login to my system using the NTLM protocol that is compatible with multiple platforms? I have discovered the mod_auth_sspi module for Apache, but I require a solution that works for both Windows and Linux environments (both of which have ...

PHP is encountering difficulties when attempting to fetch extensive requests

I have developed a PHP service that retrieves JSON data from a table consisting of 2100 rows. My development setup includes: Xampp with Apache and MySQL Windows 10 PHP-7.0.8 I am using PDO in PHP to execute the query. The service used to function flawl ...

Adjusting the document root in an Apache site's directory

I have been working on my portfolio website and I want to showcase some past projects. There is one particular website that I developed in the past which is no longer live, but I have an archived version of it. I would like to be able to view this old site ...

Web user unable to execute binary file

I have encountered an issue with a php script that generates a shell script file which is executed as the user www-data. Most of the commands in the script run without any problems, but the last command involving a binary file fails to execute when the scr ...

Changes made to the .htaccess file are preventing the $_GET variable from being set

For a while now, I've been utilizing '.htaccess' to modify the appearance of page URLs. Instead of: details.php?video=how+to+do+this&user=xxx I prefer it to look more like this: /details/xxx/how+to+do+this Although it's function ...

Apache httpd exceeds memory usage resulting in server crashing

My server is running on an Intel(R) Xeon(R) CPU X3440 with 8GB of RAM. Currently, Apache seems to be consuming all the available RAM, causing the server to become unresponsive. This is my current Apache Configuration: <IfModule prefork.c> StartSe ...

The error message "PDOException: driver not found" indicates that the driver needed

Whenever I try to connect to a MySQL database on localhost using PHP, I encounter a PDOException stating that the driver could not be found. $this->conn = new PDO("mysql:host=" . $this->host . ";dbname=" . $this->db_name, $this->username, $thi ...

The Speed of Apache Requests

After setting up my server with centos6, I decided to use a combination of nginx as the frontend and apache as the backend, along with APC for optimization purposes. To benchmark the performance, I used the following command: ab -n 1000 -c 100 http://doma ...