AYUDA EN LÍNEA
 WINDEVWEBDEV Y WINDEV MOBILE

Ayuda / Desarrollar una aplicación o un sitio web / Características específicas de WEBDEV / Mashup
  • Overview
  • How to?
  • Including JavaScript files (.js)
  • Including external resources in the site
  • Automatic detection of encoding
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Including JavaScript files or a Web resource
Overview
WEBDEV allows you to include JavaScript files or external resources in a WEBDEV project. These files can:
  • be included at project level or at page level.
  • be found in the _WEB directory of the site or be a file external to the site
  • be in a specific format (ISO, UTF-8, etc.).
How to?

Including JavaScript files (.js)

You have the ability to include one or more JavaScript files in a site or in a page (*.js). These files will be used by the generated HTML pages. These files must be in the "<ProjectName>_WEB" directory of the site.
To include a JavaScript file in a page:
  1. Open the page description: on the "Page" tab, in the "Description" group, click "Description".
  2. Select the "Details" tab.
  3. In "External resources", you can add JavaScript resources:
    • Click and select the JavaScript file path.
  4. Select (if necessary) the desired encoding. If the encoding corresponds to "<Not defined>", the encoding is automatically detected.
  5. Validate.
To include a JavaScript file in the project:
  1. Open the project description: on the "Project" tab, in the "Project" group, click "Description".
  2. Select the "Advanced" tab.
  3. Click "Additional files...".
  4. Click and select the JavaScript file path.
  5. Select (if necessary) the desired encoding. If the encoding corresponds to "<Not defined>", the encoding is automatically detected.
  6. Validate.

Including external resources in the site

Including external resources in the site is used to include the interface files (programming interface) proposed by the external services (Web API) on the WEB. This gives you the ability to interface with these external services in browser code.
To include an external resource in a page:
  1. Open the page description: on the "Page" tab, in the "Description" group, click "Description".
  2. Select the "Advanced" tab.
  3. Select the "Javascript" tab.
  4. Click "Add a Web resource" and specify the address of the desired web resource.
  5. Select (if necessary) the desired encoding. If the encoding corresponds to "<Not defined>", the encoding is automatically detected.
  6. Validate.
To include an external resource in the project:
  1. Open the project description: on the "Project" tab, in the "Project" group, click "Description".
  2. Select the "Advanced" tab.
  3. Click "Additional files...".
  4. Click "Add a Web resource" and specify the address of the desired web resource.
  5. Select (if necessary) the desired encoding. If the encoding corresponds to "<Not defined>", the encoding is automatically detected.
  6. Validate.

Automatic detection of encoding

If the encoding corresponds to "<Not defined>", the encoding is automatically detected:
  • case of a Web reference: the server is interrogated. The encoding is supplied by the server.
  • case of a file reference: if the file is in UTF8, the encoding is automatically switched to UTF8.
Versión mínima requerida
  • Versión 14
Comentarios
Haga clic en [Agregar] para publicar un comentario

Última modificación: 03/04/2023

Señalar un error o enviar una sugerencia | Ayuda local