Added FAQ

This commit is contained in:
dev-chiefworks
2023-01-10 08:32:43 -05:00
parent f1ab5c8fbe
commit 2a6111ab19
3 changed files with 55 additions and 1 deletions
+1
View File
@@ -43,6 +43,7 @@ $routes->post('/chiefsoft/site/contact', 'Chiefsoft::contact');
$routes->get('/mermsmemr/myfit/country', 'Myfit::country');
$routes->get('/mermsmemr/myfit/blogdata/(:any)', 'Myfit::blogdata/$1');
$routes->get('/mermsmemr/myfit/blogdata', 'Myfit::blogdata'); // when no limit is sent
$routes->get('/mermsmemr/myfit/faq', 'Myfit::faq');
$routes->post('/mermsmemr/myfit/contact', 'Myfit::contact');
$routes->post('/mermsmemr/myfit/pricing', 'Myfit::pricing');
+6 -1
View File
@@ -33,7 +33,7 @@ class Myfit extends BaseController
public function contact()
{
$inx = array(
$inx = array(
'name' => $this->post('name'),
'email' => $this->post('email'),
'country' => $this->post('country'),
@@ -65,4 +65,9 @@ class Myfit extends BaseController
return $this->response->setJson($mCountry->getSiteCountries([]));
}
public function faq(){
$mFaq = new \App\Models\myfitFaqData();
return $this->response->setJson($mFaq->getSiteFaq([]));
}
}
+48
View File
@@ -0,0 +1,48 @@
<?php
namespace App\Models;
use CodeIgniter\Model;
class myfitFaqData extends Model
{
public function __construct()
{
parent::__construct();
}
public function getSiteFaq($in)
{
return array
(
[
'title'=>'This is the title 1',
'text'=>'Random Text Generator is a web application which provides true random text which you can use in your documents or web designs. How does it work? First we took many books available on project Gutenberg and stored their contents in a database.'
],
[
'title'=>'This is the title 2',
'text'=>'Random Text Generator is a web application which provides true random text which you can use in your documents or web designs. How does it work? First we took many books available on project Gutenberg and stored their contents in a database.'
],
[
'title'=>'This is the title 3',
'text'=>'Random Text Generator is a web application which provides true random text which you can use in your documents or web designs. How does it work? First we took many books available on project Gutenberg and stored their contents in a database.'
],
[
'title'=>'This is the title 4',
'text'=>'Random Text Generator is a web application which provides true random text which you can use in your documents or web designs. How does it work? First we took many books available on project Gutenberg and stored their contents in a database.'
],
[
'title'=>'This is the title 5',
'text'=>'Random Text Generator is a web application which provides true random text which you can use in your documents or web designs. How does it work? First we took many books available on project Gutenberg and stored their contents in a database.'
],
[
'title'=>'This is the title 6',
'text'=>'Random Text Generator is a web application which provides true random text which you can use in your documents or web designs. How does it work? First we took many books available on project Gutenberg and stored their contents in a database.'
]
);
}
}