Author Topic: MOTD ?  (Read 4680 times)

0 Members and 1 Guest are viewing this topic.

Offline ILIkeTrainZ

  • Newbie
  • *
  • Posts: 2
  • Karma: 0
MOTD ?
« on: February 26, 2014, 01:28:35 AM »
hi evreyone.
i am not that great at PHP and html so i need your help.

I am making an motd and its waaay not close to being finished (my motd:  forest-craft.nl/garrysmod/motd.php
what i'm trying to show on it is The connecting players profile Name and image, steamID .
the map there is currently being plyed on and the status of downloading
now i tryd some PHP codes but they dont seem to work.
can somone please explain me how to do it?

_
trainz

EDIT:
Here is the code
public_html/garrysmod/motd.php
Code: [Select]
<html>
<body bgcolor=#dbdbdb>
<div style="text-align: center;">
<div style="width: 80%; margin: 0px auto; border: 10px solid #c9d6e4; background-color: #ededed; padding: 10px; font-size: 12px; font-family: Tahoma; margin-top: 30px; color: #818181; text-align: left;">
<div style="font-size: 30px; font-family: impact; width: 100%; margin-bottom: 5px;">Welcome to canned TTT
Here is some useful information: </div>
<br>
Our server has active staff and rulebreakers get big punishments!<br>
U.<br>
<br>
<h2>Rules:</h2>
<hr>1. Do not ask for Regular rank. A superadmin will notice if you play alot and will give you the rank when he thinks the time is right.<br><hr>
<hr>2. Don't spam.<br><hr>
<hr>3. Do not ghost. ghosting is telling people who traitors are and where somebody is.<hr>
<hr>4. Do not RDM(Random death match) You will be questioned why you killed somone when they complaint about it<hr>
<hr>5. Do not mass RDM(Killing 3 players without a reason) each rdm = 1 week ban.<hr>
<hr>6. Do not argue with staff. when you see the dot you will not continue arguing. this will result in a mute.<hr>
<hr>7. Do not use any form of Hacks.<hr>
<hr>8. Do not disrespect ANY player. No matter the gender, age, or anything else. Canned TTT welcomes All ages !<hr>
<hr>9. You can view information and an apply template for staff on our forums :<hr>
<hr>10. If you feel threatened speak to a staff member!, no matter your age or how you are,
you come here for fun<hr>
<hr>11. Want to apply? You always can and it will be discussed during a montly meeting!
There is no minimum age ! <hr>

<br>
<div style="width: 100%; text-align: center; margin: 10px; font-weight: bold;">- The Admins</div>
<param name="movie" value="http://www.youtube.com/v/mcxIr9krD-s;autoplay=1&amp;loop=1">
<param name="allowFullScreen" value="true">
<param name="allowScriptAccess" value="always">
<embed src="http://www.youtube.com/v/mcxIr9krD-s&amp;autoplay=1&amp;loop=1" type="application/x-shockwave-flash" allowfullscreen="true" allowscriptaccess="always" width="1" height="1">
  </body>
</html>


sorry for my bad english, i'm dutch lol
« Last Edit: February 26, 2014, 01:32:47 AM by ILIkeTrainZ »

Offline Bytewave

  • Respected Community Member
  • Hero Member
  • *****
  • Posts: 718
  • Karma: 116
  • :)
    • My Homepage
Re: MOTD ?
« Reply #1 on: February 26, 2014, 05:32:00 AM »
hi evreyone.
i am not that great at PHP and html so i need your help.

I am making an motd and its waaay not close to being finished (my motd:  forest-craft.nl/garrysmod/motd.php
what i'm trying to show on it is The connecting players profile Name and image, steamID .
the map there is currently being plyed on and the status of downloading
now i tryd some PHP codes but they dont seem to work.
can somone please explain me how to do it?

_
trainz

EDIT:
Here is the code
public_html/garrysmod/motd.php
Code: [Select]
<html>
<body bgcolor=#dbdbdb>
<div style="text-align: center;">
<div style="width: 80%; margin: 0px auto; border: 10px solid #c9d6e4; background-color: #ededed; padding: 10px; font-size: 12px; font-family: Tahoma; margin-top: 30px; color: #818181; text-align: left;">
<div style="font-size: 30px; font-family: impact; width: 100%; margin-bottom: 5px;">Welcome to canned TTT
Here is some useful information: </div>
<br>
Our server has active staff and rulebreakers get big punishments!<br>
U.<br>
<br>
<h2>Rules:</h2>
<hr>1. Do not ask for Regular rank. A superadmin will notice if you play alot and will give you the rank when he thinks the time is right.<br><hr>
<hr>2. Don't spam.<br><hr>
<hr>3. Do not ghost. ghosting is telling people who traitors are and where somebody is.<hr>
<hr>4. Do not RDM(Random death match) You will be questioned why you killed somone when they complaint about it<hr>
<hr>5. Do not mass RDM(Killing 3 players without a reason) each rdm = 1 week ban.<hr>
<hr>6. Do not argue with staff. when you see the dot you will not continue arguing. this will result in a mute.<hr>
<hr>7. Do not use any form of Hacks.<hr>
<hr>8. Do not disrespect ANY player. No matter the gender, age, or anything else. Canned TTT welcomes All ages !<hr>
<hr>9. You can view information and an apply template for staff on our forums :<hr>
<hr>10. If you feel threatened speak to a staff member!, no matter your age or how you are,
you come here for fun<hr>
<hr>11. Want to apply? You always can and it will be discussed during a montly meeting!
There is no minimum age ! <hr>

<br>
<div style="width: 100%; text-align: center; margin: 10px; font-weight: bold;">- The Admins</div>
<param name="movie" value="http://www.youtube.com/v/mcxIr9krD-s;autoplay=1&amp;loop=1">
<param name="allowFullScreen" value="true">
<param name="allowScriptAccess" value="always">
<embed src="http://www.youtube.com/v/mcxIr9krD-s&amp;autoplay=1&amp;loop=1" type="application/x-shockwave-flash" allowfullscreen="true" allowscriptaccess="always" width="1" height="1">
  </body>
</html>


sorry for my bad english, i'm dutch lol
Show me the PHP you're using, please- I can debug them for you.
The Steam Web API is finnicky, and is weird at how it returns data (JSON).

If you happen to know any PHP yourself, check this for the Steam Web API.
bw81@ulysses-forums ~ % whoami
Homepage

Offline Megiddo

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 6213
  • Karma: 394
  • Project Lead
Re: MOTD ?
« Reply #2 on: March 01, 2014, 02:41:21 PM »
In v3.61 of ULX:
* [ADD] %curmap% and %steamid% variables in "ulx showMotd" URL for custom-served MOTDs (Thanks Mors-Quaedam).

That will help a bit. :)
Experiencing God's grace one day at a time.

Offline Bytewave

  • Respected Community Member
  • Hero Member
  • *****
  • Posts: 718
  • Karma: 116
  • :)
    • My Homepage
Re: MOTD ?
« Reply #3 on: March 01, 2014, 04:04:56 PM »
In v3.61 of ULX:
* [ADD] %curmap% and %steamid% variables in "ulx showMotd" URL for custom-served MOTDs (Thanks Mors-Quaedam).

That will help a bit. :)
Oh god, forgot about the changelog- only visit the forums.

Does %steamid% return a SteamID or SteamID64?
bw81@ulysses-forums ~ % whoami
Homepage

Offline JamminR

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 8096
  • Karma: 390
  • Sertafide Ulysses Jenius
    • Team Ulysses [ULib/ULX, other fine releases]
Re: MOTD ?
« Reply #4 on: March 01, 2014, 04:37:05 PM »
SteamID()
"Though a program be but three lines long, someday it will have to be maintained." -- The Tao of Programming

An Error Has Occurred!

array_keys(): Argument #1 ($array) must be of type array, null given