Hello.
I'm new to PHPRad and have a lot of questions:
1. InternacionalizationPHPRad supports internationalization?
2. API RESTWith PHPRad it's possible to make REST APIs to run alongside the app?
Example: Using PHPRad to make a Admin panel to a mobile app. So the mobile app need an API to connect to admin panel via API RESTFUL.
3. Custom input fields, with mask, like Brazil CPF/CNPJ documents, Phone number, ZIP-CodePHPRad has any way to add masks to form fields? For example mask for CPF, ZIP-Code, Phone Number, etc
4. Custom form data validationIt's possible to make custom validation in forms fields data? For example here on Brazil we need to validate some country documents, like CPF, CNPJ, PIS, etc.
5. Background actionsIt's possible to run some tasks in background?
- Example 1: Events and observers like in laravel framework. When framework watch any data changes like add new item, update, delete... and when occurs, dispatch some predefined tasks with events or observer pattern.
- Example 2: Integrate with redis for queues for backup tasks, like send emails, push notifications, etc
- Example 3: Some scheduled jobs to run like a cronjob.
6. Cache dataPHPRad supports anycache system, like Memcached or redis?
7. Multi tenant apps with different databases per domainPHPRad can work with multiple database connection and multi tenant architecture ?
Example: I intent to make an app, when with some domains in same server. Each domain with it's own database.
8. Auth Providers, facebook, twitter, etcHi, can i use external authentication providers, like facebook, twitter, auth0, firebase auth, etc?
@wemersonrv
1. Internacionalizationyes, it supports it.
2. API RESTYes, it is possible.
3. Custom input fields, with mask, like Brazil CPF/CNPJ documents, Phone number, ZIP-CodeYes, it supports, but require extra knowledge of regexp(regular expression).
4. Custom form data validationyes, it is possible, as phprad provides the option for you to add your custom code like PHP, JS, CSS, and HTML. with JS you can do the validation at the client-side and with PHP you can do it at the server-side.
5. Background actionsYes, it is possible, you can add PHP code to execute before or after the action(view, add, edit and delete) is done.
6. Cache dataPHPRad uses a cache, but I am not sure if it supports the ones you listed above.
7. Multi tenant apps with different databases per domain
I don't understand this question, you will have to elaborate more.8. Auth Providers, facebook, twitter, etcyes, you will have to do that manually after generating your app with phprad.
Tx for your answers... how to do these stufs are in official documentation?
Below I added in red, replicas to your answers.
1. Internacionalization
yes, it supports it.
It's a configurable option on PHPRad or need to make id manually?
2. API REST
Yes, it is possible.
Did you have any example on how to do that?
3. Custom input fields, with mask, like Brazil CPF/CNPJ documents, Phone number, ZIP-Code
Yes, it supports, but require extra knowledge of regexp(regular expression).
Only with regex? I'm asking because have some input masks running in my php(Laravel) and nodejs(AdonisJS) apps and it would be great if i can port them to PHPRad... Some use regex, some do not!
4. Custom form data validation
5. Background actions
Yes, it is possible, you can add PHP code to execute before or after the action(view, add, edit and delete) is done.
Validation in server-side uses the same idea of you answer for 4th question right? I just need to put the validation codes to works before add/update/delete, because PHPRad provides option for add PHP custom code
6. Cache data
PHPRad uses a cache, but I am not sure if it supports the ones you listed above.
What type of cache stuffs are used by PHPRad?
7. Multi tenant apps with different databases per domain
I don't understand this question, you will have to elaborate more.
Imagine an e-commece app, that sells spaces to stores works online without havin their own website, so the app has space to multiple stores on same server. Each store cames with it's own domain (or use a subdomain on my own domain)
My Domain: myphpradstore.com
Store 1: Fictional Store
Subdomain: firststore.myphpradstore.com
Has it's own domain: NOT
Domain: -----
Store 2: Second Fictional Store
Subdomain: secondtstore.myphpradstore.com
Has it's own domain: YES
Domain: secondstore.net
So for each store account created, will create it's own database with all store schema ready to works. And when an user access a specific domain/subdomain for each store, app must use this domain/subdomain to detect the right database and use only it from this point.
First: Check default database for account via domain, and after reach it, get the righ database credentials.
Second: From that point on, uses the right database for the store
@wemersonrv
1. Internacionalizationit is partially a configurable option. the only configuration for it is turning it on and selecting the default language. Then you can now provide your language
.ini file and place it in the language folder, according to phprad specs.
2. API REST
/**
* call model action to retrieve data
* @return json data
*/
function json($action, $arg1 = null, $arg2 = null){
$model = new SharedController;
$args = array($arg1 , $arg2);
$data = call_user_func_array(array($model,$action),$args);
render_json($data);
}
which translate to {root url}/api/json/ e.g http://localhost/api/json/ or http://example.org/api/json
you can read API Docmentation (https://phprad.com/info/api) here.3. Custom input fields, with mask, like Brazil CPF/CNPJ documents, Phone number, ZIP-CodeIf you have a custom input code you can use it with phprad as it allows you to add custom codes for fields and pages.4. Custom form data validation5. Background actionsValidation in server-side uses the same idea of you answer for 4th question right? I just need to put the validation codes to works before add/update/delete, because PHPRad provides option for add PHP custom code
Yes, it does.
6. Cache datait is used to store temp data by the system, not yet available for users to implement.
7. Multi tenant apps with different databases per domainImagine an e-commece app, that sells spaces to stores works online without havin their own website, so the app has space to multiple stores on same server. Each store cames with it's own domain (or use a subdomain on my own domain)
No, it's currently not supported. you will have to manually write the code that will handle that for you.
For more info please visit API Docmentation (https://phprad.com/info/api) and PHPRad Documentation (https://docs.radsystems.io/).
NOTE: PHPRad give a 30 day trial period to test out the product before purchase.
Ok. Tx.. .understand it all now!