Parsing commandline string
-
- Posts: 13
- Joined: Fri Oct 30, 2009 5:05 pm
Parsing commandline string
I was wondering how the command line string is parsed?
This one -> Commandline arguments
These commandline options can be edited by the user.
In a batch file i can do the following:
log=..\ucclogs\logs_%DATE%_%TIME:~0,2%-%TIME:~3,2%-%TIME:~6,2%.log
to date and time stamp the files.
How can i acheive this through the command line string. Is it parsed by php for commands or variables? or just treated as a string?
Many thanks.
This one -> Commandline arguments
These commandline options can be edited by the user.
In a batch file i can do the following:
log=..\ucclogs\logs_%DATE%_%TIME:~0,2%-%TIME:~3,2%-%TIME:~6,2%.log
to date and time stamp the files.
How can i acheive this through the command line string. Is it parsed by php for commands or variables? or just treated as a string?
Many thanks.
-
- Site Admin
- Posts: 3612
- Joined: Thu Apr 20, 2006 2:54 pm
- Location: America's Heartland
- Contact:
Re: Parsing commandline string
I myself have not personally tested this, but I'd imagine it might work. I'd test but I don't have the capability atm. Can you try it out and let me know?
Masher
-----------
Please do not PM me unless asked to! We are a small company. If you have an issue or question it would be best to post it in the forums where it can help others in the future.
NEW Join our Discord!
-----------
Please do not PM me unless asked to! We are a small company. If you have an issue or question it would be best to post it in the forums where it can help others in the future.
NEW Join our Discord!
-
- Posts: 13
- Joined: Fri Oct 30, 2009 5:05 pm
Re: Parsing commandline string
I've tried the line 'log=..\ucclogs\logs_%DATE%_%TIME:~0,2%-%TIME:~3,2%-%TIME:~6,2%.log' but that doesnt work
-
- Site Admin
- Posts: 3612
- Joined: Thu Apr 20, 2006 2:54 pm
- Location: America's Heartland
- Contact:
Re: Parsing commandline string
I'll implement this in the next version.
Masher
-----------
Please do not PM me unless asked to! We are a small company. If you have an issue or question it would be best to post it in the forums where it can help others in the future.
NEW Join our Discord!
-----------
Please do not PM me unless asked to! We are a small company. If you have an issue or question it would be best to post it in the forums where it can help others in the future.
NEW Join our Discord!
-
- Posts: 13
- Joined: Fri Oct 30, 2009 5:05 pm
Re: Parsing commandline string
Thanks Masher.
Once this issue is fixed, then i think we will buy a license and install it on our root server. It looks really good!
Once this issue is fixed, then i think we will buy a license and install it on our root server. It looks really good!
-
- Site Admin
- Posts: 3612
- Joined: Thu Apr 20, 2006 2:54 pm
- Location: America's Heartland
- Contact:
Re: Parsing commandline string
As of version 1.31 (just released it), if the panel finds %DATE% or %TIME% in either commandline (user or hidden), it'll replace them with the appopriate text.
The following should do the trick for you:
The following should do the trick for you:
Code: Select all
log=..\ucclogs\logs_%DATE%_%TIME%.log
Masher
-----------
Please do not PM me unless asked to! We are a small company. If you have an issue or question it would be best to post it in the forums where it can help others in the future.
NEW Join our Discord!
-----------
Please do not PM me unless asked to! We are a small company. If you have an issue or question it would be best to post it in the forums where it can help others in the future.
NEW Join our Discord!
-
- Posts: 13
- Joined: Fri Oct 30, 2009 5:05 pm
Re: Parsing commandline string
Sorry to dig up such an old thread but I just updated to the latest version of UGCC and the %DATE% and %TIME% parsing doesn't seem to be working?
My command line is: log=..\logs\log_main_%DATE%_%TIME%.log but the file name is 'log_main_%DATE%_%TIME%.log'
The server is currently set to German language, so I don't know if that's causing any problems with the parsing of the % characters? We can't change it back to English for another 2 weeks yet
My command line is: log=..\logs\log_main_%DATE%_%TIME%.log but the file name is 'log_main_%DATE%_%TIME%.log'
The server is currently set to German language, so I don't know if that's causing any problems with the parsing of the % characters? We can't change it back to English for another 2 weeks yet
-
- Site Admin
- Posts: 3612
- Joined: Thu Apr 20, 2006 2:54 pm
- Location: America's Heartland
- Contact:
Re: Parsing commandline string
That's odd. Will double check to make sure it's not an issue with the code.
Masher
-----------
Please do not PM me unless asked to! We are a small company. If you have an issue or question it would be best to post it in the forums where it can help others in the future.
NEW Join our Discord!
-----------
Please do not PM me unless asked to! We are a small company. If you have an issue or question it would be best to post it in the forums where it can help others in the future.
NEW Join our Discord!
-
- Site Admin
- Posts: 3612
- Joined: Thu Apr 20, 2006 2:54 pm
- Location: America's Heartland
- Contact:
Re: Parsing commandline string
It was an issue with the panel, will be fixed in the next update. Thanks!
Masher
-----------
Please do not PM me unless asked to! We are a small company. If you have an issue or question it would be best to post it in the forums where it can help others in the future.
NEW Join our Discord!
-----------
Please do not PM me unless asked to! We are a small company. If you have an issue or question it would be best to post it in the forums where it can help others in the future.
NEW Join our Discord!
-
- Posts: 13
- Joined: Fri Oct 30, 2009 5:05 pm
Re: Parsing commandline string
Cool, thanks. I look forward to the update
-
- Posts: 13
- Joined: Fri Oct 30, 2009 5:05 pm
Re: Parsing commandline string
Sorry, have to dig this one up again.
I purchased a new licence back in July 2014 and the issue still wasn't resolved. Looking at the post above from Masher it should be fixed now. However as my licence has expired I can't update. Any chance to get a guarantee that its fixed in the new version and maybe a discount on the new licence? We are about to re-install the whole server due to a HDD issue so it would be a good time to update.
Many thanks,
Andy
I purchased a new licence back in July 2014 and the issue still wasn't resolved. Looking at the post above from Masher it should be fixed now. However as my licence has expired I can't update. Any chance to get a guarantee that its fixed in the new version and maybe a discount on the new licence? We are about to re-install the whole server due to a HDD issue so it would be a good time to update.
Many thanks,
Andy
-
- Site Admin
- Posts: 3612
- Joined: Thu Apr 20, 2006 2:54 pm
- Location: America's Heartland
- Contact:
Re: Parsing commandline string
Yes it's fixed, confirmed working earlier this week when assisting another customer.
I can give you a demo license if you'd like to test it out
I can give you a demo license if you'd like to test it out
Masher
-----------
Please do not PM me unless asked to! We are a small company. If you have an issue or question it would be best to post it in the forums where it can help others in the future.
NEW Join our Discord!
-----------
Please do not PM me unless asked to! We are a small company. If you have an issue or question it would be best to post it in the forums where it can help others in the future.
NEW Join our Discord!
-
- Posts: 13
- Joined: Fri Oct 30, 2009 5:05 pm
Re: Parsing commandline string
It's ok.
Are you able to renew my current licence at the upgrade price? It expired last year and i didn't get the newer version with the fix before it expired.
Are you able to renew my current licence at the upgrade price? It expired last year and i didn't get the newer version with the fix before it expired.