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.


Messages - Bruce

Pages: 1 ... 3 4 [5] 6 7 ... 717
61
Web Server - Ask For Help / Re: Web Service question, part 2
« on: December 22, 2022, 09:28:37 PM »
Hi Jeff,

embedding users and passwords in code is not ideal, because then you need to start worrying about who can see that code.
Like for example if this code is committed into source control, especially public source control, then it would be an issue.
But for compiled programs, with minimal or no distribution of source code it's ok.

Base64 encoding the user name or password serves no purpose. The value will already be base64 encoded by the Authenticate command.
Obviously you can only use Basic Authentication against an HTTPS, not HTTP server, as the password and username are in plaintext in the header.

>> 2.  Is this technique, using a username and password to access a web service/API, the preferred way?

it's not preferred more or less than anything else. It's a perfectly good way, and commonly used. It's completely supported by NetTalk. There are other ways to do Auth, this is just one, and a perfectly good one (as long as HTTPS is in play).

>> I use another unrelated API, where I send a key/code to the API. 

key / code == user/password - same thing, different names.

>> I'm not sure how or if this can be done with a NT API/Web Service.

authentication can be passed to the server any number of ways. Whichever way you prefer you can do.

Cheers
Bruce



62
Web Server - Ask For Help / Re: NT12.52 - opening file error in DebugView
« on: December 22, 2022, 09:20:14 PM »
I would need an example of the app, and the effect, to comment.

Cheers
Bruce

63
Web Server - Ask For Help / Re: Larges Reports on NT
« on: December 22, 2022, 09:18:42 PM »
You should probably better understand the cause of the crash etc so that you can determine the fault.
Also make sure your progress timer on such a long report is really slow.

To answer your question, of course you can let a user submit a report request, and then email them the result.

cheers
Bruce

64
Web Server - Ask For Help / Re: What Triggers the Busy Image?
« on: December 22, 2022, 09:16:44 PM »
it's just a div id="_busy"
So yes, you can hide or show it.

In javascript (client side) you can just do
$('#_busy).hide()
or
$('#_busy).show()

On the server side it's more complex, because you can include script in a reply, but it'll only get executed when the reply is completely formed and completely sent to the client.

so typically you unhide on the client side, and hide on the server side.

Obviously you need to full understand how the engine is using it as well, because there are other things hiding and unhiding it.

In summary - you probably should not be hiding and unhiding that graphic yourself. If you want to notify the user of things happening, use your own graphic, or a progress bar.

cheers
Bruce


65
Alas, no ideas Alberto.
I guess you need to break it down some more, and figure it out.

Perhaps create small examples to show the effect you are trying.

Maybe use a different Busy graphic, which you can unhide, and hide, without worrying about mine.

66
Web Server - Ask For Help / Re: What Triggers the Busy Image?
« on: December 19, 2022, 08:12:21 PM »
many things.

67
Web Server - Ask For Help / Re: Load balancing
« on: December 19, 2022, 08:12:09 PM »
>> but how would it be done with one of the existing tools?

the web is full of information on load balancing. Google is your friend. I recommend searching on
"http session based load balancer"

>> do you have example, documentation or webinar?

personally, no.

>> As I recall, one of his challenges was sharing session values across multiple web servers. 

not really [1].
Session based load balancers are a thing, and there are plenty of them, including things like nginx.

What Gordon wanted was to share the session itself between multiple servers, because this makes redundancy better (a single machine can be removed at will).

>> The Net Sessions interface that Bruce introduced in NT 12 should make sharing session values easier.

This is correct. However Gordon uses a different framework for his apps, one which basically does very (very) few reads and writes to session data. So storing the session data off-server makes sense. For a regular NetTalk web app, I don't recommend off-server session storage.

Since session-based load balancing is a thing, I would recommend this route first.

cheers
Bruce


68
Web Server - Ask For Help / Re: Load balancing
« on: December 18, 2022, 09:20:02 PM »
Load Balancing is something that happens outside the server, not inside the server.

A Load Balancer accepts traffic, then passes it on to another server (the NetTalk Server) for processing.

Lots and lots of Load Balancer programs already exist, and are perfectly good at balancing. So re-writing one of those in NetTalk seems like it adds a lot of work, for zero gain in actual functionality.

So, to answer your question, no I'm not planning on implementing a load balancer in NT14.

Cheers
Bruce

69
Web Server - Ask For Help / Re: 7.15 browse - no print button
« on: December 12, 2022, 07:18:31 PM »
indeed

70
Web Server - Ask For Help / Re: Wizard type Tab style does not work.
« on: December 07, 2022, 10:04:12 PM »
hi Jari,

thanks for the example.
Here's what I did;

>> a) check the browser console to see if there are any messages

I opened the browser console (F11) and checked to see if there were any console error messages. There were not.

>> b) as a test- switch the form from popup mode to page mode and see if there are any messages.

I switched the browse so it calls the form in Page mode instead of popup mode. I then opened the browser console, and checked for messages while it went to the form.

I saw the following error in the console;

>> MailboxesFormControl:245 Uncaught ReferenceError: tinyMCE is not defined at MailboxesFormControl:245:1

This means the form is using the tinyMCE control (which it is) but in the Web server procedure support for TinyMCE is not turned on.

I turned on support for TinyMCE and tested again, and then it worked fine. I switched it back to being a popup form, and it worked fine.

I recommend you follow the same process in your app to see if there's a console message telling you what is wrong.

Cheers
Bruce




71
Web Server - Ask For Help / Re: How about adding some helper funcions
« on: December 07, 2022, 01:38:46 AM »
noted. I'm not sure where this ends though. there are more-or-less an infinite number of things that could come into play here.

72
Web Server - Ask For Help / Re: UTF8 coming in to API Server
« on: December 07, 2022, 01:37:49 AM »
json.Start method _after_ the parent call.

Cheers
Bruce

73
Web Server - Ask For Help / Re: My tip broke my menu
« on: December 07, 2022, 01:35:25 AM »
done for 12.51

74
Web Server - Ask For Help / Re: Secwin 7.40 compiling error
« on: December 06, 2022, 10:54:34 PM »
global extension for myTable and Secwin
Classes Tab
refreshClasses.

75
Web Server - Ask For Help / Re: Wizard type Tab style does not work.
« on: December 06, 2022, 10:15:08 PM »
Hi Jari,

I don't think that's a wizard-tab issue. I think it's a "something you are populating on the form" issue.

a) check the browser console to see if there are any messages
b) as a test- switch the form from popup mode to page mode and see if there are any messages.

Cheers
Bruce

Pages: 1 ... 3 4 [5] 6 7 ... 717