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.
106
Web Server - Ask For Help / Re: open submenu indented?
« on: January 14, 2023, 11:41:42 AM »
If you're trying to do what's shown in the first pic, Sean, what I've found works is to set each of the "calling" menu items to open to the right (second pic).
jf
jf
108
Web Server - Ask For Help / Hiding password (etc) in web server log
« on: December 24, 2022, 06:56:40 PM »
Grinchly Greetings, Obi Wan!
I was interested in the solution you worked out for masking passwords in the web server log display during this week's webinar.
What you showed mostly works.
BUT? it still leaks passwords BEFORE they get to the AddLog section of code.
As soon as you move around in the log and then come back to the POST, the value has been masked by the code you added in AddLog. But initially it displays on the screen.
If there were an embed available in StartNewThread, before the ?web:LastPost is first displayed, that initial display of sensitive data could be avoided.
[Edited to add - would you add an embed before that DISPLAY statement ? ]
Of course, that requires running the filtering code twice
Holiday Cheers,
Jane
I was interested in the solution you worked out for masking passwords in the web server log display during this week's webinar.
What you showed mostly works.
BUT? it still leaks passwords BEFORE they get to the AddLog section of code.
As soon as you move around in the log and then come back to the POST, the value has been masked by the code you added in AddLog. But initially it displays on the screen.
If there were an embed available in StartNewThread, before the ?web:LastPost is first displayed, that initial display of sensitive data could be avoided.
[Edited to add - would you add an embed before that DISPLAY statement ? ]
Of course, that requires running the filtering code twice

Holiday Cheers,
Jane
109
Web Server - Ask For Help / Re: Load balancing
« on: December 21, 2022, 09:04:52 AM »
Thanks, Don.
Coincidentally, Gordon did a ClarionLive webinar last Friday where he showed an overview of his current architecture.
As Bruce indicated, Gordon has moved a lot of stuff into the javascript app in the browser (which is something like 300K lines of code) to minimize use of the session queue.
What session queue he IS using is on a separate database. https://www.youtube.com/live/6x1wvtstK74?t=2806
But he also has a large-ish team of programmers and many years of coding underlying the app.
Coincidentally, Gordon did a ClarionLive webinar last Friday where he showed an overview of his current architecture.
As Bruce indicated, Gordon has moved a lot of stuff into the javascript app in the browser (which is something like 300K lines of code) to minimize use of the session queue.
What session queue he IS using is on a separate database. https://www.youtube.com/live/6x1wvtstK74?t=2806
But he also has a large-ish team of programmers and many years of coding underlying the app.
110
Web Server - Ask For Help / Re: Load balancing
« on: December 20, 2022, 10:43:51 AM »It does not address sessions.
So how do you deal with that, Don?
Does Nginx just always direct session xyz to the same instance that session used for the previous call(s) ?
Cheers,
Jane
111
Web Server - Ask For Help / Re: Load balancing
« on: December 19, 2022, 12:02:36 PM »but how would it be done with one of the existing tools? do you have example, documentation or webminar?Gordon Holfelder did a webinar on this for the CIDC 2019 conference, which is still online if you purchased that conference:
https://www.cidc2019.com/Presentations#LoadBalancingaWebserverAcrossMultipleInstances
As I recall, one of his challenges was sharing session values across multiple web servers.
The Net Sessions interface that Bruce introduced in NT 12 should make sharing session values easier.
112
Web Server - Ask For Help / Re: My tip broke my menu
« on: December 07, 2022, 05:39:42 PM »
Thanks!
114
Web Server - Ask For Help / My tip broke my menu
« on: December 06, 2022, 06:21:33 PM »
Bruce,
On a drop-down menu I put the following as a tool-tip:
Seemed innocuous, but it wound up breaking the entire menu.
Took a bit of head scratching to discover that the tip gets concatenated with the button class and it all has to fit into 256 characters.
Would you considering making those strings larger?
Thanks,
Jane
On a drop-down menu I put the following as a tool-tip:
Code: [Select]
'View items that need to be configured at the command-line or in the web server app window.'
Seemed innocuous, but it wound up breaking the entire menu.
Took a bit of head scratching to discover that the tip gets concatenated with the button class and it all has to fit into 256 characters.
Would you considering making those strings larger?
Thanks,
Jane
115
Web Server - Ask For Help / Re: Secwin 7.40 compiling error
« on: December 06, 2022, 11:59:33 AM »
Compiles on my machine. What version of MyTable are you using?
116
Web Server - Ask For Help / Re: Wizard type Tab style does not work.
« on: December 05, 2022, 09:00:01 AM »
WOMM with 12.50.
Maybe use the Themer example to see what settings you may be missing.
Maybe use the Themer example to see what settings you may be missing.
117
Web Server - Ask For Help / Re: NetWebClient : handling of general HTTP errors (like 402, 404, etc)
« on: October 24, 2022, 02:04:14 PM »
Try this in PageReceived after the parent call and see if it's useful:
Code: [Select]
self.trace('pageReceived response = ' & self.ServerResponse)
118
Web Server - Ask For Help / Re: jFiles : "pretty" JSON?
« on: October 24, 2022, 01:42:38 PM »
Maybe play with the format parameter on the Save method? https://www.capesoft.com/docs/jfiles2/jfiles.htm#Save
119
Web Server - Ask For Help / Re: Script defer
« on: October 24, 2022, 01:37:58 PM »
>> could these not be set as deferred as well?
Not really. As the doc I quoted says (emphasis added)
inline scripts without the type="module" attribute, are fetched and executed immediately
The bits I would need to defer I'm actually building up in a StringTheory object with <script> tags and the various parameters built in to the string. Then sent with packet.Append.
Apparently those are considered "inline" scripts and cannot be deferred.
So I'd have to rewrite them into script files. And doing javascript functions with $(document).ready that have parameters is a bit above my skill level. Perhaps an exercise for the student some rainy Saturday. (Although unfortunately we only get rain for about 12 minutes per year
)
Simplest for me was just to write a little Clarion code that mimics p_web.AddScript without the DEFER and to call that when I need to.
Apparently this is only an issue for me and nobody else has reported a problem with $(document).ready getting called too early with an inline script. And I've got a workaround now.
Cheers,
Jane
Not really. As the doc I quoted says (emphasis added)
inline scripts without the type="module" attribute, are fetched and executed immediately
The bits I would need to defer I'm actually building up in a StringTheory object with <script> tags and the various parameters built in to the string. Then sent with packet.Append.
Apparently those are considered "inline" scripts and cannot be deferred.
So I'd have to rewrite them into script files. And doing javascript functions with $(document).ready that have parameters is a bit above my skill level. Perhaps an exercise for the student some rainy Saturday. (Although unfortunately we only get rain for about 12 minutes per year

Simplest for me was just to write a little Clarion code that mimics p_web.AddScript without the DEFER and to call that when I need to.
Apparently this is only an issue for me and nobody else has reported a problem with $(document).ready getting called too early with an inline script. And I've got a workaround now.
Cheers,
Jane
120
Web Server - Ask For Help / Script defer
« on: October 23, 2022, 04:08:46 PM »
Bruce,
I ran into a minor head-scratcher updating an app from 11.47 to 12.47.
This is a "hybrid" app.
Much of it is pure NetTalk. But for reasons of imposed aesthetic choices, it has a section that displays pages formatted with Bootstrap. (They are patient status display pages on large monitors on the wall in various clinics. The status is updated every 15 seconds. A URL parameter hard-coded into the dedicated ChromeBox at each site tells the server which site's patients to display.) This was originally built in NT 10 and has been on NT 11 for the past couple of years.
Those pages are a NetWebPage "shell" that contains a framework of scripts and CSS and a named division.
One script is on a timer to update that named division by making a call to another NetWebPage every 15 seconds.
The scripts in the "shell" page are jquery and bootstrap (from the /scripts folder) and several scripts hard-coded in the NetWebPage. The latter are in the page rather than in a file because they include variables based on the URL sent to the page.
Then kaboom when I rebuilt with 12.47.
The reason turns out to be that you've added "defer" to NetWebServerWorkerBase.AddScript
That "defer" in the jquery loading then caused my locally-built scripts to throw an error - Uncaught ReferenceError: $ is not defined
What do you mean it isn't defined?? I just defined it!!! (Well, yeah.)
Anyway, now that I'm aware of the issue I've fixed my code in that one NetWebPage and all is well.
But I was wondering whether there would be any value in having an optional parameter to override that "defer" in NetWebServerWorkerBase.AddScript (or an overload version)?
Interestingly, looking at the NT history it says "Add: DEFER attribute added to all <script> sections. " for version 4.31(beta)
And then again "Add: defer attribute to script files" for 12.09.
BTW - you generate
The Mozilla docs say defer is Boolean. https://developer.mozilla.org/en-US/docs/Web/HTML/Element/script#attr-defer
My own experiment finds that just the presence of the single word defer triggers the behavior.
As that Mozilla link says,
And that's how I spent my Sunday
Cheers,
Jane
I ran into a minor head-scratcher updating an app from 11.47 to 12.47.
This is a "hybrid" app.
Much of it is pure NetTalk. But for reasons of imposed aesthetic choices, it has a section that displays pages formatted with Bootstrap. (They are patient status display pages on large monitors on the wall in various clinics. The status is updated every 15 seconds. A URL parameter hard-coded into the dedicated ChromeBox at each site tells the server which site's patients to display.) This was originally built in NT 10 and has been on NT 11 for the past couple of years.
Those pages are a NetWebPage "shell" that contains a framework of scripts and CSS and a named division.
One script is on a timer to update that named division by making a call to another NetWebPage every 15 seconds.
The scripts in the "shell" page are jquery and bootstrap (from the /scripts folder) and several scripts hard-coded in the NetWebPage. The latter are in the page rather than in a file because they include variables based on the URL sent to the page.
Then kaboom when I rebuilt with 12.47.
The reason turns out to be that you've added "defer" to NetWebServerWorkerBase.AddScript
That "defer" in the jquery loading then caused my locally-built scripts to throw an error - Uncaught ReferenceError: $ is not defined
What do you mean it isn't defined?? I just defined it!!! (Well, yeah.)
Anyway, now that I'm aware of the issue I've fixed my code in that one NetWebPage and all is well.
But I was wondering whether there would be any value in having an optional parameter to override that "defer" in NetWebServerWorkerBase.AddScript (or an overload version)?
Interestingly, looking at the NT history it says "Add: DEFER attribute added to all <script> sections. " for version 4.31(beta)
And then again "Add: defer attribute to script files" for 12.09.
BTW - you generate
Code: [Select]
defer="defer"
The Mozilla docs say defer is Boolean. https://developer.mozilla.org/en-US/docs/Web/HTML/Element/script#attr-defer
My own experiment finds that just the presence of the single word defer triggers the behavior.
As that Mozilla link says,
Quote
inline scripts without the type="module" attribute, are fetched and executed immediately,So I need to un-defer the jquery rather than defer my inline scripts.
And that's how I spent my Sunday

Cheers,
Jane