Download the PHP package offline/oc-forms-plugin without Composer

On this page you can find all versions of the php package offline/oc-forms-plugin. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package oc-forms-plugin

Forms plugin for October CMS

This plugin provides a simple way to create frontend forms.

Installation

Install the plugin using composer:

Features

Usage

In the backend, go to the Forms menu item and create a new form. You can use the renderForm component to display the form on the frontend. All submissions of the form will be visible in the backend.

Components

renderForm

Use the renderForm component to display a form on the frontend.

AJAX framework dependency

The component requires the AJAX framework to be present on the page. You can set the includeFramework property to true to include the framework automatically.

CSS classes

The default form markup comes with a few CSS classes that you can use to style your form.

You can set the cssPrefix property to change the prefix of the CSS classes.

Form classes

Use the formClasses property to add additional CSS classes to the form element.

Honeypot

The form comes with a honeypot field to prevent spam. You can disable this by setting the honeypot property to false.

File uploads

To enable file uploads, you need to install the Responsiv.Uploader plugin:

After installing the plugin, you can add file upload fields to your form in the backend.

You can use the fileuploadPlaceholderText property to define a custom placeholder text for the upload button.

Important: Responsiv.Uploader depends on jQuery. This means you need to include jQuery on your page. Set the includeJQuery property to true if you want the component to include jQuery automatically.

Captach Support

To enable captcha support, you need to install the Captacha for Laravel composer package:

Once the package is installed, you can enable the captcha field in the form settings.

Field overrides

The renderForm component comes with a powerful way to override the default form field partials.

To do so, create a partial with the proper name in your partials directory.

Overrides are process in the following order:

Name overrides

Override a field by its name. To do so, create a partial with the following name:

Type overrides

Override all fields with a given input type. To do so, create a partial with the following name:

Generic overrides

Take a look at the default partials of the renderForm component. You can override any other partial like the label or the validation message.

OFFLINE.Boxes integration

To make the renderForm component available in Boxes, use the following partial:

form.htm

form.yaml

Helper methods

prependField and appendField

These two methods allow you to add fields to the form before or after the existing fields.

mapFields

Apply a transform to each field in the form. The transform will receive the field as its first argument.

applyPlaceholderToFields

The Form model provides a simple helper method to apply placeholders to all fields that have no placeholder set. The label property of the field will be used as the placeholder.

This is useful for "floating label" form implementations where each field must have a placeholder.

You can pass in an optional transform function.

Events

offline.forms::form.extend

Use this event to apply changes to the form globally (frontend, backend, export).

offline.forms::form.beforeRender

Use this event to change the form before it is rendered.


All versions of oc-forms-plugin with dependencies

PHP Build Version
Package Version
Requires php Version >=8.1
october/rain Version >=3.3
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package offline/oc-forms-plugin contains the following files

Loading the files please wait ....