Get article by name or number



I try to write a simple function or plugin for the oxid shop which allows to get the article data by name or number.
I can’t do that.
Got anybody got a clue?


many people here have a clue


But I can’t find any topic with similar question.


Try the code from here:


class oxGetArticleByNumberPlugin extends oxErpPluginBase
public function invoke($aParams)
$am = $this->getConfig()->getParameter(‘am’);
$art = $this->getConfig()->getParameter(‘oxartnum’);
$aResult = array();

    		$rs = oxDb::getDB()->select( "SELECT OXID FROM ...");	
            if ($rs != false && $rs->count() > 0)
                while (!$rs->EOF) {
                    $rs->fields = array_change_key_case($rs->fields, CASE_LOWER);
                    $aResult[] =  $rs->fields['oxid']; //only the oxid

        $oResult = new oxERPReturn();
        $oResult->aResult = $aResult;
        $oResult->blResult = true;
        return $oResult;

Call to undefined method oxGetArticleByNumberPlugin::getConfig().

but when I try:
$am = $aParams[‘am’];
$art = $aParams[‘oxartnum’];
there is no error but $art param is empty.



> oxRegistry::getConfig()->

Where comes invoke($aParams){…} from?


Function ‘‘getParameter’’ does not exist or is not accessible!

Params are from OXERPCallPlugin function


Oh, it’s very old: Use getRequestParameter instead of



Now is no error, but $art param is empty. :frowning:

really has no function to get articles or orders for another field than OXID?


Have a look: Order_Article.php getMainProduct();


where the file is?
I can’t find it.


Hmm i am too old for this :rofl:: I told the wrong file. application/controllers/admin/Order_Article.php


I found the file on website
But the file is useless for me, because I need use SOAP technology and every function need own call procedure with array type parameters.


I can create function (I show my function above).
Problem is with parameters. They are empty.