Welcome! Log In Create A New Profile

Advanced

Re: Custom configuration

All files from this thread

File Name File Size   Posted by Date  
Capture =?utf-8?Q?d=E2=80=99e=CC=81cran_?=2012-03-31 =?utf-8?Q?a=CC=80_?=01.34.16.png 29.2 KB open | download Adnan RIHAN 03/30/2012 Read message
Adnan RIHAN
March 28, 2012 01:18AM
I've done this:

> root@shadow [/etc/cpnginx/custom]# cat mega-sound.be
> location ~* \.mp3$ {
> types {
> application/octet-stream mp3;
> }
> }



But, after rebuilding vhost and restarted nginx, the mp3 are currently audio/mpeg (referring to firefox).
Is there a way to check if the config is correctly "set" ?

Thanks for your help.
---
Cordialement, Adnan RIHAN.
Président-Fondateur de l'association (de loi 1901) Virtual-Info (http://www.virtual-info.info/), hébergeur Web et Serveurs de Jeux.
Consultant (http://rihan.fr/)-Technicien Supérieur en Informatique de Gestion.
Ambassadeur Qt (http://lyt.me/7E) (Projet Tag-PG (http://rihan.fr/fr/projets/tagpg)).


Le mercredi 28 mars 2012 à 00:15, Cliff Wells a écrit :

> On Tue, 2012-03-27 at 23:46 +0200, Adnan RIHAN wrote:
>
> > It's working well, but his website is now ugly, because the
> > instruction also applies for .css O_O
> >
> > > root@shadow [/etc/cpnginx/custom]# cat domain.com (http://domain.com)
> > > types {
> > > application/octet-stream mp3;
> > > }
> > >
> >
> >
>
>
> When you use the types directive, it *replaces* all the types with
> whatever you specify. You don't define any mimetypes besides mp3, so
> Nginx uses the default (application/octet-stream) for anything it
> doesn't recognize, which now includes css.
>
> Try something like this instead:
>
> location ~* \.mp3$ {
> types { application/octet-stream mp3; }
> }
>
> See also:
> http://wiki.nginx.org/HttpCoreModule#types
>
> As an aside, you could also just edit /etc/nginx/mime.types and change
> the type for mp3 files.
>
> Regards,
> Cliff
>
>
> _______________________________________________
> nginx mailing list
> nginx@nginx.org (mailto:nginx@nginx.org)
> http://mailman.nginx.org/mailman/listinfo/nginx
>
>


_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Custom configuration

Adnan RIHAN March 27, 2012 05:48PM

Re: Custom configuration

Cliff Wells March 27, 2012 06:16PM

Re: Custom configuration

Adnan RIHAN March 28, 2012 01:18AM

Re: Custom configuration

Cliff Wells March 28, 2012 02:04AM

Re: Custom configuration

Adnan RIHAN March 28, 2012 03:50AM

Re: Custom configuration

Adnan RIHAN March 28, 2012 12:12PM

Re: Custom configuration

Cliff Wells March 28, 2012 01:16PM

Re: Custom configuration

locojohn March 28, 2012 02:31PM

Re: Custom configuration

Adnan RIHAN March 28, 2012 06:52PM

Re: Custom configuration

locojohn March 28, 2012 06:57PM

Re: Custom configuration

Adnan RIHAN March 28, 2012 07:08PM

Re: Custom configuration

locojohn March 28, 2012 07:15PM

Re: Custom configuration

Adnan RIHAN March 28, 2012 07:22PM

Re: Custom configuration

Cliff Wells March 28, 2012 08:16PM

Re: Custom configuration

Adnan RIHAN March 28, 2012 08:38PM

Re: Custom configuration

Adnan RIHAN March 30, 2012 01:10AM

Re: Custom configuration

Adnan RIHAN March 30, 2012 03:12AM

Re: Custom configuration

Francis Daly March 30, 2012 04:38AM

Re: Custom configuration

Adnan RIHAN March 30, 2012 11:46AM

Re: Custom configuration

Francis Daly March 30, 2012 02:16PM

Re: Custom configuration Attachments

Adnan RIHAN March 30, 2012 07:38PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 326
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready