_generated\FunctionalTesterActions::sendAjaxPostRequest PHP Method

sendAjaxPostRequest() public method

If your page triggers an ajax request, you can perform it manually. This action sends a POST ajax request with specified params. Additional params can be passed as array. Example: Imagine that by clicking checkbox you trigger ajax request which updates user settings. We emulate that click by running this ajax request manually. php sendAjaxPostRequest('/updateSettings', array('notifications' => true)); // POST $I->sendAjaxGetRequest('/updateSettings', array('notifications' => true)); // GET
See also: Codeception\Lib\InnerBrowser::sendAjaxPostRequest()
public sendAjaxPostRequest ( $uri, $params = null )
$uri
$params
    public function sendAjaxPostRequest($uri, $params = null)
    {
        return $this->getScenario()->runStep(new \Codeception\Step\Action('sendAjaxPostRequest', func_get_args()));
    }
FunctionalTesterActions