Jump to content

Stupid FileMaker Tricks


This topic is 8077 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Don't ask why, but I need to insert pauses of variable lengths after submit requests in a sequence of pages. I have noodled around with javascript solutions but the syntax is impossible. Before I get further on down that road, does any one have a suggestion for inserting the pauses using cdml. Loops perhaps?

Link to comment
Share on other sites

Well, first I looked here ... and found this ...

I'm not a CDML guy, but could your Submit automatically insert a random number of mm:ss into a time field? Then you could return a layout with the contents of that field in a form field, and count it down with the above js? ... not sure how you envision using this. I'll let the online experts take it from here.

Link to comment
Share on other sites

Hey Guys

Fitch - I thought about that, or at least something similar. I thought about using an intervening page that said please wait and paused for a set amount of time. It's easy to make a timed redirect type thing using canned javascript. But....since you have to pass at least someinformation from that pause page to filemaker - CDML thing - that solution simply moves my current problem to another page.

The bottom line is that there has to be a way to execute the appropriately named submit request automatically.

I'm afraid that the only way to do this to write the javascript - with the setTimeout function - so that it creates a function that instructs the browser to pause, name the submit button - Name = "-edit" - and then pass the submit request. Maybe this can be done using a URL to pass all the info to FM.

Garry - I'll definitely share the solution if/when I arive at one.

Link to comment
Share on other sites

An intervening page with a meta tag might do what you need.

The code looks something like this:

code:


<HEAD>

<META HTTP-EQUIV="refresh" content = " 5; URL=FMPro?-DB=File.fp5&-Format=Page.html&-View">

</HEAD>

The number 5 in the code is the time of the pause in seconds. You should be able pass other information to the DB within the tag.

Hope this helps

Link to comment
Share on other sites

SL - Thanks for the tip. To be quite honest, I don't know what meta tags are or what they do. But I'll try your solution.

Keith - in this case I am using the solution to perform an experiment in which people are led to believe they are in a chatroom. The point of the pause is to make it seem like the participant is waiting for the other -non-existent- participants to finish. When the subjects' response is 1st out of five they wait a long time, when they are 5th there will be no delay. The result file returns the participants contribution plus display fields containing the 4 fake responses.

For this particular solution participants are tested one at a time, so there can be no crossing of the lines. If this were one the web for anyone to do, the javascript solution would have the advantage of pausing before the submit.

[ March 04, 2002, 10:23 PM: Message edited by: Dr.J. ]

Link to comment
Share on other sites

Thanks for the info Dr. J. Knowing the scenario is limited eliminates that concern.

I recommend a search engine -> "meta". I think it was a link to vancouver which was most helpful to me.

The redirect page will display during the pause and it can have a hard coded message to the client and other junk.

[ March 05, 2002, 08:04 AM: Message edited by: Keith M. Davie ]

Link to comment
Share on other sites

I might add that the meta refresh is part of the solution to a problem which one can encounter from a client who creates a new record and on the success.htm clicks the browser's reload or refresh button. Without a meta refresh this will allow a second (etc.) record to be created containing the same data. With the meta refresh you change the action from a -new to a -find. Then a reload from success.htm merely performs a find.

[ March 05, 2002, 08:10 AM: Message edited by: Keith M. Davie ]

Link to comment
Share on other sites

SL... and Gary - The code below works like a charm. Thanks SL... Note that if the pause occurs in a sequence of edits, the recID must be passed and that requirees an -edit action, not a -view.

Sadly, my IPNetSentry packet inspection for FM hacks is triggered by this. I have to talk to the guys at sustainable softworks about tweaking the program. For those who care, I can get IPNetSentry to trigger on the FMPro? code, and even the -db= code, but nother farther down the line. Ideally it would screen for stuff like -raw, which is usually farther into the packet. Should be doable for them.

<META HTTP-EQUIV="refresh" CONTENT=" 5; URL=FMPro?-DB=xxx_.fp5" &-lay=web &-FORMAT=/fff/fff/xxx.html&-RecID=[FMP-currentrecid]&-edit">

Link to comment
Share on other sites

This topic is 8077 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.