Start a conversation

Programming

Programming Tips and Tutorials within Scriptcase

  • Verifying if is running under a safe site(web server llS.)

    The Scriptcase provides the macro sc_site_ssl (https protocol) to see if the site is safe. Note: This macro works only for the IIS web server (Internet Information Server). Example 1: Using the affirm...

  • Checking if a field exists in the database via ajax.

    For do this sample we use the idea of a Customers form,with field Cod, CPF and Name. As usual in my forms always use the field cod in auto-increment Name is editable and 100 positions  and CPF editabl...

  • Generate word document for download

    In any application, create a PhP button. Within the button place codes: [field_id] = {field_id}; [field_name_doc]={docname}; [field_name_file]={filename}; sc_redir(blank_2); Put the globals variables ...

  • Separating the date and time display in a field in a query DataTime

    Create a table in MySQL database with the code below CREATE TABLE `banking_bill` ( `id` int(11) NOT NULL auto_increment, `bill_value` varchar(10) NOT NULL, `expiration_date` datetime NOT NULL, `number...

  • Calculating the difference between times

    Example of PHP code that get the difference between time: FUNCTION h2m($hours) {  $t = EXPLODE(:, $hours); $h = $t[0]; IF (ISSET($t[1])) { $m = $t[1];  } ELSE { $m = 00;  } $mm = ($h * 60)+$m; RETURN ...

  • Using masks in Data Entry

    This example will be developed using a form of customized input masks and routine social security number validation using ajax. Creating a new form 1. Create a new application of the standard form (si...

  • Exemplo Boleto Bancário

    Neste tutorial vamos aprender a criar uma aplicação de boleto bancário no Scriptcase, o código de barras utilizado será o 2 de 5 no padrão Febraban de Arrecadação. ( Ao final está disponível o arquivo...

  • Gerando seu próprio exportador de registros em XML.

    Utilizaremos uma aplicação de controle para gerar a funcionalidade de exportação de dados do banco de dados para arquivo XML. O código informado abaixo, poderá ser usado tanto no evento onload, como n...

  • Create a folder using PHP code

    To create a folder on the server partition, use the PHP command: mkdir (); In the example below, I will create a folder where your name will be the current system date. <php $folder = date(Ymd);mkdir ...

  • Reading file with PHP

    The code described below, open and read values from an external file to scriptcase. An example would be a TXT file with values or texts. The tutorial will be based on the use of an control application...