Measurement of the γγ^{*}→η and γγ^{*}→η^{′} transition form factors