Download the PHP
package bvfbarten/f3-model without Composer
On this page you can find all versions of the php package
bvfbarten/f3-model. It is possible to download/install
these versions without Composer. Possible dependencies are resolved
automatically.
Vendor bvfbarten Package f3-model Short Description Simple model class for f3 framework License
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 f3-model
F3 Model
F3 Model strives to create lazy loading relations the fatfree way. It comes with four functions to add to the mapper object.
class UserGroup extends F3Model {
public $_db = 'db';
public $_table = 'user_group';
public function relations() {
return [
'User' => [
"User",
['id = ?', $this->user_id]
],
'Group' => [
"Group",
['id = ?', $this->group_id]
],
'NotFamily' => [
"Group",
['id != ? and name = ?', 3, 'family']
],
];
}
}
$userGroup = new UserGroup;
$user = $userGroup->loadRelation('User');
function findRelation($key, $where, $args) { }
returns array of NotFamily relationship
$where, gives ability to add additional where parameters to related table in same fashion as f3
$args, allows overriding $args given in initial relations function
function loadRelation($key, $where, $args) { }
returns a single object of NotFamily
function countRelation($key, $where, $args) { }
returns a count of NotFamily
function combineFilter($filter, $filter1) { }
returns an f3 filter combining $filter and $filter1
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 bvfbarten/f3-model contains the following files
Loading the files please wait ....
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.