Ajax::req( string $key, mixed $val = null )

Description #

Get and set request.

Parameters #

  • $key
    string (Required) Request key.
  • $val
    mixed (Optional) Request value. Default value: null

Source #

File: classes/ajax.php

	public function req( $key, $val = null ) {
		if ( null === $val && ! isset( $this->req[ $key ] ) ) {
			return;
		}

		if ( null === $val ) {
			return $this->req[ $key ];
		}

		$this->req[ $key ] = $val;
	}

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Add your comment