# Example Configure Script

The following example illustrates the `configure_atom.lua` script.

    function getConfigOptions()
       return {
          SSLMethod="SSLV23",
       }
    end

    function getNamespaces()
       return {
          atom="http://www.w3.org/2005/Atom"
       }
    end

    function getDateFormats()
       return { "YYYY-MM-DDTHH:NN:SS" }
    end

    -- ################ FEED URL ################

    function getFeedUrls()
       local config = get_config()
       local section = get_param("SECTION")
       local url = config:getValue(section, "FEEDURL", "")
       return { url };
    end

    -- ################ FEED ################

    function getFeedModifiedDateXPath()
       cache_result()
       return "/atom:feed/atom:updated"
    end

    function getEntryXPaths()
       cache_result()
       return { "/atom:feed/atom:entry" }
    end

    function getNextUrlXPaths()
       cache_result()
       return { "/atom:feed/atom:link[@rel='next']/@href" }
    end

    -- ################ ENTRIES ################

    function getEntryIdXPath()
       cache_result()
       return "~/atom:id"
    end

    function getEntryModifiedDateXPath()
       cache_result()
       return "~/atom:updated"
    end

    function getEntryMetadataXPaths()
       cache_result()
       return {
           ID="~/atom:id",
           URL="~/atom:link[@rel='alternate']/@href",
           DRETITLE="~/atom:title[@type='text']",
           AUTHOR="~/atom:author/atom:name",
           PUBLISHED_DATE="~/atom:published",
           UPDATED_DATE="~/atom:updated",
       }
    end

    function getEntryContentUrlXPath()
       cache_result()
       return "~/atom:content[starts-with(@src,http)]/@src"
    end

    function getEntryContentXPath()
       cache_result()
       return "~/atom:content"
    end

© Copyright 2019 Micro Focus or one of its affiliates | Send documentation feedback Close Send documentation feedback To open the configured email client on this computer, open an email window. Otherwise, copy the information below to a mail client, and then send this email to swpdl.idoldocsfeedback@microfocus.com. We appreciate your feedback! Product: Topic Title: Help Topic: Feedback:

_FT_HTML5_bannerTitle.htm