Commit d9139a78 authored by nirgendswo's avatar nirgendswo

update documentation & readme

parent e4d2a6dd
This diff is collapsed.
......@@ -237,15 +237,14 @@ separated by comma to the APP_RSS_TYPES. RSS feeds will be called by
/rss/{type}
```
## 9. Actions
## 7. Methods
To handle forms you can extend your theme with actions. Create an "Actions" folder in your theme.
Place an action class that is extended by **"App\Http\Actions\PostActionAbstract"**.
To handle forms you can extend your theme with actions. Create an "Methods" folder in your theme.
Place an method class that is extended by **"App\Http\Methods\PostMethodAbstract"**.
To call an action rename the class to the slug which should call the action. For example,
a Slug **"getting-started"** have a an action class **"GettingStartedPostAction"**. The classes need a namespace like, **"Themes\name-of-your-theme\Actions"**.
To call an method rename the class to the slug which should call the method. For example,
a Slug **"getting-started"** have a an action class **"GettingStartedPostMethod"**. The classes need a namespace like, **"Themes\name-of-your-theme\Methods"**.
Don't forget to run **"composer dump"** after you created your action classes.
Once you prepared your action class, every call of a slug containing an action class, calls the internal **process**-function. **"$this->results"** will contain all results from the logic
and it's by default an empty array which is present in any view.
Once you prepared your method class, every call of a slug containing an method class, calls the internal **process**-function. **"$this->results"** will contain all results from the logic and it's by default an empty array which is present in any view.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment