consolidated POST string parsing into a single method