Link Search Menu Expand Document

Docs Command

Table of contents

  1. Complete Catalog of Commands

Puko’s Docs Command is designed to simplify controller creation and speed up backend development. It follows an annotation-like pattern, allowing you to define settings directly above a class or function name in a doc comment.

Example:

/**
 * #Master master-admin.html
 * #Value title Welcome
 * #Date before 31-08-2016 12:00:00
 */
public class registrasi extends View {

Because these commands are placed within standard PHP doc comments, your function logic remains clean. All commands must be prefixed with a hashtag (#) character; otherwise, they will be skipped by the framework.

/**
 * #...
 */

Complete Catalog of Commands

CommandKey IdentifierValueDescription
#ValuenameDidit VellizSends data named name with the specified value directly to the view.
#Templatemastertrue/falseOption to use the master layout.
#Templatehtmltrue/falseOption to output as an HTML file in the browser.
#Templatecachetrue/falseOption to cache HTML output with the PTE cache driver.
#Datebefore/afterd-m-Y H:i:sLimits access based on server time. If the server time is outside the specified range, the function cannot be accessed.
#ClearOutputbinarytrue/falseOption to output results processed through the framework.
#Authbearertrue/falseProtects access to the function. true allows access only to authenticated users.
#Authsessiontrue/falseProtects access to the function. true allows access only to authenticated users.
#Authcookiestrue/falseProtects access to the function. true allows access only to authenticated users.
#Master-master.htmlSpecifies a custom file for the master layout.
#DisplayException-true/falseForwards the process to View or Service middleware when an exception occurs.
#UnderConstruction-true/falseDisplays an “Under Construction” page.
#Permission\pukoframework\auth\Bearer@\plugins\auth\UserAuthpermissions@MANAGERDisplays a “Permission Denied” page if access checks fail.