NetTalk Central
NetTalk Web Server => Web Server - Ask For Help => Topic started by: astahl on November 21, 2014, 05:23:26 AM
-
Hi,
I have a NetWebPage that is being called from an outside source to download a user specific file. If the file was not created for them how can I return back to them a message like "File not available, try later"?
Ashley
-
Hi Ashley,
in the page you can do a
p_web.SendError('503','File Not yet available','the file is not available yet, try again later')
and then do a return.
the exact code to use is somewhat up to you - there's no HTML reply code that matches this situation exactly - but there's a discussion on codes here;
http://stackoverflow.com/questions/9794696/best-http-status-code-in-rest-api-for-not-ready-yet-try-again-later
Of course, you could just returna page that says "File is not yet ready".
cheers
Bruce
-
Thanks Bruce