Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Setup plates.thephpleague.com #139

Open
3 tasks
reinink opened this issue Dec 28, 2016 · 2 comments
Open
3 tasks

Setup plates.thephpleague.com #139

reinink opened this issue Dec 28, 2016 · 2 comments

Comments

@reinink
Copy link
Contributor

reinink commented Dec 28, 2016

Right now the only League project using a custom domain is this one (platesphp.com). There really isn't any reason for this.

  • Add the CNAME plates.thephpleague.com DNS record
  • Update /docs/CNAME
  • Figure out 301 redirects for all the old addresses (this is the hard part)
@odahcam
Copy link
Contributor

odahcam commented Aug 16, 2017

How you pretend to redirect all the old addresses?

@carbontwelve
Copy link
Contributor

How you pretend to redirect all the old addresses?

Why would you need to pretend to redirect? I'd have the old domain DNS point to a server running either apache or nginx and have the virtual host config do a domain to domain 301 redirect.

Apache

RewriteEngine on
RewriteCond %{HTTP_HOST} ^platesphp.com [NC,OR]
RewriteCond %{HTTP_HOST} ^www.platesphp.com [NC]
RewriteRule ^(.*)$ http://plates.thephpleague.com/$1 [L,R=301,NC]

Nginx <0.9.1

server {
  server_name .platesphp.com;
  rewrite ^ http://plates.thephpleague.com$request_uri? permanent;
}

Nginx >=0.9.1

server {
  server_name .platesphp.com;
  return 301 http://plates.thephpleague.com$request_uri;
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants