build_secuTrial_url {secuTrialR}R Documentation

Compose a secuTrial URL

Description

Given a secuTrial server URL, and optionally instance, customer, project id and document id, this function composes a URL to a specific secuTrial instance, customer or form.

Usage

build_secuTrial_url(
  server,
  instance = NA,
  customer = NA,
  projid = NA,
  docid = NA
)

Arguments

server

string containing a server URL

instance

(optional) string containing secuTrial instance name

customer

(optional) string containing secuTrial customer label

projid

(optional) string containing secuTrial project identifier

docid

(optional) secuTrial document/form identifer

Details

To find the server and instance of a secuTrial database, simply extract the information from the URL that you usually use to log in. For example in:

https://server.secutrial.com/apps/WebObjects/ST21-setup-DataCapture.woa/wa/choose?customer=TES

Also note that only the server address has to be provided, the other arguments are optional. Thus, there are different scenarios:

Value

string containing a URL to desired secuTrial page. Currently we provide no guarantee that the returned URL is valid.

Examples


# This example, builds pseudo-urls that do not point to an active secuTrial instance.

server <- "server.secutrial.com"
instance <- "ST21-setup-DataCapture"
customer <- "TES"
project <- "7036"
docid <- "181"

build_secuTrial_url(server)
build_secuTrial_url(server, instance)
build_secuTrial_url(server, instance, customer)
build_secuTrial_url(server, instance, customer, project)
build_secuTrial_url(server, instance, customer, project, docid)

# examples of docids (mnpdocid)
path <- system.file("extdata", "sT_exports", "lnames",
                    "s_export_CSV-xls_CTU05_long_ref_miss_en_utf8.zip",
                    package = "secuTrialR")
sT_export <- read_secuTrial(path)

# return docids
docids <- sT_export$ctu05baseline$mnpdocid

# make several links with all docids
build_secuTrial_url(server, instance, customer, project, docids)


[Package secuTrialR version 1.1.1 Index]