ULX

Author Topic: ULX log viewer  (Read 36659 times)

0 Members and 3 Guests are viewing this topic.

Offline trurascalz

  • Newbie
  • *
  • Posts: 13
  • Karma: 1
ULX log viewer
« on: March 16, 2014, 05:10:04 AM »
You probably won't know me but I have been here a while but didn't contribute much, but i made this online log viewer for ULX (Suppose you can use it for other logs and i made a advance dupe version aswell ((But thats private)) ).  I did this because i saw a few communities with it and wanted to attempt it myself like http://www.noxiousnet.com/logs/. Hopefully you find it useful as i did

Features:
  • View text files within a folder
  • Stops people using the ../ to gain access to other folders

Not really much to it, you can view  a demo here -http://alexsavory.me/projects/ulxlogs/

Download it here: https://github.com/trurascalz/ULXLogviewer

Installation instructions:
  • Upload to web space
  • Fill in config.php

Notes:
Sometimes it doesn't like working with GSP's with the folder structure:
Method to try to fix
If it doesn't load your folder, try breaking the filepath into segments and try that so if your file path was
/127.0.0.1_27015/garrysmod/data/ulx_logs

try, /127.0.0.1_27015/ and see if that loads the files in there then try /127.0.0.1_27015/garrysmod/ and see if it loads again, etc

http://stackoverflow.com/questions/24085569/why-ftp-fget-is-returning-bind-failed-permission-denied-13-in-php Enabling passive ftp may also fix problems.
-----
This was a quick whip together and there's probably a better way to approach it.
I believe I blocked any loopholes, but just tell me if you can break it and ill fix it.
Folder path requires a leading / eg.
/gmod/data/ulx/ulx_logs/
« Last Edit: June 10, 2016, 02:45:45 PM by trurascalz »

Offline Bytewave

  • Respected Community Member
  • Hero Member
  • *****
  • Posts: 718
  • Karma: 116
  • :)
    • My Homepage
Re: ULX log viewer
« Reply #1 on: March 16, 2014, 08:23:10 AM »
Hmmm... Interesting system...
You used Bootstrap for the demo- is this default?

Also, how easy would this be to modify to access another folder?
bw81@ulysses-forums ~ % whoami
Homepage

Offline trurascalz

  • Newbie
  • *
  • Posts: 13
  • Karma: 1
Re: ULX log viewer
« Reply #2 on: March 16, 2014, 08:35:55 AM »
Yeah bootstrap is built into it, the system will take any folderpath its set in the config, so you can set it to darkrp logs or summat, it will parse anything in a text file

Offline Bytewave

  • Respected Community Member
  • Hero Member
  • *****
  • Posts: 718
  • Karma: 116
  • :)
    • My Homepage
Re: ULX log viewer
« Reply #3 on: March 16, 2014, 10:11:33 AM »
Yeah bootstrap is built into it, the system will take any folderpath its set in the config, so you can set it to darkrp logs or summat, it will parse anything in a text file
Sweet!
I applaud your use of TWBS; it's always been a personal preference of mine, being OCD and stuff... :P
I'll check out the system in action later. I could really use this for a Pointshop logging system I made myself. :D
bw81@ulysses-forums ~ % whoami
Homepage

Offline Eccid

  • Full Member
  • ***
  • Posts: 115
  • Karma: 11
  • Hey, come on... We just met...
    • Terror Abound! Steam Group
Re: ULX log viewer
« Reply #4 on: March 16, 2014, 05:23:11 PM »
I tried this out and it failed to load once it was directed to my logs folder. It just sits on loading indefinitely.

being OCD and stuff... :P
Yeah, ok.

Offline Bytewave

  • Respected Community Member
  • Hero Member
  • *****
  • Posts: 718
  • Karma: 116
  • :)
    • My Homepage
Re: ULX log viewer
« Reply #5 on: March 16, 2014, 05:26:54 PM »
Yeah, ok.
Please don't bring this argument up again; the more it happens, the more fires start to cripple the forums...

I tried this out and it failed to load once it was directed to my logs folder. It just sits on loading indefinitely.
Does your GSP allow external access to files? There's always a possibility they block incoming connections that aren't on port 27015 (or whatever your Source port is).
bw81@ulysses-forums ~ % whoami
Homepage

Offline Eccid

  • Full Member
  • ***
  • Posts: 115
  • Karma: 11
  • Hey, come on... We just met...
    • Terror Abound! Steam Group
Re: ULX log viewer
« Reply #6 on: March 16, 2014, 06:46:45 PM »
I figured out my issue.

Please don't bring this argument up again; the more it happens, the more fires start to cripple the forums...

Then stop saying it, man. It's not quirky and fun.

Offline eliman

  • Newbie
  • *
  • Posts: 14
  • Karma: 0
Re: ULX log viewer
« Reply #7 on: March 19, 2014, 01:59:15 PM »
Don't think this works with SFTP users, it may be a mistake but i'm 90% sure its not. Anyone else able to confirm this?

Offline trurascalz

  • Newbie
  • *
  • Posts: 13
  • Karma: 1
Re: ULX log viewer
« Reply #8 on: March 19, 2014, 02:00:28 PM »
Works on a totally different function

http://www.php.net/manual/en/function.ssh2-sftp.php

Offline Slayer42

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
Re: ULX log viewer
« Reply #9 on: April 20, 2014, 09:54:04 AM »
Got this on a server i'm superadmin on and i've done everything that is in the comments and in the post to fix errors but I still get a really long loading and all it shows is :


Offline trurascalz

  • Newbie
  • *
  • Posts: 13
  • Karma: 1
Re: ULX log viewer
« Reply #10 on: April 20, 2014, 10:28:06 AM »
If there are alot, of files it will take ages to load.

Method to try to fix
If it doesn't load your folder, try breaking the filepath into segments and try that so if your file path was
/127.0.0.1_27015/garrysmod/data/ulx_logs

try, /127.0.0.1_27015/ and see if that loads the files in there then try /127.0.0.1_27015/garrysmod/ and see if it loads again, etc
-----

Offline Tommo1590

  • Newbie
  • *
  • Posts: 37
  • Karma: 1
Re: ULX log viewer
« Reply #11 on: June 05, 2014, 11:26:58 PM »
Got this on a server i'm superadmin on and i've done everything that is in the comments and in the post to fix errors but I still get a really long loading and all it shows is :



Same Issue here..

Code: [Select]
Status

Folder: /81.19.208.19_27055/garrysmod/data/ulx_logs/
Successfully accessed log folder.

However not showing any of the log files.

Offline JamminR

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 8096
  • Karma: 390
  • Sertafide Ulysses Jenius
    • Team Ulysses [ULib/ULX, other fine releases]
Re: ULX log viewer
« Reply #12 on: June 06, 2014, 02:11:05 PM »
Geez, no need to post someone elses huge image in a reply quote.
Tommo, I can't even get to your http://81.19.208.19:27055/garrysmod/data - connection is reset by peer.
Do you have proxy/firewall systems that might prevent it?
It's a good indication that if I can't reach it, neither would the lua code. (Not always of course, depending on firewall configs)
"Though a program be but three lines long, someday it will have to be maintained." -- The Tao of Programming

Offline Tommo1590

  • Newbie
  • *
  • Posts: 37
  • Karma: 1
Re: ULX log viewer
« Reply #13 on: June 08, 2014, 02:19:13 PM »
http://81.19.208.19:27055/garrysmod/data Isn't a public accessible link via browser.
The script uses the PHP FTP Functions so its logging into the server ftp using the ftp not by looking for the files by link.

The script just wont show the log files which I assume is something to do with the ftp_nlist function which I haven't figured out yet.  :(

Offline Slayer42

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
Re: ULX log viewer
« Reply #14 on: June 16, 2014, 02:26:14 AM »
I would also like to comment and say that my issue was not resolved and I told the owner what you suggested and he said it did not work :

http://sotairygaming.com/logs