Post by mood2020 » Mon Oct 22, 2018 9:19 pm

I start to create my custom module I have this error when click edit my module
"
Warning: Invalid argument supplied for foreach() in C:\wamp64\www\perfor-opencart\system\engine\loader.php on line 83
"
my controller is :

Code: Select all

class ControllerExtensionModuleFetchddatasmarterp extends Controller {

private $error = array(); // This is used to set the errors, if any.

public function index()
{ // Default function
$this->language->load('module/fetchdatasmarterp'); // Loading the language file of helloworld

//$this->document->setTitle($this->language->get('heading_title')); // Set the title of the page to the heading title in the Language file i.e., Hello World

$this->load->model('setting/setting'); // Load the Setting Model (All of the OpenCart Module & General Settings are saved using this Model )

$this->load->model('module/fetchdatasmarterp');

}
}
my view is empty also my model is empty language have some vars

plz help me I need to create an extension that will get API JSON file that contains products info then insert them to DB just these small process and show my extension page in the dashboard menu so I can open it later easily from the dashboard

Newbie

Posts

Joined
Sat Oct 13, 2018 7:17 pm

Post by OSWorX » Tue Oct 23, 2018 3:22 am

Please use next time code when pubsishing code (gragments).

Then, which OpenCart Version should be the target?
And if you really want help, you should post more - the code fragment cannot be all.

Beside this, you are asking for more than only a 'simpl' module, e.g. Admin Menu entry.
Maybe download one of the countless free extensions and check that code - if you do not explore the existing OpenCart code you already have.

Full Stack Web Developer :: Dedicated OpenCart Development & Support DACH Region
Contact for Custom Work / Fast Support.


User avatar
Guru Member

Posts

Joined
Mon Jan 11, 2010 10:52 pm
Location - Austria
Who is online

Users browsing this forum: No registered users and 65 guests