### Bug description

For stand alone Quarto documents, you can render them so that they have a title that evaluates an inline R chunk, i.e. this works:

```
---
title: "`r 1+1`"
format: html
---

## Quarto

```

and the title will be 2 (and also the pagetitle will be 2). This is expected behaviour.

However when this is a page in a website it no longer works. For example, if we have the following for our `_quarto.yml` file:

```
project:
  type: website

website:
  title: "Test"
```

Then the above page would have a title printed in the document of `2` but the pagetitle (title that appears in the browser tab) will be `Test - r 1+1` when it should really be `Test - 2`.

If I try to set the pagetitle directly, it still doesn't render properly, for example, the following Quarto document (when it's in the Quarto website) will have a tab name of `r 1+1`.

```
---
pagetitle: "`r 1+1`"
format: html
---

## Quarto

```

It's interesting that title works (in the document) but pagetitle does not seem to be working as expected.

### `quarto check` Output

```bash
[✓] Checking Quarto installation......OK
      Version: 99.9.9
      Path: /Users/garthtarr/git/quarto-cli/package/dist/bin

[✓] Checking basic markdown render....OK

[✓] Checking Python 3 installation....OK
      Version: 3.9.13
      Path: /usr/local/opt/python@3.9/bin/python3.9
      Jupyter: (None)

      Jupyter is not available in this Python installation.
      Install with python3 -m pip install jupyter

[✓] Checking R installation...........OK
      Version: 4.2.1
      Path: /Library/Frameworks/R.framework/Resources
      LibPaths:
        - /Users/garthtarr/Library/R/x86_64/4.2/library
        - /Library/Frameworks/R.framework/Versions/4.2/Resources/library
      rmarkdown: 2.14

[✓] Checking Knitr engine render......OK
```

### `quarto tools check` Output

```bash
[✓] Reading Tool Data
Tool                Status                          Installed     Latest        
tinytex             Not installed                   ----          v2022.07      
chromium            Not installed                   ----          869685    
```

### Checklist

- [X] [formatted your issue](https://yihui.org/issue/#please-format-your-issue-correctly) so it is easier for us to read?
- [X] included a minimal, fully reproducible example in a single .qmd file? Please provide the whole file rather than the snippet you believe is causing the issue.
- [X] documented the quarto version you're running, by pasting the output from running `quarto check` in the "Quarto Check Output" text area?
- [X] documented the version of the quarto tools you're running, by providing the output from running `quarto tools check` in the "Quarto Tools Check Output" text area?
- [X] documented the RStudio IDE version you're running (if applicable), by providing the value displayed in the "About RStudio" main menu dialog?
- [X] documented which operating system you're running? If on Linux, please provide the specific distribution as well.
- [X] upgraded to the latest version, including your versions of R, the RStudio IDE, and relevant R packages?
2022-07-17T14:15:45Z
garthtarr
bug
Future
open
pagetitle not correctly rendering inline chunk evaluation
https://github.com/quarto-dev/quarto-cli/issues/1436