Please enable JavaScript to view this site.

In this example using ISP a newsletter will be composed in the next steps:

Create a profile option containing the layout of the newsletter.

Create a profile option containing the ISP.

Send newsletter, select the users and create the emails used for the newsletter.

Note that you can merge both profile options to one profile option.

The final result is a newsletter in the following format:

Vlijm Netwerkbeheear Newsletter with Invantive Server Pages Image

Profile Option Layout Newsletter

This local profile option contains the layout of the newsletter. The texts ‘: Payload’ and ‘: FOOTER’ are replaced by the message:

Newsletter Profile Options web front end Screen

Profile Option ISP

This local profile option contains the ISP to compose the message:

Newsletter Code with Invantive Server Pages Web Front End Screen

The code is:

<%@ page language="ISP" %>

<%

declare

 l_gbr_aanhef      varchar2(500);

 l_template        clob;

 l_payload         clob;

 l_tak_found       boolean;

begin

 l_template := bubs#profiel_opties.get_value('xxinet-html-nieuwsbrief-template');

 l_payload  := '';

 --

 -- Determine greeting.

 --

 select 'Geachte '

        || case

           when gbr.gbr_geslacht_ind = 'M'

           then 'heer '

           when gbr.gbr_geslacht_ind = ‘V’

           then 'mevrouw '

           else ''

           end

        || gbr_naam

 into   l_gbr_aanhef

 from   bubs_gebruikers_v gbr

 where  gbr.gbr_id = l_parameters_map('GBR_ID')

 ;

 l_payload  := l_payload || l_gbr_aanhef || ‘,’;

 l_payload  := l_payload || '<br/>';

 l_payload  := l_payload || 'De processen die door u gemeld zijn:';

 l_payload  := l_payload || '<ul>';

 l_tak_found := false;

 --

 for r_tak in

 ( select tak.code tak_code

   ,      tak.omschrijving tak_omschrijving

   from   bubs_processen tak

   where  tak.gbr_id_melder = l_parameters_map('GBR_ID')

   order

   by     tak.id desc

 )

 loop

   l_payload := l_payload || '<li>Proces ' || r_tak.tak_code || ': ' || r_tak.tak_omschrijving || '</li>';

 end loop;

 --

 if not l_tak_found

 then

   l_payload := l_payload || '<li>Geen meldingen.</li>';

 end if;

 --

 l_payload  := l_payload || '</ul>';

 --

 -- Merge both.

 --

 l_template := replace(l_template, ':PAYLOAD', l_payload);

 l_template := replace

               ( l_template

               , ':FOOTER'

               , 'Deze e-mail is verzonden op '

                 || to_char(sysdate, 'DD-MM-YYYY HH24:MI:SS')

                 || ' aan '

                 || l_parameters_map('GBR_EMAIL_ADRES')

                 || '. Klik <a href="http://site/afmelden?GBR_ID='

                 || to_char(l_parameters_map('GBR_ID'))

                 || '">hier</a> om af te melden.'

               );

 itgen_isp.print_clob(l_template);

end;

%>

<!-- Aangemaakt met Invantive Estate -->

Send Newsletter

After this one time activities it is easy to send the newsletter with for example:

begin

 --

 -- Log on to Invantive Estate

 --

 bubs_session.set_session_info

 ( 'toad.sql'

 , 'install'

 , 'system'

 , 'Newsletter'

 , coalesce(sys_context('userenv', 'ip_address'), '?')

 , sys_context('userenv', 'host')

 , 'n/a'

 , 'TOAD ' || to_char(sysdate, 'YYYYMMDDHH24MISS')

 );

end;

/

insert into bubs_berichten_v

( brt_afgehandeld_vlag

, brt_afzender

, brt_afzender_naam

, brt_boodschap_l

, brt_mime_type

, brt_onderwerp

, brt_ontvanger

, brt_ontvanger_naam

, brt_ref_tabel

, brt_ref_sleutel

, brt_vertalen_vlag

)

select 'N'

,      'info@acme.com'

,      'ACME'

,      itgen_isp.run

      ( bubs#profiel_opties.get_value('xxacme-html-nieuwsbrief-isp')

      , 'GBR_ID=' || itgen_url.escape_cached(to_char(gbr.gbr_id), 'Y')

        || '&' || 'GBR_NAAM=' || itgen_url.escape_cached(gbr.gbr_naam, 'Y')

        || '&' || 'GBR_EMAIL_ADRES=' || itgen_url.escape_cached(gbr.gbr_email_adres, 'Y')

      )

,     'text/html'

,     'ACME nieuwsbrief november 2009'

,     gbr.gbr_emil_adres

,     gbr.gbr_naam

,     'GBR'

,     gbr.gbr_id

,     'Y'

from  bubs_gebruikers_v gbr

where 1=1

and   gbr.gbr_email_adres is not null

/

commit

/

X

Important Safety and Usage Information

Intended Use and Limitations: This software, developed by Invantive, is designed to support a variety of business and information technology data processing functions, such as accounting, financial reporting an sales reporting. It is important to note that this software is not designed, tested, or approved for use in environments where malfunction or failure could lead to life-threatening situations or severe physical or environmental damage. This includes, but is not limited to:

  • Nuclear facilities: The software should not be used for operations or functions related to the control, maintenance, or operation of nuclear facilities.
  • Defense and Military Applications: This software is not suitable for use in defense-related applications, including but not limited to weaponry control, military strategy planning, or any other aspects of national defense.
  • Aviation: The software is not intended for use in the operation, navigation, or communication systems of any aircraft or air traffic control environments.
  • Healthcare and Medicine Production: This software should not be utilized for medical device operation, patient data analysis for critical health decisions, pharmaceutical production, or medical research where its failure or malfunction could impact patient health.
  • Chemical and Hazardous Material Handling: This software is not intended for the management, control, or operational aspects of chemical plants or hazardous material handling facilities. Any malfunction in software used in these settings could result in dangerous chemical spills, explosions, or environmental disasters.
  • Transportation and Traffic Control Systems: The software should not be used for the control, operation, or management of transportation systems, including railway signal controls, subway systems, or traffic light management. Malfunctions in such critical systems could lead to severe accidents and endanger public safety.
  • Energy Grid and Utility Control Systems: This software is not designed for the control or operation of energy grid systems, including electrical substations, renewable energy control systems, or water utility control systems. The failure of software in these areas could lead to significant power outages, water supply disruptions, or other public utility failures, potentially endangering communities and causing extensive damage.
  • Other High-Risk Environments: Any other critical infrastructure and environments where a failure of the software could result in significant harm to individuals or the environment.

User Responsibility: Users must ensure that they understand the intended use of the software and refrain from deploying it in any setting that falls outside of its designed purpose. It is the responsibility of the user to assess the suitability of the software for their intended application, especially in any scenarios that might pose a risk to life, health, or the environment.

Disclaimer of Liability: Invantive disclaims any responsibility for damage, injury, or legal consequences resulting from the use or misuse of this software in prohibited or unintended applications.

  
Disclaimer