Sign up on the Revelation Software website to have access to the most current content, and to be able to ask questions and get answers from the Revelation community

At 21 FEB 1999 12:09:38PM Matt Sorrell wrote:

Hello again,

When it rains, it pours.

I've got an HTML form working except for one bug. If I type in an existing record key, and click read, it reads beautifully.

If, from a blank form, I enter a new record and click save, it saves

beautifully.

However, if I type in an existing key, read the record into the form, modify the record, and then click my save button, all it does is re-read the existing record instead of writing my changes back to disk.

I can't figure it out for the life of me.

Matt Sorrell

msorrell@movgal.com

"The views, opinions, and judgements expressed in this message are solely

those of the author. The message contents have not been reviewed or

approved by Movie Gallery."


At 25 FEB 1999 10:36AM Stephen Revelation wrote:

Matt,

Have you checked to see if the same is happening in your OI stand-alone copy? I had an HTML form with three fields (ID, Name and DOB). I created a record for ID 99 and Wrote (#1 below) it. I Read (#2) 99 then changed the Name field (Mary-]Marianne), Wrote (#3) it again, and Read (#4) it again to view the updated record. Below is my INET_GATEWAY for the above four processes:

#4) /INET_REPOS?ID_NO=99&NAME=&D_O_B=&$SUBMIT=READ&FORM_ID=DAVID …

#3) /INET_REPOS?ID_NO=99&NAME=Marianne&D_O_B=04/15/74&$SUBMIT=WR …

#2) /INET_REPOS?ID_NO=99&NAME=&D_O_B=&$SUBMIT=READ&FORM_ID=DAVID …

#1) /INET_REPOS?ID_NO=99&NAME=Mary&D_O_B=04/15/74&$SUBMIT=WRITE& …

Your INET_GATEWAY should look like this. Have you changed Inet_FormWrite or Inet_FormRead? These are stored procedures.

Did you follow the walkthrough available on our website? If not the link to it is here

Post any information you can provide and I'll keep an eye out.

Stephen Revelation


At 25 FEB 1999 05:40PM Matt Sorrell wrote:

Stephen,

Here is the really odd thing about it. If I enter a brand new record using the web form, I can read and write it at will. But, as soon as I read in a record that already existed in the SYSKNOWLEDGE table, for instance R29, then all of my buttons stop working and all they do is refresh the form with original contents. Also, the last event you see in INET_GATEWAY was the read event for the original record.

The only way to get out of this loop is to return to the original URL where the DOC_ID is specified. Then, it will continue to work until you read in a original record.

BTW, I'm not using native OI tables. I attached the SYSKNOWLEDGE table from my AREV 3.12 environment, and aliased it under another name. Also, any updates that I do from within OI and within AREV are correctly reflected in all instances. It is only the Web Form that is "freaking out".

Matt


At 26 FEB 1999 04:32AM Oystein Reigem wrote:

Matt,

Here is the really odd thing about it. If I enter a brand new record using the web form, I can read and write it at will. But, as soon as I read in a record that already existed in the SYSKNOWLEDGE table, for instance R29, then all of my buttons stop working and all they do is refresh the form with original contents. Also, the last event you see in INET_GATEWAY was the read event for the original record.

But you don't see the database read itself in INET_GATEWAY. When I check my own INET_GATEWAY what I see is some of the data from my request. It seems to be Request (the name of the Inet function you call) and Request (the query parameters).

Which Inet function is it you see? If it's Inet_FormRead, or some read function of your own, there must be something wrong with your form.

But perhaps the problem rather has to do with something I have been wondering about myself. I really want my web app to be read only, and I make my forms by hand, but I have tried to use the HTML Publisher to make read/write forms. And with those forms there is no Inet function name in ACTION. The names are in the VALUEs of the Read and Write SUBMIT buttons. When I press the Read or Write button I see no Inet function name in INET_GATEWAY. What shows is just "/?". So how exactly is it OICGI knows which Inet function to call (Inet_FormRead or InetFormWrite)? Picks it up somehow from the query parameters???

It's frustrating that INET_GATEWAY doesn't show more information than 60 characters or so for each request. One cannot see much of the query parameters. It isn't easy to use it for debugging. There should perhaps have been a Detail button you could use to study the last request in detail. But I guess if I were you I might e.g use the Inet_Security function, which is called in advance of every Inet function, to dump each request to a text file and study them in detail.

- Oystein -


At 26 FEB 1999 04:51AM cpates@sprezzatura.com,[url=http://www.sprezzatura.com]Sprezzatura Ltd[/url] wrote:

Hi Oystein,

So how exactly is it OICGI knows which Inet function to call (Inet_FormRead or InetFormWrite)? Picks it up somehow from the query parameters???

Here's my theory :-)

When your form is submitted all the elements in the form are gathered up by the browser and sent to the server. However, if you have multiple SUBMIT buttons only the one that was clicked gets sent.

OICGI ( or INET_GATEWAY…not sure which ) looks at the VALUE of the submit button and then finds a HIDDEN control with the same name. It then uses the VALUE in the HIDDEN control as the name of the request to call.

so….

If you enter 1 in the CODE box and click the Read button the browser should send something like this (as it's a POST method it gets sent as an attachment but let's not get into that here :-):

CODE=1&DESCRIPTION=&$SUBMIT=Read&Read=INET_FORMREAD&Write=INET_FORMWRITE

Which gets translated to:

INET_FORMREAD?CODE=1&DESCRIPTION=&Read=INET_FORMREAD&Write=INET_FORMWRITE

Or something similiar. :-)

cpates@sprezzatura.com

Sprezzatura Ltd

World Leaders in all things RevSoft


At 26 FEB 1999 05:00AM cpates@sprezzatura.com,[url=http://www.sprezzatura.com]Sprezzatura Ltd[/url] wrote:

Matt,

Just a thought, but what are the cache settings on your browser? Is it set to re-visit the page with every request? Have you tried putting in the no-cache META tags in the HTML? (I believe IE ignores them but Navigator is OK)

As Stephen and Oystein say, you should be seeing activity in INET_GATEWAY if your form is making a request. The only reason I can think of that it wouldn't is if the pages were cached and your browser was using those instead.

cpates@sprezzatura.com

Sprezzatura Ltd

World Leaders in all things RevSoft


At 26 FEB 1999 06:56AM Oystein Reigem wrote:

Carl,

Your theory certainly makes sense. Thanks!

- Oystein -


At 26 FEB 1999 10:44AM Oystein Reigem wrote:

Carl,

While on the subject - do you know if one can have images instead of dull html buttons for submit buttons? Without using JavaScript?

- Oystein -


At 26 FEB 1999 12:06PM cpates@sprezzatura.com,[url=http://www.sprezzatura.com]Sprezzatura Ltd[/url] wrote:

Hi Oystein,

Sorry, can't think of one, the TYPE=SUBMIT" of in INPUT element ignores the SRC attribute, and the tags don't have an SRC attribute….

cpates@sprezzatura.com

Sprezzatura Ltd

World Leaders in all things RevSoft


At 01 MAR 1999 02:13PM Oystein Reigem wrote:

Now what do I do if I have several buttons with the same Inet function? How can the function know which button was pressed? I have tried to append a query parameter in the VALUEs of the HIDDEN elements:

but that fails miserably.

What I need this for? I have html forms for queries against tables (but it could just as well have been a data entry forms). I want the forms to have index lookup capabilities. For each field with index lookup I have a button beside the field. When I press a button I want my own Inet_IndexLookup function to run. But the function needs to know which field to look up! The only solution I can see is to make specific functions for each field.

Help…

- Oystein -


At 02 MAR 1999 05:21AM cpates@sprezzatura.com,[url=http://www.sprezzatura.com]Sprezzatura Ltd[/url] wrote:

Oystein,

I know you want to avoid JavaScript but you really could get the functionality you need with a few simple lines of code.

eg. something like ( from memory :-)

onClick=document.location=./INET_INDEXTHING?FIELD=NAME'"

The code needed has been in JavaScript since v1.0 so it should be supported by most browsers including Navigator 2.0.

Otherwise I'm not sure of how you could acheive what you need without it….

FWIW

cpates@sprezzatura.com

Sprezzatura Ltd

World Leaders in all things RevSoft


At 02 MAR 1999 10:09AM Oystein Reigem wrote:

Carl,

I'm convinced. I'll go for JS. I.e I knew I could do it with very simple scripting, but you not knowing of a non-script alternative is the final nail in the coffin for my non-JS policy.

- Oystein -

View this thread on the forum...

  • third_party_content/community/commentary/forums_nonworks/cfa425c3c7b48c648525671f005e4449.txt
  • Last modified: 2023/12/28 07:40
  • by 127.0.0.1