server-configuration

Make XAMPP/Apache serve file outside of htdocs

Is it possible to configure xampp to serve up a file outside of the htdocs directory? For instance, say I have a file: C:\projects\transitCalculator\trunk\TransitCalculator.php and my xampp files are normally served out of: C:\xampp\htdocs\ (because that's how it's configured by default) Is there some way to make Apache recognize an...

Visual Web Developer (Express): Setting Document Root for Dev Environment

Hey-- I'm developing a site in Visual Web Dev Express, and when I run/debug, I'd like to be able to set my application's document root so that I can use safer paths, like "/css/style.css' instead of "css/style.css". How would I accomplish this? ...

How do I serve a script with apache instead of running it?

I'm trying to host a python script using an apache web server, but the server tries to run the script instead of just offering it for download. I do not have direct access to server, and adding the line AddType text/plain .py to .htaccess in the root folder does not appear to work, though I could be doing something wrong. How do I g...

Slicehost installation profile

I'm no UNIX Guru, but I've had to set up a handful of slices for various web projects. I've used the articles on there to set up users, a basic firewall, nginx or apache, and other bits and pieces of a basic web server. I foresee more slice administration in my future. Is there a more efficient way to set up users, permissions, and sof...

How to configure server for small hosting company for django-powered flash sites?

I'm looking at setting up a small company that hosts flash-based websites for artist portfolios. The customer control panel would be django-powered, and would provide the interface for uploading their images, managing galleries, selling prints, etc. Seeing as the majority of traffic to the hosted sites would end up at their top level d...

What needs to go in order to fully remove a MAMP install from OSX?

For reasons that we won't discuss, I have determined that MAMP is a pile of crap that haunts my system, and unless I remove it fully, I will live in shame. I've done the obvious thing and removed the MAMP directory from my Applications folder, however, I don't like wandering files, and I have an itching feeling that MAMP put some .sock ...

RoR Server Construction and Capistrano Support

I have been creating a website with Ruby on Rails, and will be hosting it through a friend. He has the space and capacity to host the server, and I have a system to devote to being a dedicated server. And this is my first attempt at a Rails website, plus self-hosting with a friend. I will be formatting and preparing the server today a...

SQL Server 2005 DB Mirroring Error

I'm getting the following error when trying to setup SQL Server 2005 DB Mirroring on my servers. I am running two Win2K3 servers with SQL 2005 on each with one of those running alongside a SQL 2000 Version. After restoring the database with NORecovery and configuring the endpoints, I run into the following error when I try to start the...

How to add some HTML to every HTML document served?

I need to add a script before the </body> tag, so instead of modifying all the pages, I was wondering if I could configure the server to add some HTML before that tag for every HTML document being served? ...

SQL Server 2005 & the Windows Event Log

I'm running a SQL Server 2005 Standard. I got several alerts I need to react on. So I created these alerts, but they never appear so that the jobs depending on them are never run. I found out that for alerts it is necessary that the SQL Server writes to the Windows Event Log, but this is not happening at all. Every source tells me that ...

Managing site deployments between demo/staging/live on production servers

The way we currently manage site roll outs to the server and then switching sites between demo/acc/live "mode" is a bit hap-hazard and i'm looking to improve the whole process. I've been reviewing automated deployment tools, but also the way the server is structured. I'll save the automated deployment questions for another post, here i'...

How to fetch a resource through a php script?

I am trying to do the following in my web application: <img src="static.example.com/image01.jpg?width=300&height=300" /> Is it possible to have my server (I use Apache in a shared hosting environment) run a PHP script when accessing a .jpg (or any filetype that I chose) instead of just serving the file? I know that the PHP script ha...

More remote debugging sessions for multiple instances of JBoss

Hello, I'm running more instances of JBoss on one machine. This instances is created with own address binding parameter -b and runs on different configurations by -c parameter. The machine is Linux one and there are more virtual interfaces created (by ifconfig eth0:1 192.168.0.101 netmask 255.255.255.0 up). My idea is that more peop...

optimum setup for php server

We have a number of servers running various different LAMP setups. One thing that seems to be different depending on who set the server up is the way PHP is configured. Some are set up to use the Apache DSO module, others are setup to use CGI. Some have suEXEC turned on, other servers its turned off. We are always trying to tweak our app...

A universal mod-rewrite htaccess file for my script

I'm writing a script that (I hope) will be widely distributed and I want make sure that it will work on as many servers as possible out of the box. This script will require an .htaccess file but I've learned some htaccess files are not very portable. The htaccess needs to do a simple redirect, like so: http://example.com/dir/string R...

Global variables in css style sheets.

I hava an absolute url in my stylesheet. http://localhost/images/myimage.jpg. I also have a config class with the following constant const SITE_ROOT = 'http://localhost/images' On php pages i write config::SITE_ROOT . "/myimage.jpg" so when i move the site to the production server i can change the site root in one central location....

Which PHP config is running when I forward from one directory to another?

I am testing an idea based on my last question, but I've run into a very interesting problem... My home directory is on one path of the server (where all home directories reside) and for reasons I can only guess at, the PHP config for that directory does not have IMAP turned on. However, my project directory, which exists on a test mir...

Multiple PHP versions on the same box

Is it possible to have multiple versions of PHP running on the same box ( like rails ) . Here is my problem , I need to start development on a new project and was planning to use PHP 5.3 for it so that I can use the latest Zend framework and active record with it . However the machine where I need to host my application has PHP 4.4 and ...

how can i send message?

I have programmed for mailing in php.but how can i send mail through local server? ...

.htaccess mod_rewrite has different result on different sites

Hi, I am using mod_rewrite to create SEO URLs. Basically the thing works in the following way: all requests are caught by .htaccess and redirected to a php script (let's say transform.php). transform.php parses SEO URL and transforms it into a normal URL, then includes index.php, then catches application's (index.php's) output and uses ...