Infusionsoft_WebFormService::getHostedURL PHP Метод

getHostedURL() публичный статический Метод

Instead of having to use the HTML code, you can get the URL to the Infusionsoft hosted version of the web form.
Автор: Jacob Allred ([email protected])
public static getHostedURL ( integer $webFormId, Infusionsoft_App $app = null ) : string
$webFormId integer The ID from Infusionsoft_WebFormService::getMap.
$app Infusionsoft_App
Результат string URL of hosted web form
    public static function getHostedURL($webFormId, Infusionsoft_App $app = null)
    {
        $app = parent::getObjectOrDefaultAppIfNull($app);
        /*
         * The API doesn't provide a method of getting the hosted URL.
         * Instead, we are going to get the HTML, find the form GUID, and create
         * the hosted URL on our own.
         */
        // Get the HTML
        $html = Infusionsoft_WebFormService::getHTML($webFormId, $app);
        // Create our search string
        return self::getHostedUrlFromHtml($html, $app);
    }