I'm in the process of setting up a website for my lab (via blogdown). I have also created a new bookdown site that will serve as the project site for a student group. Ideally, I'd like a page in my website to automatically redirect to the bookdown site. For example, I want example-lab.com/group to send people to bookdown.org/my-profile/group. I have a solution, but it's a bit hacky and I'm wondering if there's a better way I'm not finding.
Things I have tried:
- Include bookdown site as external URL in the main menu of my lab website
- Sends me to the bookdown site automatically
- No direct URL to give to group members
Current solution: Create page in my lab blogdown content folder (
group.Rmd) and link to this in the
config.tomlfile. This page then includes an html tag to redirect in the form of:
<meta http-equiv="refresh" content="0; url=https://bookdown.org/my_profile/group/">
- External URL that redirects appropriately (example-lab.com/group sends to bookdown site)
- Kind of laggy, necessarily brings user to the "redirect page" first.
- Redirect publication to external URL: This is not exactly what I want because I am perfectly happy having my bookdown site hosted on bookdown.org, I just want an external link to hand out to people that sends them there.
- Integrating bookdown and blogdown: Also not quite what I want, as I'd like the bookdown site to act like a page of my main website.
Is there a better way to do this?