Hi All,
Can anyone can point me the way to write a audit log in livecode server which host in hostm.com ?
I try to use the following method, but I don't know where is the correct path to save the file and don't know whether it is work or not.
function httpsapi.init
addlog($_post_raw)
end httpsapi.init
on addlog prequest
put "some data" into url "file:../hostname.com/textfile.txt" // which is failed
put specialfolderpath("Temporary") & "textfile.txt" into alogfile
open file alogfile for append
wirte the english date & tab & preuest & return to file alogfile
close file alogfile
end addlog
Regards
Terry Ho
Audit log in livecode server
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
-
- VIP Livecode Opensource Backer
- Posts: 9838
- Joined: Sat Apr 08, 2006 7:05 am
- Location: Los Angeles
- Contact:
Re: Audit log in livecode server
The best place to write logs will be determined by what is reading them. How will you retrieve the logs, how frequently, and how will they be used?
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
Re: Audit log in livecode server
Hi,
What I want to do is for two purpose:
1. Debug purpose, want to know what data is receive and send out.
2. For long term, it may create a audit log to know where is the request from, what they request or if discover has illegal activity, it may block the ip or info the web admin and etc.
Regards
Terry Ho
What I want to do is for two purpose:
1. Debug purpose, want to know what data is receive and send out.
2. For long term, it may create a audit log to know where is the request from, what they request or if discover has illegal activity, it may block the ip or info the web admin and etc.
Regards
Terry Ho
-
- VIP Livecode Opensource Backer
- Posts: 9838
- Joined: Sat Apr 08, 2006 7:05 am
- Location: Los Angeles
- Contact:
Re: Audit log in livecode server
Shared host:
Any folder in your home folder, above your web root.
Dedicated/VPS:
/var/log/ is the standard place for logs. You could create a folder there, and assign a group with write permissions to it, and set permissions for your process as a member of that group.
Any folder in your home folder, above your web root.
Dedicated/VPS:
/var/log/ is the standard place for logs. You could create a folder there, and assign a group with write permissions to it, and set permissions for your process as a member of that group.
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
Re: Audit log in livecode server
Hi ,
Thanks your help. I find the way to make it, which is use the current stack path.
Regards
Terry Ho
Thanks your help. I find the way to make it, which is use the current stack path.
Regards
Terry Ho