NetTalk Central

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - JohanR

Pages: [1] 2 3 ... 10
1
Web Server - Ask For Help / Inbound stream from Postmark
« on: March 30, 2024, 03:38:44 AM »
Hi,

I have created my NetWebPage to receive data (JSON) from Postmark,
as well as the data structures and code using the CodeWriter

but am a little confused as to how to get the data to load into the json data structure?
p_web.?

p_web.GetValue('json') , gives me nothing,
do I need to set some settings first, or which p_web method do I use to return the data to load into

  SomeLoadString.SetValue(p_web.GetValue('json'))
  json.start()
  json.SetTagCase(jf:CaseAsIs)
  json.Load(element,SomeLoadString) ! Load From a StringTheory object


This seems to give me an empty string


thanks

Johan






2
Hi,

Perhaps 2 questions in 1

1)
I've seen several posts and it does not seem as if there is a simple solution to change the heading text after the form is generated.
Is there simple way to change heading on a form?

2)
Is there a way to wrap a TABLE form in a MEMORY form, but still have the TABLE function normally?
IOW use the TABLE form as an update form from a browse, but still wrapped inside the MEMORY form?
Thinking is to use the wrapping MEMORY form to populate fields above the TABLE form tab


thanks

Johan
 

3
Web Server - Ask For Help / User feedback?
« on: March 14, 2024, 01:19:01 AM »
Hi,

For some reason can't figure out how to get a user response when they click a button and act accordingly?

eg. similar to the message function.
'Are you sure you want cancel this action?'
if yes - delete record
if no - leave as is

If I look at the code , it seems as if the Form "Cancel confirmation" message that pops up is part of the form function
Is there a way I can include a custom action in this function?


thanks

Johan


4
Web Server - Ask For Help / Processing incoming mail via Postmark
« on: February 28, 2024, 01:54:40 AM »

Hi

Am trying to process incoming mail being sent to a webhook
The data declaration below is for the attachments on the mail

The "Content" field will contain the attachment.
Total cumulative size for all Inbound attachment files may not exceed 35 MB

How do I change the declaration of "Content" to variable length?
The length is specified in "ContentLength" but I need to change STRING(255) to expect a variable length

After the structure change , would I have to change the loading code?

thanks

Johan

from the postmark docs
 
],
  "Attachments": [
    {
      "Name": "test.txt",
      "Content": "VGhpcyBpcyBhdHRhY2htZW50IGNvbnRlbnRzLCBiYXNlLTY0IGVuY29kZWQu",
      "ContentType": "text/plain",
      "ContentLength": 45
    }
  ]

generated code and structure from capesoft codewriter


AttachmentsQueueType      Queue,Type,Name('Attachments')
Name                       STRING(255),Name('Name')
Content                    STRING(255),Name('Content')
ContentType                STRING(255),Name('ContentType')
ContentLength              Real,Name('ContentLength')
                         End

json.NewPointer          Procedure(*Cstring pGroupName, *CString pColumnName)
  ! note that pColumnName is the json tag name, not the label. case sensitive.
  Code
  case pGroupName & '.' & pColumnName
  Of 'group.ToFull'
    element.ToFull &= NEW ToFullQueueType
  Of 'group.CcFull'
    element.CcFull &= NEW CcFullQueueType
  Of 'group.BccFull'
    element.BccFull &= NEW BccFullQueueType
  Of 'group.Headers'
    element.Headers &= NEW HeadersQueueType
  Of 'group.Attachments'
    element.Attachments &= NEW AttachmentsQueueType
  End






5
Web Server - Ask For Help / VarnishCheck? slightly NTWS related
« on: February 25, 2024, 12:40:11 AM »
Hi,

I have moved from an old windows server(2012R2) to windows server 2022

All good as far as I can see,
however now my NTWS is being hit with this request every second.

[insecure] GET /varnishcheck HTTP/1.1
Host: 197.189.218.234
Connection: close
User-Agent: Amazon-Route53-Health-Check-Service (ref b2bec952-b505-45e9-9f3d-74bbf25e43d7; report http://amzn.to/1vsZADi)
Accept: */*
Accept-Encoding: identity,gzip,deflate


Seems Varnish is some sort of caching program to speed up websites, still investigating.

Is this just par for the course, or something I can do?
Did not get this on my old server, so just trying to understand why the difference, is it the OS or my setup, or just the way it is?

thanks

Johan







6
Hi,

Having an issue with a NTWS browse procedure not generating anything on the page
The log from debugview is attached

My thinking is that something is generating something funky somewhere

Any ideas appreciated of how to track this down?

thanks

Johan


 

7
Hi,

Thought this might be worth some feedback as it seems to be working quite nicely

Part of my NTWS is serving pure static pages, using the tags as per the manual
<!-- NetWebServer -->
<!-- Net:c:Head -->
<!-- Net:c:BodyEnd -->

On one of the pages I embedded a form, with only a button that call a popup form.
I something to manage and trigger the popup, and that's why I used 2 forms.
One to embed and call the popup form.

See attached pic.
What is quite nice is that the action and display of the popup form cover the static page and the effect is seamless.

Not something special, just a nice simple illustration of a mix of static and dynamic procedures

cheers,
Johan
 












8
Web Server - Ask For Help / How to secure an email form on public website?
« on: September 25, 2023, 01:01:25 AM »
Hi

Looking for any tips/methods to add an NT en email form to a static web page.

Not the capturing and sending of the mail info, but what are good ways to secure this page to prevent spamming or other issues.

One thought I had was to add my own version of captcha
eg.
display random nr and request the user to slide a slider to that nr before displaying the entry fields?

key here is to make it as easy as possible for the user

Any info appreciated

thanks

Johan






9
Hi,

If anyone else is using Google API, this might affect the billing, still investigating this.
I have implemented Google address and been testing it and currently working on refining and see how to improve the user experience.

To find an address it can consist of several calls to Google Autocomplete, this will return a list of possibles.
If the user picks an address then a call is made to Google PlacesDetails which will then return specific info for that address, including the critical required postal code and plus code.

However I found this in the docs this morning and still looking into it.
If I understand it correctly every call will be billed, unless it's wrapped in a sessiontoken ID, which will result in one billing once a call is made to Google PlacesDetials.

As we have been spoilt, a call to stringhteory seems to generate an ID in the correct format.
str.MakeGuid4()

If anyone else has implemented Google search, would appreciate any feedback, I will look into over the weekend and report back as well.


Johan





https://developers.google.com/maps/documentation/places/web-service/autocomplete

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
sessiontoken
A random string which identifies an autocomplete session for billing purposes.

The session begins when the user starts typing a query, and concludes when they select a place and a call to Place Details is made. Each session can have multiple queries, followed by one place selection. The API key(s) used for each request within a session must belong to the same Google Cloud Console project. Once a session has concluded, the token is no longer valid; your app must generate a fresh token for each session. If the sessiontoken parameter is omitted, or if you reuse a session token, the session is charged as if no session token was provided (each request is billed separately).

We recommend the following guidelines:

Use session tokens for all autocomplete sessions.
Generate a fresh token for each session. Using a version 4 UUID is recommended.
Ensure that the API key(s) used for all Place Autocomplete and Place Details requests within a session belong to the same Cloud Console project.
Be sure to pass a unique session token for each new session. Using the same token for more than one session will result in each request being billed individually.
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++


10
Hi,

Received the update folder error,
netweb.js file is version 14.00 in the libsrc folder after installing 14.01,
to temp fix I changed the version nr to 14.01

Assuming it's just a sync problem with the version nrs.
 

Johan

11
Web Server - Ask For Help / GPF on this line - loc:gridjson JSONClass
« on: August 16, 2023, 07:08:39 AM »
Hi,

NT 14.01
Latest jfiles and all the rest,
various procedures , all of them throws a GPF on this decleration.

loc:gridjson   JSONClass

Any ideas?

thanks

Johan




12
Web Server - Ask For Help / Add new client using button from UpdateForm
« on: August 06, 2023, 09:47:06 AM »
Hi,

Update FORM on order table has a button that add a new client via UpdateClient FORM , a popup.

In the GotFocusBack routine I need to retrieve the client_id of the newly added client.
I query "_refresh_" for "saved", but the are no table values in the value queue,
so currently am setting a p_web.SSV('tmp_client_isn') in the save embed on the ClientUpdate form and then use that on FocusBack.

Is there a better alternative?

Below the value queue

[TVCWEB] Value Q Name=_action_ Value=1
[TVCWEB] Value Q Name=_ajax_ Value=1
[TVCWEB] Value Q Name=_calledfrom_ Value=weborder
[TVCWEB] Value Q Name=_equate_ Value=btn_add_new_client
[TVCWEB] Value Q Name=_event_ Value=gainfocus
[TVCWEB] Value Q Name=_from_ Value=updvendorclient
[TVCWEB] Value Q Name=_parentpage Value=
[TVCWEB] Value Q Name=_popup_ Value=0
[TVCWEB] Value Q Name=_refresh_ Value=saved
[TVCWEB] Value Q Name=_rid_ Value=
[TVCWEB] Value Q Name=viewstate Value=
[TVCWEB] Value Q Name=weborder_form:inited_ Value=1


thanks

Johan


13
Web Server - Ask For Help / Easily see procedure template settings?
« on: August 05, 2023, 11:54:16 PM »
Hi,

Is there a way to easily see template settings of procedures without going into each procedure.
IOW either select certain template settings to display on app window
or how do I track down the values in the TXA?

eg.
I want to make sure that all my NT procedures are secure with the the following settings set correctly
"Only server if"
and
"user must be logged in" = true


So would be useful to have a list of all procedures security settings.

thanks

Johan








14
Web Server - Ask For Help / Passing P_web as parameter - expense?
« on: August 04, 2023, 02:55:04 AM »
Hi,

I have a logging/trace/debug procedure that logs events in my web app.

One of the parameters currently is p_web.

Just trying to figure out,
if I have lots of calls to the debug log procedure with the p_web as a parameter,
but only to return without action because global debug is switched off.
How bad is this?

thanks

Johan

15
Web Server - Ask For Help / Webapps setting - popups
« on: August 03, 2023, 03:04:39 AM »
Hi,

Currently looking at using POPUPS in my app,

I could not get them to work until I changed the setting in "Nettalk global extension" - "webapps" - "Popups"

Now they work, but work everywhere and everything opens a popup,
even if I specify to open as "Link"


thanks

Johan





Pages: [1] 2 3 ... 10