# Selima Website Content Management System # Page.pm: The base web page form checker. # Copyright (c) 2005-2018 imacat. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # Author: imacat # First written: 2005-02-28 package Selima::Checker::Page; use 5.008; use strict; use warnings; use base qw(Selima::Checker); # new: Initialize the checker sub new : method { local ($_, %_); my ($class, $self); ($class, @_) = @_; $_[1] = "pages" if scalar(@_) < 2 || !defined $_[1]; $self = $class->SUPER::new(@_); return $self; } # _check_path: Check the page path # Use the default page path checker # _check_ord: Check the order # Use the default order checker # _check_title: Check the title # Use the default title checker # _check_body: Check the content # Use the default content checker # _check_kw: Check the keywords list # Use the default keywords list checker return 1;