From e7747bf975a8523be7756a71d1b5166f5229363b Mon Sep 17 00:00:00 2001 From: vincent-peugnet Date: Tue, 8 Jan 2019 02:17:18 +0100 Subject: mini help --- app/class/art2.php | 18 ++++++++++--- app/view/templates/edithelp.php | 50 ++++++++++++++++++------------------- app/view/templates/editleftbar.php | 10 ++++---- app/view/templates/editrightbar.php | 2 +- assets/css/edit.css | 30 +++++++++++++++++++++- 5 files changed, 73 insertions(+), 37 deletions(-) diff --git a/app/class/art2.php b/app/class/art2.php index b6311c0..474531b 100644 --- a/app/class/art2.php +++ b/app/class/art2.php @@ -24,8 +24,6 @@ class Art2 protected $renderhead; protected $renderbody; protected $secure; - protected $invitepassword; - protected $readpassword; protected $interface; protected $linkfrom; protected $linkto; @@ -37,6 +35,7 @@ class Art2 protected $thumbnail; protected $authors; protected $invites; + protected $readers; protected $affcount; protected $editcount; @@ -98,8 +97,6 @@ class Art2 $this->setrenderhead(''); $this->setrenderbody(''); $this->setsecure(3); - $this->setinvitepassword('invitepassword'); - $this->setinvitepassword('readpassword'); $this->setinterface('main'); $this->setlinkfrom([]); $this->setlinkto([]); @@ -111,6 +108,7 @@ class Art2 $this->setthumbnail(''); $this->setauthors([]); $this->setinvites([]); + $this->setreaders([]); $this->setaffcount(0); $this->seteditcount(0); } @@ -420,6 +418,11 @@ class Art2 return $this->invites; } + public function readers($type = 'array') + { + return $this->invites; + } + public function affcount($type = 'int') { return $this->affcount; @@ -716,6 +719,13 @@ class Art2 } } + public function setreaders($readers) + { + if(is_array($readers)) { + $this->readers = array_values(array_filter($readers)); + } + } + public function setaffcount($affcount) { if (is_int($affcount)) { diff --git a/app/view/templates/edithelp.php b/app/view/templates/edithelp.php index d01f3aa..ff0ade5 100644 --- a/app/view/templates/edithelp.php +++ b/app/view/templates/edithelp.php @@ -1,27 +1,25 @@ -

Help !

-

To save your article, press the HOME, UPDATE, or DISPLAY buttons. You can use the keyboard shortcuts as well.

-
ALT + W : home
-
ALT + X : update
-
ALT + C : display
-

Markdown

-

The html main use Markdown encoding. Actualy, W is using Michel Fortin's Markdown Extra.

-

Links

-
[text](=article_id)
-

where article_id is the article's id you want to point to.

-

Images

-
[altimage](/img_id.extension)
-

Where img_id is the id of your image and its extension.

-

Shortcuts

-
%TITLE%
-

Show the title of your article.

-
%DESCRIPTION%
-

Show the description of your article.

-
%SUMMARY%
-

Generate a summary, the list of all your head titles using #, ##, ###...

-
%%tag_name%%
-

Generate a menu, a list of links to all articles under this tag.

-

vv

-

vv

-

vv

-

\ No newline at end of file +

update shortcut

+ ALT + X +

Synthax

+

+ 📏Markdown encoding +
+ 📐Markdown Extra +

+ + +

More infos

+ + 📕 Manual \ No newline at end of file diff --git a/app/view/templates/editleftbar.php b/app/view/templates/editleftbar.php index 3cc747a..7a2a40b 100644 --- a/app/view/templates/editleftbar.php +++ b/app/view/templates/editleftbar.php @@ -182,12 +182,12 @@ -
+
Help -
- insert('edithelp') ?> - -
+
+ insert('edithelp') ?> +
+
diff --git a/app/view/templates/editrightbar.php b/app/view/templates/editrightbar.php index e42cdf1..a081aac 100644 --- a/app/view/templates/editrightbar.php +++ b/app/view/templates/editrightbar.php @@ -80,7 +80,7 @@