Method: Pdfcrowd::HtmlToImageClient#convertUrl

Defined in:
lib/pdfcrowd.rb

#convertUrl(url) ⇒ Object



2109
2110
2111
2112
2113
2114
2115
2116
# File 'lib/pdfcrowd.rb', line 2109

def convertUrl(url)
    unless /(?i)^https?:\/\/.*$/.match(url)
        raise Error.new(Pdfcrowd.create_invalid_value_message(url, "convertUrl", "html-to-image", "Supported protocols are http:// and https://.", "convert_url"), 470);
    end
    
    @fields['url'] = url
    @helper.post(@fields, @files, @raw_data)
end