Web Project Settings

IN THIS PAGE

Description

Different web project settings available in Alpha Anywhere

Run Time Properties

 Project style

  •  Project style

    Specify the name of the style for all components in the project.

    In each individual component, you must specify the style name as <ProjectStyle>

    You can perform a global update of your components to change the style name to <ProjectStyle> by selecting Edit, Bulk operations from the menu when the Web Projects Control Panel has focus.

  • If you select a style that has a 'compact' option (e.g. the 'Alpha' style), you can specify the project style as 'Alpha:compact'.

 Web site defaults

  •  Default page

    Select the default page to be returned when no page is specified in the request. This value is only used when publishing to an IIS server. See the Xbasic server settings for its list of default page names.

  •  Session lifetime (minutes)

    Enter the number of minutes a session will remain active on the server without any requests from the user. A session will automatically end on the server if no requests are received from the user in this amount of time. This value is only used when publishing to an IIS server.

 Aex files

  •  File list

    Property name: aexFiles.fileNames Specify the name of any .aex files that you want to load when this project is run. AEX Files specified here are loaded automatically when the application is run. It is not necessary to use the a5w_load_aex() function.

 File Download

  •  Allowed filenames

    Enter a comma delimited list of allowed files that can be downloaded from the server. Enter filename patterns using wildcard characters (* and ?). To allow any type of file, enter *.* For example, if you enter: a5*.xls,a5*.pdf - Only .xls files and .pdf files that start with 'a5' can be downloaded. If you only want to specify a list of blocked filename patterns, leave this property blank, or enter *.*.

  •  Disallowed filename

    Enter a comma delimited list of files that can not be downloaded from the server. Enter filename patterns using wildcard characters (* and ?).

  •  Allowed folders

    Enter a comma delimited list of folder names from which files can be downloaded. You can use wildcard characters (* and ?) in the name. Example: *\images,*\pdf - would allow user to download from a folder called 'images' or 'pdf' on any drive. d:\images would only allow download from the 'images' folder on drive D on the server.

    <UserSessionFolder> is not supported in Alpha Anywhere.

    If you leave this blank (not recommended) then files can be downloaded from any folder.

    You can use the <ApplicationRoot> placeholder in the folder name you specify. e.g. <ApplicationRoot>\DownloadFolder

 Javascript Libraries

  •  jQuery Core

    Load jQuery core Javascript Library. You can choose where the library is loaded from. Alpha Anywhere has a built-in version of this library, or you can load it from the Google Content Delivery Network, or the jQuery Content Delivery Network. When you load from Google, you must specify the version you want to load. When you load from the jQuery CDN, the latest stable release is automatically loaded.

  •  jQuery Core Version

    Specify the version number you want to load

  •  jQuery UI

    Load jQuery UI Javascript Library. Requires jQuery Core. You can choose where the library is loaded from. Alpha Anywhere has a built-in version of this library, or you can load it from the Google Content Delivery Network.

  •  jQuery UI Version

    Specify the version number you want to load

  •  Links

    Specify a list of Javascript libraries to link

  •  Include Image Gallery

    Specify if the Image Gallery Javascript libraries should be loaded. If you use the Image Gallery anywhere in your application you must check this option. NOTE: If this option is checked, then you must also check the options to load jQuery core.

  •  Include Google JSAPI library

    Specify if the Google Javascript API library should be loaded. This is needed if you use the Google visualization library in the UX component.

  •  Cordova/PhoneGap libraries

    If you are building a hybrid mobile application that requires a Cordova/PhoneGap Javascript library, specify where the Javascript should be loaded from. Javascript can be loaded from one of the following locations:

    BuiltIn
    Use the built-in version of either the iOS or Android library
    Local
    Use a version that is loaded from a file in the web root
  • If the file is loaded from a "Local" folder, it must be loaded from a folder that follows the required naming convention:

    Javascript\Cordova\IOS\currentVersion\cordova.js, Javascript\Cordova\IOS\2.8.0\cordova.js, Javascript\Cordova\Android\currentVersion\cordova.js, Javascript\Cordova\Android\2.8.0\cordova.js
  •  Include CKEdit HTML Editor Javascript library

    If your component uses the CKEdit HTML editor you must check this box to load the necessary Javascript and CSS libraries.

 CSS Libraries

  •  jQuery CSS

    Specify which jQuery UI CSS library should be loaded. These libraries are loaded from the Google Content Delivery Network.

  •  Links

    Specify a list of CSS libraries to link in the application.

 Resource Providers

  •  Named Providers

    Resource providers such as Google and Facebook can be used for user authentication or access to resources that are available from the provider, such as calendars and documents. A user can log onto a system using their credentials from the provider in place of the user name and password in the web security system. A named provider is used to configure the connection to a specific resource provider.

 Webkit (Chrome/Safari) Specific

  •  Allow static text selection

    Defines whether or not static text can be selected in a mobile or web application. For mobile applications, this property should be set to .f.. This will prevent static-text on a page from being selected. For desktop applications you might want to set this property to .t. so that users can select static-text.

 Stripe Checkout

  •  Define keys

    If your application uses Stripe Checkout, you can specify your Stripe API key here.

 E-mail Settings

  •  SMTP Server

    The URL or IP Address for the SMTP server for sending e-mail.

  •  SMTP server port

    The port used by the SMTP server.

  •  SSL Option

    Defines the SSL option to use when sending Email. If SSL is not used, leave this property blank. Example settings: SSL, TLS.

  •  E-mail account user name

    The user name for the e-mail account used to send e-mail.

  •  E-mail account password

    The password for the e-mail account used to send e-mail.

  •  From address

    The default from address for e-mails sent from the application.

  •  From alias

    The default friendly name for the from address for e-mails sent from the application.

  •  Mandrill key

    If you use the Mandrill web service to send email, you can set the key value here. If you set the value here you will not need to set the value each time you call the Mandrill web service (using the email_send_mandrill() Xbasic function).

 E-mail Outbox

  •  Table type

    Specify if the e-mail outbox is a .DBF or SQL table. The e-mail outbox stores a copy of e-mail messages sent from this application.

  •  Connection string

    Sent e-mail can optionally be stored in an outbox. Specify the connection string to the SQL database where the outbox is stored.

  •  Table name

    Specify the outbox table name where sent emails will be stored.

  •  Sequence name

    Specify the sequence name for the table. The Sequence name is only needed for databases such as Oracle and PostgresSQL that use sequences for auto-increment fields.

  •  Field map

    Specify how the fields in the outbox table are mapped to the required fields. You only need to specify mappings for fields that do not match the corresponding 'system' value shown in the map.

 Audit table (for SQL tables)

Auditing can be enabled to keep track of edits made to SQL tables in an application. Information about each Insert, Update and Delete is kept in the Audit table. This table keeps track of the type of edit, the user id of the person making the edit, the name of table that was edited, and the old and new value of each field that was edited.

  • Video: Auditing Table Edits

    In many applications it is desirable to keep track of every edit made to a SQL table so you can know what fields were changed, who made the edit and when the edit was made. This is often achieved by added update, insert and delete triggers to the SQL database. But in cases where it is not possible to modify the database, you can use the built-in auditing feature in Alpha Anywhere.

    In the first video we show how the auditing feature is set up and used.

    In cases where updates to SQL tables are made in your own Xbasic code (as opposed to from UX and Grid components), it is necessary to manually update the audit log. In the second video we show how this is done.

    2018-15-06

To turn on the Auditing feature, check the Keep track of edits to tables made through Grid and UX components property.

Once you do this, you will be able to specify the connection string to the database where the Audit table is stored. You can either map an existing table, or create a new table.

By default, the User Id of the user who made the edit to a table is obtained from the Alpha Anywhere security framework (by evaluating the context.security.currentUser expression). However, if you are not using the Alpha Anywhere security framework, you can define a custom expression to get the user id of the person who made the edit.

In the case where you are making updates to SQL tables in your own Xbasic code, you will need to manually update the audit log table. There are two helper function in Xbasic to make this easy:

For example, the following code updates a table and also updates the audit log:

dim cn as sql::Connection
cn.open("::Name::AADemo-Northwind")
dim args as sql::arguments
args.add("primaryKey","ALFKI")
args.add("title","Manager")


dim sql as c
sql = "update Customers set ContactTitle = :title where CustomerID = :primaryKey"

'capture the BEFORE update values
dim dataJson as c
dataJson = a5Helper_getAuditInfoFromSQLStatement(cn,sql,args.xml)

flag = cn.Execute(sql,args)

'write to the auditing table
a5Helper_writeToAuditingLog(cn,"Update",dataJson,"CustomerID","ALFKI")
The Audit table can grow to be very large in a large application used by many people. You might want to implement a strategy to purge old records from the audit table from time to time.

A complete list of properties for configuring table auditing are listed below:

  •  Keep track of edits to tables made through Grid and UX Components

    If checked, enables table auditing in Grid and UX Components.

  •  Connection string

    The Connection string property defines the connection to the SQL database where the audit table is defined. If the audit table doesn't exist, you can create one using the Create Audit Table link at the bottom of the Define Audit Table dialog.

  •  Table name

    The Table name property defines the table in the database where the audits are written. If no table exists in your database, you can create the table from within Alpha Anywhere using the link. Using this link will both create the table and populate the Field map, as well.

    If you manually create the audit table, the table must contain the following fields:

    Field name: id, Type: Numeric(10), Primary key: True, Allow Nulls: False, Is Auto-increment: True
    Field name: operation, Type: Character(20), Primary key: False, Allow Nulls: False, Is Auto-increment: False
    Field name: UserId, Type: Character(100), Primary key: False, Allow Nulls: True, Is Auto-increment: False
    Field name: dateStamp, Type: DateTime, Primary key: False, Allow Nulls: False, Is Auto-increment: False
    Field name: data, Type: Memo, Primary key: False, Allow Nulls: False, Is Auto-increment: False
    Field name: databaseTableName, Type: Character(100), Primary key: False, Allow Nulls: False, Is Auto-increment: False
    Field name: primaryKeyFields, Type: Character(200), Primary key: False, Allow Nulls: False, Is Auto-increment: False
    Field name: primaryKeyValue, Type: Character(200), Primary key: False, Allow Nulls: False, Is Auto-increment: False
    Field name: connectionStringToDatabases, Type: Memo, Primary key: False, Allow Nulls: False, Is Auto-increment: False
    Field name: comment, Type: Character(100), Primary key: False, Allow Nulls: True, Is Auto-increment: False
  •  Field map

    The Field map defines a mapping between columns in the audit table and the data collected and written to the table by Alpha Anywhere. The Auto map fields link can be used to automatically map fields in the table to the audit fields.

  •  Expression for User Id

    Defines the user Id to log in the audit table. If you use the Alpha Anywhere Security Framework, Context.Security.CurrentUser will be used to retrieve the user Id.

  • If you are not using the Alpha Anywhere Security Framework, you can define a custom expression for the user Id. In many cases, the user Id is stored in a session variable that is set when a user logs into the system. For example, Context.session.userid. To set the Expression for User Id to use this session variable, you would uncheck the Use security framework to get User Id? and enter the following in the Expression to evaluate to get User Id text box:

    Context.session.userid

 Repository Settings

  •  Table type

    Specify if the repository is a .DBF or SQL table.

  •  Connection string

    Specify the connection string to the SQL database.

  •  Table name

    Specify the table name.

  •  Field map

    Specify how the fields in the repository table are mapped to the required fields. Only fields that are different from their 'system' value are shown in the map.

 Work Queue Table Settings

  •  Table type

    Specify the table type for the Work Queue.

  •  Connection string

    Specify the connection string to the database for the Work Queue.

  •  Table name

    Specify the name of the table for the Work Queue.

  •  Field map

    Specify how the fields in the Work Queue table are mapped to the required fields. Only fields that are different from their 'system' value are shown in the map.

 Help Table Settings

  •  Table type

    Specify if the Help Table is a .DBF or SQL table.

  •  Connection string

    Specify the connection string to the SQL database.

  •  Table name

    Specify the table name.

  •  Field map

    Specify how the fields in the Help Table table are mapped to the required fields. Only fields that are different from their 'system' value are shown in the map.

 Text Dictionary Table Settings

  •  Table type

    Specify if the Text Dictionary Table is a .DBF or SQL table.

  •  Connection string

    Specify the connection string to the SQL database.

  •  Table name

    Specify the table name.

  •  Field map

    Specify how the fields in the Text Dictionary Table table are mapped to the required fields. Only fields that are different from their 'system' value are shown in the map.

 Offline Data Synchronization Log Table Settings

  •  Table type

    ALWAYS SET TO SQL

  •  Connection string

    Specify the connection string to the SQL database.

  •  Table name

    Specify the table name.

  •  Field map

    Specify how the fields in the Data Synchronization Log table are mapped to the required fields. Only fields that are different from their 'system' value are shown in the map.

 Application Global Variables

  •  Define application variables

    Specify any application global variables. These variables can be seen by every page and component in this application.

 Calendar Component

  •  License number

    Specify the license number for your Calendar component. The license number in the Calendar component itself should be set to: <GetFromProjectSetings>

 PDF Printing Options

  •  Use Microsoft XPS printer to generate PDF files

    Specify if the Microsoft XPS printer should be used instead of the Amyuni PDF printer driver to generate PDF files. When you use this option, you can specify if the resulting XPS files should be converted to PDF files before being sent to the browser, or if they should be sent to the browser as XPS files.

  •  Convert XPS files to PDF before sending to client

    Defines whether or not XPS files should be converted to a PDF format before being sent to the client.

    If you choose to send the resulting XPS files to the browser without first converting them to PDF, only Microsoft Internet Explorer will be able to display the file directly in the browser. All other browsers will download the file and you will have to use the local XPS viewer application to see the file.

  •  Print timeout (seconds)

    Large PDF reports may take a long time to build and you may want to cancel reports that take too long to create. The print timeout setting will cancel any report that has not completed in the allowed time (in seconds). Set the timeout to 0 to allow all reports to run to completion. An error will be reported back to the user if a report is cancelled because it exceeded the allowed time.

  •  Print timeout message (optional)

    The system will generate an error message if a PDF report times out. Any optional message entered here will replace the system error message if the report times out.

 Report Server

  •  Disable

    Specify if the Report Server (used for printing PDF Reports in Web Applications) should be disabled. By default (in V12 and above) a 4 core Report Server is automatically enabled. (To license a Report Server that uses more than 4 cores, contact Alpha Software).

  •  Use For HTML Reports

    Offload HTML reports to the report server. This option should be used under conditions where your HTML reports are very large or complex.

 Web-socket Applications

Design Time Properties

 Automatic Backups

  •  Backup folder

    When you edit your Components an automatic backup is created. If you leave this property blank, the backups are stored in a subfolder in your web project. You can specify a folder where you would like the backups to be stored.

 Create AEX for Live Preview

  •  Auto-create AEX for Live Preview

    When doing a Live Preview from a component builder, should all functions and classes defined in the Code tab of the Control Panel be compiled into an AEX file and automatically be published to the LivePreview folder? If you components do not reference any global UDFs, then this property can be turned off.

 Live Preview

  •  Prompt to start server for Live Preview

    When you select Live Preview while working in a Component Builder, if the server is not started, Alpha Anywhere will prompt if you want to start the server. In some cases you might have a server started in another Alpha Anywhere instance, so it would not be necessary to start the server in the current Alpha Anywhere instance. If you check this property, the prompt to start the server will be suppressed.

 A5_Application.A5I File

  •  Encrypt connection strings

    Specify if connection strings in the a5_application.a5i file should be encrypted. Encryption is recommended. Turn encryption off if you are trying to debug a connection problem and want to see what connection strings are getting published.