Goto https://www.stucuk.netGoto https://www.atlanticaonlinewiki.comGoto https://www.game-requirements.com


Menu


It is currently Tue Nov 21, 2017 1:57 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 18 posts ]  Go to page 1, 2  Next
Author Message
 Post subject: Master Server Top 5
PostPosted: Tue Dec 11, 2007 5:42 pm 
Offline
OW Support Owner
OW Support Owner
User avatar

Joined: Wed Dec 28, 2005 11:13 pm
Posts: 4991
Location: UK, Scotland
Websites which have PHP can have a Master Server List(lists only 5). See front page right sidebar for what i mean.

CSS (Changeable)
Code:
.PageStyle1
{
border-top-style: solid; border-bottom-style: solid; border-top-width: 1px; border-bottom-width: 1px; border-left-style: solid; border-left-width: 1px; border-right-style: solid; border-right-width: 1px;
BACKGROUND-COLOR: #2B6F55; border-color:#134633;
}

.PageStyle2
{
border-right-style: solid; border-right-width: 1px; border-left-style: solid; border-left-width: 1px; border-bottom-style: solid; border-bottom-width: 1px; BACKGROUND-COLOR: #1A5E44; border-color: #12402E; font-size: 12px;
}


Actual Include (note you can't use the include command)
Code:
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'http://master.owsupport.com/?display=html');
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_exec($ch);
curl_close($ch);
?>


Note that all you can change is the colours. The table is currently a fixed size, etc.

_________________
Image
Free Map Editor - Game Requirements - Stucuk.Net
-Stu


Top
 Profile  
 
 Post subject:
PostPosted: Tue Dec 11, 2007 9:30 pm 
Offline
Soldier level 3
Soldier level 3
User avatar

Joined: Mon Feb 27, 2006 1:54 pm
Posts: 209
Location: Poland
Cool thing. But I unfortunately cannot add this on my site. The reason is simple. Im using CMS so this is different thing. If I wanna to add a panel then I must have a proper code to include in this:

Quote:
openside("name");
echo "content";
closeside();

In "content". But this code that you showed aint proper. Thats a bit of shame...

_________________
...::: Serpher :::...
Image
Sorry for my bad English


Top
 Profile  
 
 Post subject:
PostPosted: Wed Dec 12, 2007 7:12 pm 
Offline
Original-War.Net Owner
Original-War.Net Owner
User avatar

Joined: Sun Jan 01, 2006 4:56 pm
Posts: 419
Location: Eastern Europe
Replace echo with eval tbh.
http://php.net/eval

_________________
Image


Top
 Profile  
 
 Post subject:
PostPosted: Wed Dec 12, 2007 8:57 pm 
Offline
OW Support Owner
OW Support Owner
User avatar

Joined: Wed Dec 28, 2005 11:13 pm
Posts: 4991
Location: UK, Scotland
The code i posted is PHP code. Which you can place on any site which has PHP support. So it is "proper" code. It effectivly includes the php file on master.owsupport.com into the place you add the code. (so it works like if you use echo)

_________________
Image
Free Map Editor - Game Requirements - Stucuk.Net
-Stu


Top
 Profile  
 
 Post subject:
PostPosted: Sat Dec 15, 2007 10:35 pm 
Offline
OW Support Owner
OW Support Owner
User avatar

Joined: Wed Dec 28, 2005 11:13 pm
Posts: 4991
Location: UK, Scotland
http://master.owsupport.com/?display=xml

the above can be used by anyone who wishes to have full customisability over the data. (For advanced users)

_________________
Image
Free Map Editor - Game Requirements - Stucuk.Net
-Stu


Top
 Profile  
 
 Post subject:
PostPosted: Sat Dec 15, 2007 11:04 pm 
Offline
Soldier level 3
Soldier level 3
User avatar

Joined: Mon Feb 27, 2006 1:54 pm
Posts: 209
Location: Poland
Eh.. It's not working. It's hopeless.

@Yuri
I tryed and nothing...

_________________
...::: Serpher :::...
Image
Sorry for my bad English


Top
 Profile  
 
 Post subject:
PostPosted: Sun Dec 16, 2007 12:01 am 
Offline
OW Support Owner
OW Support Owner
User avatar

Joined: Wed Dec 28, 2005 11:13 pm
Posts: 4991
Location: UK, Scotland
put the code i posted into a blank php file, u will find it works.

_________________
Image
Free Map Editor - Game Requirements - Stucuk.Net
-Stu


Top
 Profile  
 
 Post subject:
PostPosted: Sun Dec 16, 2007 1:12 am 
Offline
Soldier level 3
Soldier level 3
User avatar

Joined: Mon Feb 27, 2006 1:54 pm
Posts: 209
Location: Poland
Nope...
Quote:
Fatal error: Call to undefined function curl_init()

As u see theres only an error...

_________________
...::: Serpher :::...
Image
Sorry for my bad English


Top
 Profile  
 
 Post subject:
PostPosted: Sun Dec 16, 2007 10:00 am 
Offline
Original-War.Net Owner
Original-War.Net Owner
User avatar

Joined: Wed Jan 25, 2006 10:21 am
Posts: 2786
Location: Poland, Białystok
Your server doesn't have implemented curl in PHP :P


Top
 Profile  
 
 Post subject:
PostPosted: Sun Dec 16, 2007 1:32 pm 
Offline
OW Support Owner
OW Support Owner
User avatar

Joined: Wed Dec 28, 2005 11:13 pm
Posts: 4991
Location: UK, Scotland
http://uk3.php.net/curl

Curl is a libary, you should ask your host to install it. (Tho it should already be installed)

_________________
Image
Free Map Editor - Game Requirements - Stucuk.Net
-Stu


Top
 Profile  
 
 Post subject:
PostPosted: Sun Dec 16, 2007 3:43 pm 
Offline
Soldier level 3
Soldier level 3
User avatar

Joined: Mon Feb 27, 2006 1:54 pm
Posts: 209
Location: Poland
@Radzio
Obviously...

@Stucuk
I'll try.

_________________
...::: Serpher :::...
Image
Sorry for my bad English


Top
 Profile  
 
 Post subject:
PostPosted: Sun Dec 16, 2007 3:56 pm 
Offline
Original-War.Net Owner
Original-War.Net Owner
User avatar

Joined: Wed Jan 25, 2006 10:21 am
Posts: 2786
Location: Poland, Białystok
Heh, probably host won't install it (they think that installing something like curl will decrease security).


Top
 Profile  
 
 Post subject:
PostPosted: Sun Dec 16, 2007 10:44 pm 
Offline
Original-War.Net Owner
Original-War.Net Owner
User avatar

Joined: Sun Jan 01, 2006 4:56 pm
Posts: 419
Location: Eastern Europe
Retrieving Master Server info using PHP sockets:

Code:
$conn = fsockopen('master.owsupport.com', 80, $errno, $errstr, 30);
fwrite($conn, "GET /?display=html HTTP/1.0\r\nHost: master.owsupport.com\r\n\r\n");
$in = '';
while (!feof($conn)) {
   $in .= fgets($conn, 128);
}
fclose($conn);
$in = preg_split("#[/\r?\n/]{3}#", $in, 2, PREG_SPLIT_NO_EMPTY);
echo trim($in[1]);

_________________
Image


Last edited by YuriStriatov on Mon Dec 17, 2007 9:07 am, edited 1 time in total.

Top
 Profile  
 
 Post subject:
PostPosted: Sun Dec 16, 2007 11:08 pm 
Offline
Soldier level 3
Soldier level 3
User avatar

Joined: Mon Feb 27, 2006 1:54 pm
Posts: 209
Location: Poland
What Im supposed to do with that (if I must) ?

_________________
...::: Serpher :::...
Image
Sorry for my bad English


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 17, 2007 9:06 am 
Offline
Original-War.Net Owner
Original-War.Net Owner
User avatar

Joined: Sun Jan 01, 2006 4:56 pm
Posts: 419
Location: Eastern Europe
... Paste it into your website?

_________________
Image


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 18 posts ]  Go to page 1, 2  Next

All times are UTC [ DST ]


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group

Original War is an RTS / RPG game by Altar Games
Original War Support is not part of Altar Games but is maintaining Original War for Altar Games

Privacy Policy