Added false is_content flags to several blocks so that the 404 extension can work properly

This commit is contained in:
Matthew Barbour 2020-06-24 09:40:25 -05:00 committed by Shish
parent 9e1aabe17f
commit bd9808081e
5 changed files with 17 additions and 7 deletions

View File

@ -4,7 +4,9 @@ class UploadTheme extends Themelet
{ {
public function display_block(Page $page) public function display_block(Page $page)
{ {
$page->add_block(new Block("Upload", $this->build_upload_block(), "left", 20)); $b = new Block("Upload", $this->build_upload_block(), "left", 20);
$b->is_content = false;
$page->add_block($b);
} }
public function display_full(Page $page) public function display_full(Page $page)

View File

@ -49,7 +49,9 @@ class UserPageTheme extends Themelet
$html->appendChild(BR()); $html->appendChild(BR());
$html->appendChild(A(["href"=>$part["link"]], $part["name"])); $html->appendChild(A(["href"=>$part["link"]], $part["name"]));
} }
$page->add_block(new Block("User Links", (string)$html, "left", 90)); $b = new Block("User Links", (string)$html, "left", 90);
$b->is_content = false;
$page->add_block($b);
} }
public function display_signup_page(Page $page) public function display_signup_page(Page $page)

View File

@ -48,7 +48,9 @@ class CustomUserPageTheme extends UserPageTheme
} }
$html .= "<li><a href='{$part["link"]}'>{$part["name"]}</a>"; $html .= "<li><a href='{$part["link"]}'>{$part["name"]}</a>";
} }
$page->add_block(new Block("User Links", $html, "user", 90)); $b = new Block("User Links", $html, "user", 90);
$b->is_content = false;
$page->add_block($b);
} }
public function display_signup_page(Page $page) public function display_signup_page(Page $page)
@ -59,7 +61,7 @@ class CustomUserPageTheme extends UserPageTheme
$tfe = new TextFormattingEvent($tac); $tfe = new TextFormattingEvent($tac);
send_event($tfe); send_event($tfe);
$tac = $tfe->formatted; $tac = $tfe->formatted;
$reca = "<tr><td colspan='2'>".captcha_get_html()."</td></tr>"; $reca = "<tr><td colspan='2'>".captcha_get_html()."</td></tr>";
if (empty($tac)) { if (empty($tac)) {

View File

@ -48,7 +48,9 @@ class CustomUserPageTheme extends UserPageTheme
} }
$html .= "<li><a href='{$part["link"]}'>{$part["name"]}</a>"; $html .= "<li><a href='{$part["link"]}'>{$part["name"]}</a>";
} }
$page->add_block(new Block("User Links", $html, "user", 90)); $b = new Block("User Links", $html, "user", 90);
$b->is_content = false;
$page->add_block($b);
} }
public function display_signup_page(Page $page) public function display_signup_page(Page $page)
@ -59,7 +61,7 @@ class CustomUserPageTheme extends UserPageTheme
$tfe = new TextFormattingEvent($tac); $tfe = new TextFormattingEvent($tac);
send_event($tfe); send_event($tfe);
$tac = $tfe->formatted; $tac = $tfe->formatted;
$reca = "<tr><td colspan='2'>".captcha_get_html()."</td></tr>"; $reca = "<tr><td colspan='2'>".captcha_get_html()."</td></tr>";
if (empty($tac)) { if (empty($tac)) {

View File

@ -48,7 +48,9 @@ class CustomUserPageTheme extends UserPageTheme
} }
$html .= "<a href='{$part["link"]}' class='tab'>{$part["name"]}</a>"; $html .= "<a href='{$part["link"]}' class='tab'>{$part["name"]}</a>";
} }
$page->add_block(new Block("User Links", $html, "user", 90)); $b = new Block("User Links", $html, "user", 90);
$b->is_content = false;
$page->add_block($b);
} }
public function display_signup_page(Page $page) public function display_signup_page(Page $page)