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 - JohanR

Pages: [1] 2 3 ... 28
1


Hi Mike

Check the processlink embed
see below some additions I add.

regards

Johan


p_web.ProcessLink PROCEDURE(<string p_action>)

 
  ! -----------------------------------------------------------------------------
  ! The incoming request has been completely parsed and is about to be processed.
  ! No tables have been opened, but they may be soon so this is a good place
  ! to set owner and filename variables .
  ! -----------------------------------------------------------------------------
! [Priority 4000]
                 
  self.metaHeaders = ''&|
   '<meta http-equiv="content-type" content="text/html; charset=utf-8"/><13,10>'&|
   '<meta http-equiv="x-ua-compatible" content="IE=edge"/><13,10>'&|
   '<meta name="author" content="TVCweb"/><13,10>'&|
   '<meta name="description" content="The Vineyard Connection offers premium wines, in-house wine freight, door-to-door wine courier services, and customs clearance solutions. Join our wine club for seamless deliveries worldwide." /><13,10>'&|
   '<meta name="keywords" content="wine shop, wine club, wine freight, wine courier, wine logistics, customs clearance, premium wines, door-to-door wine delivery, South African wines" /><13,10>'&|
   '<meta name="viewport" content="width=device-width, initial-scale=1.0" /><13,10>'&|   
   '<link rel="preconnect" href="https://fonts.googleapis.com" /><13,10>'&|
   '<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin/><13,10>'&|
   '<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=PT+Serif:ital@0;1&display=swap" rel="stylesheet"/><13,10>'&|
   '<link rel="icon" href="/images/favicon.ico" type="image/x-icon" /><13,10>'





2
Web Server - Ask For Help / Re: Change Page Title - browser tab description
« on: December 03, 2025, 08:55:27 PM »
Hi Jane

Thanks!

Coincidentally I found the same way late last night from ChatGPT, but did not try to implement.

Got it working this morning by adding this to the "send new value to server" embed

   p_web.Script('document.title="' & clock() & '";')


Pretty handy, multiple tabs, can display client name, quote nrs, order nr, status etc...
Hardest thing to do now is decide what to display and to keep it short enough

NTWS covers so much thought there might be a builtin method.

thanks again

Johan

3
Web Server - Ask For Help / Re: Change Page Title - browser tab description
« on: December 02, 2025, 09:39:44 PM »
Hi Ron

No,
Its the 'Orders' with the red logo which is on one of the browser tabs.
Currently it's generic, but would be good to have the actual order number there or the quote nr,
if multiple tabs are open

I have added an attachment that currently show multiple tabs with the order nr , this is loaded at page loading,

Trying to see if I can change that text while the user is on the form, eg. when it's a quote and the users converts to a confirmed order, then change it from the quote nr to the order nr.

This is not critical, but a nice touch, and would be good to know how to access that data as it might have other uses for feedback.

This is an example of Bitfinex crypto trading exchange updating the price live
https://trading.bitfinex.com/trading?type=exchange


regards

Johan

 

4
Web Server - Ask For Help / Re: Change Page Title - browser tab description
« on: December 02, 2025, 06:21:15 AM »


Hi Ron

Apologies, my question probably was not clear, seemed very clear to me when I was typing it :)

See the attachment

On the procedure General TAB, I can specify the page title and I can use a session variable
Looking in the code it is loaded with this line
p_web.MakePage('OrderMasterForm',Net:Web:Form,p_web.site.LoginRequired,p_web.GSV('my_title'),,,)

So I'm hoping to change that to a dynamic quote nr, or an order nr as the user changes the status on the page.



I also possibly created confusion with this line , Ignore this
p_web.ntForm(loc:formname,'setTabHeadingText',0,clip(loc:quote_tab_text))



thanks


Johan


5
Web Server - Ask For Help / Change Page Title - browser tab description
« on: November 29, 2025, 10:11:28 PM »
Hi,

How to update the browser tab heading dynamically as a user changes fields on a form.
eg. change from quote to order , then to change the browser tab description from the quote nr to the order nr


Changing a tab heading I used the following
p_web.ntForm(loc:formname,'setTabHeadingText',0,clip(loc:quote_tab_text))

I see the this line in the webhandler when the page is created 
p_web.MakePage('OrderMasterForm',Net:Web:Form,p_web.site.LoginRequired,p_web.GSV('my_title'),,,)

However cannot find how to update the browser tab


thanks

Johan
















6
Web Server - Ask For Help / Re: Pass a Session Variable as a parameter?
« on: November 25, 2025, 08:20:43 AM »

Hi Jane

Thanks , I do pass p_web into other functions and have that working when it's functions that work with p_web and session variables,
but in this case it's a function that only receives a stringtheory object and then populates the data.

It's unaware of which specific session variable to load or unaware that it's a NTWS

I have it working with a temp stringtheory object, was just looking at it and thinking there was a way to reference the session variable as a stringtheory obect and then pass that in.


thanks

Johan





7
Web Server - Ask For Help / Re: Pass a Session Variable as a parameter?
« on: November 25, 2025, 04:47:44 AM »
Hi,

Sorry had to add, this is how I am doing currently.

my_tmp_st  stringtheory

     MyFunction(my_tmp_st)
     p_web.SSV('session_var',my_tmp_st.GetValue())


Johan




8
Web Server - Ask For Help / Pass a Session Variable as a parameter?
« on: November 25, 2025, 04:33:26 AM »
Hi,

Sure I know this but it's buried in the year end brain fog of too much screen time and not enough down time....
Think I might even have asked this somewhere, sometime, but cannot find the answer. :)


How to pass a session variable to a function.

As I understand session variables are stringtheory objects, so if I have a function like
MyFunction(stringtheory tmpstr)

How do I pass a session variable into that function without using intermediary strings



thanks


Johan








9
Web Server - Ask For Help / Re: NetWebClient - post data?
« on: September 04, 2025, 08:40:55 AM »
Hi Jane

thanks

NetShowSend=>1 is exactly what I was after

thanks

Johan

10
Web Server - Ask For Help / NetWebClient - post data?
« on: September 02, 2025, 10:02:06 PM »
Hi,

How do I check the actual Post request?
Having some issues and want to make sure that all the bits are in the correct places.

Current specific error that I'm getting is that the bearer token is invalid, as far as I can it's good and has not expired.
So want to see what the post data actually looks like, complete with header etc...

thanks

Johan

11
Web Server - Ask For Help / Re: 2Step process - Bearer token - OAuth?
« on: September 01, 2025, 09:38:45 PM »
Hi Jane

Thanks for detailed reply as always!

I'm glad to report after reading your reply and method, it's the route I am busy with.
Feels good to know I am on the right path :)

After reading the OAuth docs, I also went the route of doing my own thing.
I've done quite a few different API's but not the 2 step process.
Just seemed more simple and in control than trying to understand the OAuth process.
I'm almost done, so far so good.

All seems pretty simple, and thanks to NT and the Codewriter takes an enormous amount of time, pain and possible mistakes out of it.

thanks

Johan

12
Web Server - Ask For Help / 2Step process - Bearer token - OAuth?
« on: September 01, 2025, 08:29:09 AM »
Hi,

Looking to get some JSON data from a 3rd party API server tracking , Fedex

I have to request the bearer token using credentials, and then use the returned bearer token to fetch the data.
The bearer token expires after an hour.

Before I dive in and code the 2 steps , this seems to be exactly the same as OAuth.
Am I on the right path?

Or as simple to code the 2 steps?

thanks

Johan









13
Hi Ron

Thanks, that is a very clear explanation.

You have confirmed what I understand it to do with some more information that is very helpful

thanks

Johan


14

Hi,

I have a table update FORM, the master.

On it I have a few buttons that call small popup forms that also update some of the same table fields, the popup form are memory forms.
These fields are sometimes display fields on the master FORM, sometimes not.

It all seems to work and the table fields from the popups are updated and saved, but still testing the process to make sure all is reliable.

The way I undestand is that the Table update form will write the record from the session variables?

Is there anything to follow to make this process 100% reliable?
eg. call a certain sync routine to ensure all is good?

Is there perhaps a webinar or resource that discusses simialr process that will be of use?


thanks

Johan

15
Web Server - Ask For Help / Re: How to debug this slow request?
« on: August 08, 2025, 10:32:16 AM »
Hi Ron

:) Yes have to agree with that.
However it's good to attempt and get things to look as PRO as possible as well as easy as possible

regards

Johan

Pages: [1] 2 3 ... 28