s4
changeset 446:39823dfee44f
Display warning about quiz mode on the top of articles
author | HIROSE Yuuji <yuuji@gentei.org> |
---|---|
date | Sat, 01 Jul 2017 22:43:22 +0859 |
parents | 12548e1a4ff8 |
children | 4769510d6169 |
files | s4-blog.sh |
diffstat | 1 files changed, 12 insertions(+), 2 deletions(-) [+] |
line diff
1.1 --- a/s4-blog.sh Sat Jul 01 20:17:41 2017 +0859 1.2 +++ b/s4-blog.sh Sat Jul 01 22:43:22 2017 +0859 1.3 @@ -196,9 +196,13 @@ 1.4 <tr class="preface${frozen_class:+ }$frozen_class"> 1.5 <td>`echo "$hexhead"|unhexize|hreflink|minitbl`</td></tr> 1.6 </table> 1.7 - 1.8 - <table class="blog_replies"> 1.9 EOF 1.10 + case "$blogtype" in 1.11 + "クイズ") 1.12 + echo "クイズモードは本人と管理者の書き込みのみが表示されます。" 1.13 + ;; 1.14 + esac | html p 'class="warn"' 1.15 + echo '<table class="blog_replies">' 1.16 if [ x"$blogtype" = x"クイズ" ]; then 1.17 if $isgroup; then 1.18 if ! isgrpowner "$user" "$blogowner"; then 1.19 @@ -209,6 +213,12 @@ 1.20 author='$user') 1.21 EOF 1.22 fi 1.23 + else # if user's blog 1.24 + if [ x"$user" != x"$blogowner" ]; then 1.25 + cat<<-EOF > $quizmodefile 1.26 + AND author IN ('$blogowner', '$user') 1.27 + EOF 1.28 + fi 1.29 fi 1.30 fi 1.31 }