Yes, the php.ini and that command would be correct. It sadly depends on how your host has setup your webspace. Some allow php.ini files for such settings even specific for directories, other need it via htaccess (or both). Others may not allow it at all or only via their backend. You host probably has some FAQ about that.