Re: Using Applescript to process WebCatalog functions

This WebDNA talk-list message is from

1998


It keeps the original formatting.
numero = 17701
interpreted = N
texte = Bob Mosebar changed the universe:> I would like to be able to send a commit and close event to WebCatalog > from an AppleScript process. We want our customer to be able to FTP an > updated database, file exported from Filemaker Pro, whenever they get new > information from their sources.Why with Applescript? You can let your customer upload into a special folder and check this folder with WebCat for the existence of a file, whenever a user enters the shop. I am currently working on a procedure which lets my customer upload a new database at any time with any name and blocks the access for all users while the update is running. I used this kind of stuff already with 4D-databases, here is the workflow:If a user enters the shop and an uploaded file is present in the upload-folder: #1 rename the original start-template to entry.tpl_disabled #2 rename a predefined warning-page from entry.tpl_update to entry.tpl #3 send this page, it says Database gets updated, try again in a minute. (any user gets now THIS entry.tpl while it is active...) #4 close the database #5 move it to a backup-folder, set the name to date and time. #6 move the new file to its correct position (and set the original name). #7 rename the warning-page to entry.tpl_update #8 rename the original page back from entry.tpl_disabled to entry.tpl (from now on users get the right entry page again)This is reliable and fast, a customer can use any filename and does not see other files in the shop.Here is an example for the file organization: ---------------------------------------------------------- MyShop => root of the shop template1 template2 templateX entry.tpl => your entry page entry.tpl_upload => your warning-page Products.db => your active database ProductsUpload => ftp-folder for the customer newprices.txt => uploaded file, any name ProductsBackup => folder for old databases 26.05.98_12:31:26.txt => old database 13.05.98_16:21:11.txt => old database 02.04.98_23:05:08 .txt => old database ----------------------------------------------------------If your customer is merely skilled you can give him ftp to the backup folder too - if something goes wrong with the update, he can download the last backup (I believe, he cannot find it right now ;-) and upload it again. And if you want a sophisticated solution you can even make him an admin-interface to shuffle files and a panic-button which restores the most recent database before the last upload...Anyway - the new WebCat plugin does not need AppleScript. You should turn off AppleScript on your webserver, for security and performance... Peter __________________________________________ Peter Ostry - po@ostry.com - www.ostry.com Ostry & Partner - Ostry Internet Solutions Auhofstrasse 29 A-1130 Vienna Austria fon ++43-1-8777454 fax ++43-1-8777454-21 Associated Messages, from the most recent to the oldest:

    
  1. Re: Using Applescript to process WebCatalog functions (Mike Heininger 1998)
  2. Re: Using Applescript to process WebCatalog functions (Peter Ostry 1998)
  3. Re: Using Applescript to process WebCatalog functions (Kenneth Grome 1998)
  4. Re: Using Applescript to process WebCatalog functions (Britt T. 1998)
  5. Re: Using Applescript to process WebCatalog functions (Peter Ostry 1998)
  6. Re: Using Applescript to process WebCatalog functions (Britt T. 1998)
  7. Re: Using Applescript to process WebCatalog functions (Peter Ostry 1998)
  8. Re: Using Applescript to process WebCatalog functions (Britt T. 1998)
  9. Re: Using Applescript to process WebCatalog functions (Peter Ostry 1998)
  10. Re: Using Applescript to process WebCatalog functions (Kenneth Grome 1998)
  11. Re: Using Applescript to process WebCatalog functions (Peter Ostry 1998)
  12. Re: Using Applescript to process WebCatalog functions (Bob Mosebar 1998)
  13. Re: Using Applescript to process WebCatalog functions (Peter Ostry 1998)
  14. Re: Using Applescript to process WebCatalog functions (Peter Ostry 1998)
  15. Re: Using Applescript to process WebCatalog functions (Bob Mosebar 1998)
  16. Re: Using Applescript to process WebCatalog functions (Kenneth Grome 1998)
  17. Re: Using Applescript to process WebCatalog functions (Kenneth Grome 1998)
  18. Re: Using Applescript to process WebCatalog functions (Kenneth Grome 1998)
  19. Re: Using Applescript to process WebCatalog functions (Peter Ostry 1998)
  20. Re: Using Applescript to process WebCatalog functions (Bob Mosebar 1998)
  21. Re: Using Applescript to process WebCatalog functions (Bob Mosebar 1998)
  22. Re: Using Applescript to process WebCatalog functions (Britt T. 1998)
  23. Re: Using Applescript to process WebCatalog functions (Peter Ostry 1998)
  24. Re: Using Applescript to process WebCatalog functions (Kenneth Grome 1998)
  25. Re: Using Applescript to process WebCatalog functions (Peter Ostry 1998)
  26. Re: Using Applescript to process WebCatalog functions (Bob Mosebar 1998)
  27. Re: Using Applescript to process WebCatalog functions (Kenneth Grome 1998)
  28. Re: Using Applescript to process WebCatalog functions (Kenneth Grome 1998)
  29. Re: Using Applescript to process WebCatalog functions (PCS Technical Support 1998)
  30. Re: Using Applescript to process WebCatalog functions (Peter Ostry 1998)
  31. Using Applescript to process WebCatalog functions (Bob Mosebar 1998)
Bob Mosebar changed the universe:> I would like to be able to send a commit and close event to WebCatalog > from an AppleScript process. We want our customer to be able to FTP an > updated database, file exported from Filemaker Pro, whenever they get new > information from their sources.Why with Applescript? You can let your customer upload into a special folder and check this folder with WebCat for the existence of a file, whenever a user enters the shop. I am currently working on a procedure which lets my customer upload a new database at any time with any name and blocks the access for all users while the update is running. I used this kind of stuff already with 4D-databases, here is the workflow:If a user enters the shop and an uploaded file is present in the upload-folder: #1 rename the original start-template to entry.tpl_disabled #2 rename a predefined warning-page from entry.tpl_update to entry.tpl #3 send this page, it says Database gets updated, try again in a minute. (any user gets now THIS entry.tpl while it is active...) #4 close the database #5 move it to a backup-folder, set the name to date and time. #6 move the new file to its correct position (and set the original name). #7 rename the warning-page to entry.tpl_update #8 rename the original page back from entry.tpl_disabled to entry.tpl (from now on users get the right entry page again)This is reliable and fast, a customer can use any filename and does not see other files in the shop.Here is an example for the file organization: ---------------------------------------------------------- MyShop => root of the shop template1 template2 templateX entry.tpl => your entry page entry.tpl_upload => your warning-page Products.db => your active database ProductsUpload => ftp-folder for the customer newprices.txt => uploaded file, any name ProductsBackup => folder for old databases 26.05.98_12:31:26.txt => old database 13.05.98_16:21:11.txt => old database 02.04.98_23:05:08 .txt => old database ----------------------------------------------------------If your customer is merely skilled you can give him ftp to the backup folder too - if something goes wrong with the update, he can download the last backup (I believe, he cannot find it right now ;-) and upload it again. And if you want a sophisticated solution you can even make him an admin-interface to shuffle files and a panic-button which restores the most recent database before the last upload...Anyway - the new WebCat plugin does not need AppleScript. You should turn off AppleScript on your webserver, for security and performance... Peter __________________________________________ Peter Ostry - po@ostry.com - www.ostry.com Ostry & Partner - Ostry Internet Solutions Auhofstrasse 29 A-1130 Vienna Austria fon ++43-1-8777454 fax ++43-1-8777454-21 Peter Ostry

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

syntax question, not in online refernce (1997) Sorting error (1997) problems with WebCat-Plugin () Re1000002: Setting up shop (1997) Line items in table cells (1997) [ShowNext] (1997) [searchString] (1997) Bug or syntax error on my part? (1997) Remote administration (1998) Attention all list readers (1997) [WebDNA] Paypal Sandbox TCPConnect (2012) StoreBuilder Shopping Cart (2000) shipping costs (2000) RAM variables (1997) SV: Send massmail (2000) God's Truth (1998) emailer (1997) Authenticate (1997) Problem (1997) textarea to page display (1998)