Web Enabled forms

I have created a form that is supposed to filled out with a web browser. I am not sure why I am getting an error tring to display it in the browser. I have 2 versions of this form one for the broswer and one for the client(with/without javascript) the client version displays fine. It is not like I am using some crazy javascript on the browser version. It is the same script to display my menus that I am using on the rest of the site. I have gone into the properties of the web version and allowed access to public access users. I have also added a user called Anonymous and given that user write privileges.

Subject: It would really help if you told us what kind of error you are getting.

Subject: RE: It would really help if you told us what kind of error you are getting.

I am getting the http 500 error when displaying the form. I am not sure why.

Subject: RE: It would really help if you told us what kind of error you are getting.

Error 500 – internal server error – has nothing to do with your Javascript. The error is happening on the server, and the server doesn’t try to execute your Javascript. Chances are the problem is that there’s a field on the form whose Value formula (if computed) or Default or keyword formula (if editable) is producing an error result.

http://www-1.ibm.com/support/docview.wss?rs=899&uid=sim2407c49349e4bd4fb85256cc300008cdc gives another possible explanation.

Subject: Form works. but doesn’t save

I can now display the form but it doesn’t save the document. I am stil getting the Error 500 – internal server error.I only have 1 field on the form that is computed, that is my $$Return field. it’s syntax is “[http://www.theurl.com]”. The rest of my field are editable with no default value accept 2. Their values are Deleted/“NO” and docread/“Not Read”. (fieldname/“value”)

I also have a few checkboxes with no default. I use window.document.forms[0].submit(); in the web javascript of a button to submit my form and the form WebQuerySave event I call and agent that has the following formula.

@MailSend(“emailaddress”;“”;“”;“New Airport Comment”;“Here is a new comment from the website.”;“”;[IncludeDoclink]);

SELECT ((Form = “airport_commentsNo”))

I am really lost. Not sure why this isn’t working.

Subject: RE: Form works. but doesn’t save

I suspect the WebQuerySave agent is the source of your problem; this is supposed to be a LotusScript agent, not macro. While sending a little email in LotusScript isn’t a one-line function, it’s not that hard to do.

If you want to execute macro functions when the form is being saved, you can do this more efficiently using a function in a computed for display field on the form, perhaps in conjunction with @If(@IsDocBeingSaved – execute the formula after validation.

However, the @MailSend function (and the LotusScript equivalent) are tricky to use in web applications in general, because there’s the question of whether the server will allow this user (or this non-user, if they’re not signed in) to send email.

I suggest that there’s probably no need to make the user wait while you send this email, in any case. Why not just use a scheduled server agent instead? Send a newsletter every now and then – who needs to receive a separate email for every comment entered? You might also think about including the subject in the email subject and the text of the comments in the email body, to save the recipient the trouble of clicking the link each time.

Subject: Web Enabled forms

You should establish why you have two versions of this Form? There is no need to have two versions, unless you are using them for different purposes, which I doubt.

Next, on the–one combimed Form–you should have a look at the Database Design (first tab) you should have the following settings:

  • Use Javascript when generating pages

On the Form Design (second tab) you should have the following settings:

  • Generate HTML for all fields

Subject: RE: Web Enabled forms

I am using 2 versions of the form because the javascript menus don’t work in the client. They throw exception, so to avoid this I have create a second version of the form for the client without the javascript menu. And I have done everything you suggested. Still nothing.

Subject: RE: Web Enabled forms

[On the Form Design (second tab) you should have the following settings:

  • Generate HTML for all fields"]

Unless you would like your form to be both insecure and considerably larger
than it needs to be, do not turn on this property. It is only in relatively
obscure cases of sophisticated Javascript automation that this is necessary,
and even then, there are much better ways to accomplish the goal.

Subject: *Agreed