Minor fixes to navigator <a> tags

This commit is contained in:
Rosia E Evans 2023-09-28 13:33:34 +01:00
parent 202801841d
commit 33cc777a65
3 changed files with 9 additions and 3 deletions

View file

@ -30,8 +30,7 @@ Page::Page(std::string sourceFileUrl, std::string outFolderUrl)
calculatePageFlags();
calculatePageTitle();
std::string formattedTitle = findAndReplace(title, " ", "_");
this->outFileUrl = outFolderUrl + "/" + formattedTitle + ".html";
this->outFileUrl = outFolderUrl + getRelativeUrl();
}
std::string Page::getSourceFileContents()
@ -44,6 +43,12 @@ std::string Page::getOutFileUrl()
return outFileUrl;
}
std::string Page::getRelativeUrl()
{
std::string formattedTitle = findAndReplace(title, " ", "_");
return "/" + formattedTitle + ".html";
}
FileFlags Page::getPageFlags()
{
return flags;