Skip to content

Commit

Permalink
Added composer.json for package management, and also added readme.
Browse files Browse the repository at this point in the history
  • Loading branch information
ThorFjelldalen committed Feb 5, 2019
1 parent 32e1354 commit 535688c
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 0 deletions.
31 changes: 31 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Redirectoperators

Operators for performing URL redirect from within a template. The operators will send an HTTP header 301.

- `redirectabsolute`
- `redirectrelative`

## Installation
Install with Composer:

```
composer require aplia/redirectoperators
```

## Usage
From within a template, write:
```
{redirectrelative( '' )}
```
for instance:
```
{redirectrelative( '/path/to/file.php' )}
```
or
```
{redirectabsolute( '' )}
```
for instance:
```
{redirectabsolute( '' )}
```
15 changes: 15 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"name": "aplia/redirectoperators",
"description": "Operators for performing URL redirect from within a template.",
"keywords": ["ezextension", "redirect", "operator"],
"homepage": "https://github.com/Aplia/redirectoperators",
"type": "ezpublish-legacy-extension",
"license": "GPL-2.0",
"extra": {
"ezpublish-legacy-extension-name": "redirectoperators"
},
"require": {
"php": ">=5.3",
"composer/composer": ">=1.0"
}
}

0 comments on commit 535688c

Please sign in to comment.