Newbie Spellweaver
- Joined
- Oct 15, 2007
- Messages
- 25
- Reaction score
- 0
ArcCms Alpha release 1
Hi all im now releasing the ArcCms Alpha release out to the world
its just in alpha stage at this point but as time goes ArcCms will grow.
some new changes in the system
A demo of ArcCms can be found
SVN
In order to download and be up to date with ArcCms we are running on an SVN server
I recommend to use TortoiseSVN.
Svn server:
User: guest
Installation guide
To install ArcCms at this point is somewhat wierd, but i am working on a self installation process.
First of all, we need to activate some extensions in both apache and php.
I recommend to use AppServ,
Required Apache extension.
How to enable mod_rewrite
Recommended PHP extensions
A guide on how to enable extensions can be found
Settings up ArcCms
Now we unpack all the files in the httpdocs.
When that is complete we go into arccms_root/configs and open mysql.php
where you will see this
fill in that information and we move on to the next step
Database Installation
i recommened to use Navicat or phpmyadmin
1. Import the setup.sql that can be found in the sql folder into a database
2. After the import is done enter table settings
3. edit the cms_url value into your full ArcCms url ie:
4. save and exit
Finilize
You are now done with the setup and are now ready to start using arccms
all settings can be found in the administration/settings panel,
How to create a Widget
To create a Widget in ArcCms is realy easy, with a simple class we can create and mange widgets in no time.
to start creating a widget enter your widget folder at root/widgets
There we create a new file with our widget name.
In this tutorial im gonna name it status.php this widget will display the servers status of each server we got installed in the database.
when this file is created we open it up and write a start class
in this class we set some default variables and create a function with the same name as the class
now that we got some basics up, we can start creating the widget content.
Finilized script
and thats it... in the end my script looked like this.
How to Create a Module page
To create a module page is very simple and easy
start off by creating a file in the root/modules folder
with the name you want on your page
in this example im gonna show you when i created the news page.
first off create a class name with the same name as your file, in this case news
Finilize
In the end i created this script for the news module
i hope you will enjoy this release of ArcCms as it is the alpha release,
you may redistribute this on to other websites / Forums
Bugs can be posted here in the forum or on a PM
Hi all im now releasing the ArcCms Alpha release out to the world
its just in alpha stage at this point but as time goes ArcCms will grow.
some new changes in the system
- New updated armory
- Multi server compability
- Alot of bug fixes
- Paginations
- Unique visitors counter
A demo of ArcCms can be found
You must be registered to see links
SVN
In order to download and be up to date with ArcCms we are running on an SVN server
I recommend to use TortoiseSVN.
You must be registered to see links
Svn server:
You must be registered to see links
User: guest
Installation guide
To install ArcCms at this point is somewhat wierd, but i am working on a self installation process.
First of all, we need to activate some extensions in both apache and php.
I recommend to use AppServ,
You must be registered to see links
Required Apache extension.
- mod_rewrite
How to enable mod_rewrite
- go to the config file in apache/conf/ and open httpd.conf
- Search for #LoadModule rewrite_module modules/mod_rewrite.so
- Remove the # in the beginning
- Restart Apache
Recommended PHP extensions
- cUrl (this is used to check for updates)
- FTP (this is used to download updates from our ftp server)
A guide on how to enable extensions can be found
You must be registered to see links
Settings up ArcCms
Now we unpack all the files in the httpdocs.
When that is complete we go into arccms_root/configs and open mysql.php
where you will see this
Code:
<?php
$conf = array();
$conf['db_host'] = ""; // Mysql Server Host (default: localhost)
$conf['db_user'] = ""; // Mysql Server Username (default: root)
$conf['db_pass'] = ""; // Mysql Server Password
$conf['db_logon'] = ""; // ArcEmu Logon Table
$conf['db_website'] = ""; // ArcCms Website Table
define("COOKIE_PREFIX", "arccms_"); // ArcCms cookie prefix, (you should change this)
define("ARCCMS_INSTALLED", true); // Do not change this...
?>
fill in that information and we move on to the next step
Database Installation
i recommened to use Navicat or phpmyadmin
1. Import the setup.sql that can be found in the sql folder into a database
2. After the import is done enter table settings
3. edit the cms_url value into your full ArcCms url ie:
You must be registered to see links
4. save and exit
Finilize
You are now done with the setup and are now ready to start using arccms
all settings can be found in the administration/settings panel,
How to create a Widget
To create a Widget in ArcCms is realy easy, with a simple class we can create and mange widgets in no time.
to start creating a widget enter your widget folder at root/widgets
There we create a new file with our widget name.
In this tutorial im gonna name it status.php this widget will display the servers status of each server we got installed in the database.
when this file is created we open it up and write a start class
Code:
<?php
// a widget class allways have to extend the class Widget
class statusWidget extends Widget { // a widget allways have to have Widget after it name so that we dont mix it up with any other class
}
?>
in this class we set some default variables and create a function with the same name as the class
Code:
<?php
// a widget class allways have to extend the class Widget
class statusWidget extends Widget { // a widget allways have to have Widget after it name so that we dont mix it up with any other class
var $title = "Server Status"; // This will be displayed above the widget content on the website when active
var $content;
function statusWidget(){
}
}
?>
now that we got some basics up, we can start creating the widget content.
Code:
<?php
// a widget class allways have to extend the class Widget
class statusWidget extends Widget { // a widget allways have to have Widget after it name so that we dont mix it up with any other class
var $title = "Server Status"; // This will be displayed above the widget content on the website when active
var $content;
function statusWidget(){
$this->content = "This is my widget"; //This will be the main content, make sure to allways use the $this-> constant before the content variable
}
}
?>
Finilized script
and thats it... in the end my script looked like this.
Code:
<?php
class statusWidget extends Widget {
public $title = "Server Status";
public $content;
function statusWidget() {
$db = new DB(config::getConf("db_website") . ".servers");
$db->setSort("server_id ASC");
$db->setColPrefix("server_");
$db->select();
while ($db->nextRecord()) {
$online = new DB($db->character_table.".characters");
$online->select("online = 1");
$count = $online->numRows();
$this->content .= "<strong><a href='status/view/".$db->name."'>" . $db->name . "</a></strong> (" . ServerStatus($db->ip, $db->port) . ")<br />
Players Online : ".$count."<br />
Realmlist : ".$db->realmlist."
<hr style='width: 90%;'/>
";
}
}
}
?>
How to Create a Module page
To create a module page is very simple and easy
start off by creating a file in the root/modules folder
with the name you want on your page
in this example im gonna show you when i created the news page.
first off create a class name with the same name as your file, in this case news
Code:
<?php
class news { // The class name have to be the same as the file name.
function index() { // the index function is a default function, this will be loaded if no method as been requested.
}
// For each function we create here we can access it by sending a method request, ie. http://localhost/news/method <-- the method is the name of the function we wanna load
// We can also send up to 3 variables to that function ie. http://localhost/news/method/var1/var2
// Method Example function
function method($var1, $var2, $var3 = "running"){
echo $var1;
echo $var2;
echo $var3;
}
}
?>
Finilize
In the end i created this script for the news module
Code:
<?php
class news {
function index() {
$db = new DB(config::getConf("db_website") . ".news");
$db->setSort("news_id DESC");
$db->setColPrefix("news_");
$db->select();
while ($db->nextRecord()) {
$this->content .= "
<div class='newspost'>
<h2><a href='news/more/" . $db->id . "'>" . $db->title . "</a></h2>
<img src='images/news_cat.jpg' width='84px' class='cat'>
<div class='post'>
" . $db->post . "
</div>
<p class='info'>
<em class='date'>" . showdate("longdate", $db->date) . "</em>
<em class='author'><a href=''>" . ucfirst(getAccount($db->poster, "login")) . "</a></em>
</p>
</div>
<br /><br />
";
}
}
function more($id) {
$db = new DB(config::getConf("db_website") . ".news");
$db->setSort("news_id DESC");
$db->setColPrefix("news_");
$db->select("news_id = '$id'");
$db->nextRecord();
$this->content .= "
<div class='newspost'>
<h2>" . $db->title . "</h2>
<img src='images/news_cat.jpg' width='84px' class='cat'>
<div class='post'>
" . $db->post . "
</div>
<p class='info'>
<em class='date'>" . showdate("longdate", $db->date) . "</em>
<em class='author'><a href=''>" . ucfirst(getAccount($db->poster, "login")) . "</a></em>
</p>
</div>
<br /><br />
"; }
}
?>
i hope you will enjoy this release of ArcCms as it is the alpha release,
you may redistribute this on to other websites / Forums
Bugs can be posted here in the forum or on a PM