MageDB Development blog
Friday, February 2, 2007 2:35:02 PM
Development news of paFileDB Extreme Edition (EXED)
Friday, February 2, 2007 2:35:02 PM
Friday, February 2, 2007 2:43:12 AM

i didn`t got much replys on most of my threads but the stats here are showing that there are way more readers than posters so thanx again for reading my bad english and poor grammer typing 
Sunday, January 28, 2007 2:20:38 AM
Monday, January 22, 2007 9:24:39 PM
Friday, January 19, 2007 4:38:59 PM
Thursday, January 18, 2007 11:22:12 PM



Wednesday, January 17, 2007 10:35:16 PM

in some tests that i did some parts are about 6 times faster now than they where before.. though this is mostly thanx to the ban on the global function (i don`t use it anymore which is a good thing)
... becuase it`s offline now for a few days!!! if this continues for the next few days i will just quit that host and probably ask Ala (a person that`s on extreme edition for almost the beginning since i started with it) to host Extreme Edition bacause his site is online for quite some time now 

Saturday, January 13, 2007 12:51:48 AM
Thursday, January 11, 2007 6:52:56 PM
and it is (or atleast should be) faster than the default beta 1 way.Monday, January 8, 2007 10:38:27 PM
) and than click on "Security Notification" once that`s done click on: "Update NOW with the latest patch information!" and than you should have received the latest patch information which contains all the required info to fix this bug.
otherwise look in some of the php files in ./includes/exed/ all .php
but i`m just having a very hard time in making those sub categories working... and the dropdown..
it`s all so hard to do... o well it`s a nice challenge for me anyway.
o well.. another bug fix will go online for that in a few days i think.Friday, January 5, 2007 3:44:28 PM

Monday, January 1, 2007 2:38:20 AM


Friday, December 29, 2006 10:03:16 PM

Wednesday, December 27, 2006 9:42:34 PM

it wouldn`t even install, now it will. all that needed fixing where some lines in the sql file and a missing config line.Monday, December 25, 2006 12:05:06 AM
and i have a small present for everyone. i`ve just completed the first part of the database backup system.. this part is just a script that grabs tons of mysql info and makes a table dump. it doesn`t make the data dump yet (so that are all the entries you made in pafiledb) but i`m gonna try to finish the data dump part as soon as possible.
in the code below it`s extending the pafiledb sql class but you can remove the "extends padb_mysql"
because it just needs the database connection.. nothing more of the class. so as long as you have a db connection you don`t need the extends part.
here is the code so far.
<?php
/*=================================================================
| MySQL Backup DB 1.0 |
+-----------------------------------------------------------------+
| Backup DB is a php script that is used to make database |
| backups. With this script you can not only make a dump of |
| the table structure but also a complete dump of the entire |
| entire database. |
| |
| |
| Creator : Mark also known as markg85 |
| E-Mail : markg852@hotmail.com |
| Licence : GPL V2 |
| Version : 1.0 |
| |
=================================================================*/
require ('../db/mysql.php');
class backupdb extends padb_mysql
{
// Public Vars
var $show_charset = 'no'; // useless at this moment
var $do_table = '*.*'; // useless at this moment
// Private Vars
var $types = array(MYSQL_ASSOC, MYSQL_NUM, MYSQL_BOTH);
var $engines;
var $auto_increment;
// Constructor
function structure_dbbackup()
{
$table_names = $this->fetch_all(mysql_list_tables($this->dbname));
$this->engines = array();
$structure = '';
$table_status_array = $this->fetch_all(mysql_query("show table status from pafiledb353"));
foreach ($table_status_array as $table_status)
{
$this->engines[$table_status['Name']] = $table_status['Engine'];
$this->auto_increment[$table_status['Name']] = $table_status['Auto_increment'];
//echo $table_status['Engine'] . '<br>';
}
foreach ($table_names as $table_array)
{
foreach ($table_array as $table)
{
$structure .= '-- ' . str_repeat('-', 80) . '<br>';
$structure .= '-- ' . $table . '<br>';
$structure .= '-- ' . str_repeat('-', 80) . '<br><br>';
$structure .= 'CREATE TABLE IF NOT EXISTS `' . $table . '`<br>(<br>';
$index_query = mysql_query("SHOW INDEX FROM " . $table . " FROM pafiledb353");
$index_array = $this->fetch_all($index_query);
$num_rows = mysql_num_rows($index_query);
$columns_array = $this->fetch_all(mysql_query("SHOW COLUMNS FROM " . $table . ""));
$num_fields = mysql_num_fields(mysql_query("SELECT * FROM " . $table . ""));
foreach ($columns_array as $key => $column)
{
$structure .= str_repeat(' ', 4) . '`' . $column['Field'] . '` ' . $column['Type'];
if (empty($column['Extra']))
{
if (!preg_match('/text/i', $column['Type']))
{
$structure .= (trim($column['Default']) == '') ? '' : ' DEFAULT \'' . $column['Default'] . '\'';
}
}
$structure .= ($column['Null'] == 'NO') ? ' NOT NULL' : ' NULL';
$structure .= (!empty($column['Extra'])) ? ' ' . strtoupper($column['Extra']) : '';
$structure .= ($num_fields -1 == $key AND $num_rows == 0) ? '<br>' : ',<br>';
}
foreach ($index_array as $key => $index)
{
if ($index['Non_unique'] == 0 and $index['Index_type'] == 'BTREE')
{
$structure .= str_repeat(' ', 4) . 'PRIMARY KEY (`' . $index['Column_name'] . '`)';
}
if ($index['Non_unique'] == 1 and $index['Index_type'] == 'BTREE')
{
$structure .= str_repeat(' ', 4) . 'KEY `' . $index['Key_name'] . '` (`' . $index['Column_name'] . '`)';
}
$structure .= ($key == $num_rows - 1) ? '<br>' : ',<br>';
}
$structure .= ') ';
$structure .= 'ENGINE=' . $this->engines[$table] . ((!empty($this->auto_increment[$table])) ? ' AUTO_INCREMENT=' . $this->auto_increment[$table] : '') . ';<br><br><br>';
}
}
return $structure;
}
// This function fetches all sql data and puts it in a multidimensional array
function fetch_all($result, $type = MYSQL_ASSOC)
{
if (!in_array($type, $this->types)) die("Invalid Action!");
$all = array();
while ($row = mysql_fetch_array($result, $type))
{
$all[] = $row;
}
return $all;
}
}
$test = new backupdb;
echo $test->structure_dbbackup();
?>
en here is how a output looks like:
-- --------------------------------------------------------------------------------
-- pafiledb_admin
-- --------------------------------------------------------------------------------
CREATE TABLE IF NOT EXISTS `pafiledb_admin`
(
`admin_id` int(5) NOT NULL AUTO_INCREMENT,
`admin_username` varchar(20) NULL,
`admin_password` varchar(32) NULL,
`admin_email` varchar(50) NULL,
`admin_status` int(1) NULL,
PRIMARY KEY (`admin_id`)
) ENGINE=MyISAM AUTO_INCREMENT=2;
-- --------------------------------------------------------------------------------
-- pafiledb_cat
-- --------------------------------------------------------------------------------
CREATE TABLE IF NOT EXISTS `pafiledb_cat`
(
`cat_id` int(5) NOT NULL AUTO_INCREMENT,
`cat_name` varchar(75) NULL,
`cat_desc` varchar(150) NULL,
`cat_files` int(10) NULL,
`cat_parent` int(5) NULL,
`cat_order` int(5) NULL,
`cat_sort` varchar(25) NULL,
PRIMARY KEY (`cat_id`)
) ENGINE=MyISAM AUTO_INCREMENT=103;
-- --------------------------------------------------------------------------------
-- pafiledb_comments
-- --------------------------------------------------------------------------------
CREATE TABLE IF NOT EXISTS `pafiledb_comments`
(
`comments_id` int(10) NOT NULL AUTO_INCREMENT,
`file_id` int(10) DEFAULT '0' NOT NULL,
`news_id` int(10) DEFAULT '0' NOT NULL,
`comments_text` text NOT NULL,
`comments_poster` text NOT NULL,
`comments_ip` text NOT NULL,
`comments_title` text NOT NULL,
`comments_time` int(50) DEFAULT '0' NOT NULL,
`show_comment` int(2) DEFAULT '1',
`comments_warning` int(2) DEFAULT '0' NULL,
PRIMARY KEY (`comments_id`)
) ENGINE=MyISAM AUTO_INCREMENT=4;
-- --------------------------------------------------------------------------------
-- pafiledb_custom
-- --------------------------------------------------------------------------------
CREATE TABLE IF NOT EXISTS `pafiledb_custom`
(
`custom_id` int(5) NOT NULL AUTO_INCREMENT,
`custom_name` varchar(50) NOT NULL,
`custom_description` varchar(150) NOT NULL,
PRIMARY KEY (`custom_id`)
) ENGINE=MyISAM AUTO_INCREMENT=1;
-- --------------------------------------------------------------------------------
-- pafiledb_customdata
-- --------------------------------------------------------------------------------
CREATE TABLE IF NOT EXISTS `pafiledb_customdata`
(
`customdata_file` int(5) DEFAULT '0' NOT NULL,
`customdata_custom` int(5) DEFAULT '0' NOT NULL,
`data` text NOT NULL
) ENGINE=MyISAM;
-- --------------------------------------------------------------------------------
-- pafiledb_emaillog
-- --------------------------------------------------------------------------------
CREATE TABLE IF NOT EXISTS `pafiledb_emaillog`
(
`e_id` int(6) NOT NULL AUTO_INCREMENT,
`e_date` int(20) DEFAULT '0' NOT NULL,
`e_ip` varchar(15) NOT NULL,
`e_fromname` text NOT NULL,
`e_fromaddress` text NOT NULL,
`e_toname` text NOT NULL,
`e_toaddress` text NOT NULL,
`e_headers` text NOT NULL,
`e_subject` text NOT NULL,
`e_message` text NOT NULL,
PRIMARY KEY (`e_id`)
) ENGINE=MyISAM AUTO_INCREMENT=100;
-- --------------------------------------------------------------------------------
-- pafiledb_exed
-- --------------------------------------------------------------------------------
CREATE TABLE IF NOT EXISTS `pafiledb_exed`
(
`id` smallint(1) unsigned NOT NULL AUTO_INCREMENT,
`newindicator` tinyint(1) unsigned DEFAULT '1',
`displaynewindicatordays` tinyint(1) unsigned DEFAULT '5',
`downtime` tinyint(1) unsigned DEFAULT '1',
`filesize` tinyint(1) unsigned DEFAULT '1',
`filesize_type` tinyint(1) unsigned DEFAULT '1',
`filesize_intervalcheck` tinyint(1) unsigned DEFAULT '0' NOT NULL,
`filesize_interval` smallint(1) unsigned DEFAULT '1000',
`pleasewait` tinyint(1) unsigned DEFAULT '0' NOT NULL,
`waittime` tinyint(1) unsigned DEFAULT '5',
`commentskin` tinyint(1) unsigned DEFAULT '1',
`permalink` tinyint(1) unsigned DEFAULT '1',
`commentsx` tinyint(1) unsigned DEFAULT '1',
`thumbnailingx` tinyint(1) unsigned DEFAULT '1',
`enabledisablefile` tinyint(1) unsigned DEFAULT '0' NOT NULL,
`enabledisabledownload` tinyint(1) unsigned DEFAULT '0' NOT NULL,
`toplist` tinyint(1) unsigned DEFAULT '1',
`toplist_where` tinyint(1) unsigned DEFAULT '1',
`toplist_downloads` tinyint(1) unsigned DEFAULT '1',
`toplist_ratings` tinyint(1) unsigned DEFAULT '1',
`toplist_newest` tinyint(1) unsigned DEFAULT '1',
`show_drop_down` tinyint(1) unsigned DEFAULT '1',
`show_file_log` tinyint(1) unsigned DEFAULT '0' NOT NULL,
`icon_or_thumb` tinyint(1) unsigned DEFAULT '1',
`pagination_style` tinyint(1) unsigned DEFAULT '1',
`sec_xml` text NOT NULL,
`sec_last_xml_fetch` char(10) NOT NULL,
`version` varchar(10) NOT NULL,
`sec_version` text NOT NULL,
`sec_last_mail` char(10) NOT NULL,
`readable_version` varchar(15) NOT NULL,
`register_mod` tinyint(1) unsigned DEFAULT '1',
`guest_must_register` tinyint(1) unsigned DEFAULT '0' NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM AUTO_INCREMENT=2;
-- --------------------------------------------------------------------------------
-- pafiledb_files
-- --------------------------------------------------------------------------------
CREATE TABLE IF NOT EXISTS `pafiledb_files`
(
`file_id` int(10) NOT NULL AUTO_INCREMENT,
`file_name` varchar(150) NULL,
`file_desc` varchar(200) NULL,
`file_creator` varchar(100) NULL,
`file_version` varchar(20) NULL,
`file_longdesc` text NULL,
`file_ssurl` text NULL,
`file_dlurl` text NULL,
`file_size` varchar(20) DEFAULT '0|0',
`file_mirrors` text NOT NULL,
`file_time` int(50) NULL,
`file_catid` int(5) NULL,
`file_posticon` varchar(30) NULL,
`file_license` int(5) NULL,
`file_dls` int(10) NULL,
`file_last` int(50) NULL,
`file_pin` int(1) NULL,
`file_docsurl` text NULL,
`file_rating` int(10) DEFAULT '0' NOT NULL,
`file_totalvotes` int(10) DEFAULT '0' NOT NULL,
`file_disabled` tinyint(1) unsigned DEFAULT '0' NOT NULL,
`file_download_disabled` tinyint(1) unsigned DEFAULT '0' NOT NULL,
`file_added_by` text NOT NULL,
`file_edited` text NOT NULL,
PRIMARY KEY (`file_id`),
KEY `file_dls` (`file_dls`),
KEY `file_time` (`file_time`),
KEY `file_name` (`file_name`)
) ENGINE=MyISAM AUTO_INCREMENT=254;
-- --------------------------------------------------------------------------------
-- pafiledb_filestats
-- --------------------------------------------------------------------------------
CREATE TABLE IF NOT EXISTS `pafiledb_filestats`
(
`fs_id` smallint(1) unsigned NOT NULL AUTO_INCREMENT,
PRIMARY KEY (`fs_id`)
) ENGINE=MyISAM AUTO_INCREMENT=1;
-- --------------------------------------------------------------------------------
-- pafiledb_license
-- --------------------------------------------------------------------------------
CREATE TABLE IF NOT EXISTS `pafiledb_license`
(
`license_id` int(5) NOT NULL AUTO_INCREMENT,
`license_name` varchar(30) NULL,
`license_text` text NULL,
PRIMARY KEY (`license_id`)
) ENGINE=MyISAM AUTO_INCREMENT=1;
-- --------------------------------------------------------------------------------
-- pafiledb_permissions
-- --------------------------------------------------------------------------------
CREATE TABLE IF NOT EXISTS `pafiledb_permissions`
(
`id` smallint(1) unsigned NOT NULL AUTO_INCREMENT,
`cat_id` text NOT NULL,
`admin_id` smallint(1) unsigned NOT NULL,
`perm_add_files` tinyint(1) unsigned NOT NULL,
`perm_edit_files` tinyint(1) unsigned NOT NULL,
`perm_del_files` tinyint(1) unsigned NOT NULL,
`perm_manage_files` tinyint(1) unsigned NOT NULL,
`perm_add_cats` tinyint(1) unsigned NOT NULL,
`perm_edit_cats` tinyint(1) unsigned NOT NULL,
`perm_del_cats` tinyint(1) unsigned NOT NULL,
`perm_add_ums` tinyint(1) unsigned NOT NULL,
`perm_edit_ums` tinyint(1) unsigned NOT NULL,
`perm_del_ums` tinyint(1) unsigned NOT NULL,
`perm_manage_ums` tinyint(1) unsigned NOT NULL,
`perm_create_db_backup` tinyint(1) unsigned NOT NULL,
`perm_edit_pafiledb_info` tinyint(1) unsigned NOT NULL,
`perm_enable_disable_mod` tinyint(1) unsigned NOT NULL,
`perm_change_mod_settings` tinyint(1) unsigned NOT NULL,
`perm_view_mail_log` tinyint(1) unsigned NOT NULL,
`perm_manage_licence` tinyint(1) unsigned NOT NULL,
`perm_manage_custom` tinyint(1) unsigned NOT NULL,
`perm_view_phpinfo` tinyint(1) unsigned NOT NULL,
`perm_rebuild_categorymenu` tinyint(1) unsigned NOT NULL,
`perm_versioncheck` tinyint(1) unsigned NOT NULL,
`perm_seccheck` tinyint(1) unsigned NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM AUTO_INCREMENT=2;
-- --------------------------------------------------------------------------------
-- pafiledb_searchquery
-- --------------------------------------------------------------------------------
CREATE TABLE IF NOT EXISTS `pafiledb_searchquery`
(
`id` smallint(1) unsigned NOT NULL AUTO_INCREMENT,
`query` varchar(50) NOT NULL,
`key` char(32) NOT NULL,
`in` varchar(20) NOT NULL,
`sort_on` varchar(20) NOT NULL,
`order` char(4) NOT NULL,
`results` varchar(10) NOT NULL,
`timeout` char(10) NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM AUTO_INCREMENT=52;
-- --------------------------------------------------------------------------------
-- pafiledb_settings
-- --------------------------------------------------------------------------------
CREATE TABLE IF NOT EXISTS `pafiledb_settings`
(
`id` int(1) NOT NULL AUTO_INCREMENT,
`dbname` text NOT NULL,
`dburl` text NOT NULL,
`topnumber` int(5) DEFAULT '0' NOT NULL,
`homeurl` text NOT NULL,
`timeoffset` int(5) DEFAULT '0' NOT NULL,
`timezone` varchar(100) NOT NULL,
`skin` varchar(20) NOT NULL,
`stats` int(1) DEFAULT '0' NOT NULL,
`lang` varchar(20) NOT NULL,
`viewall` int(1) DEFAULT '0' NOT NULL,
`showss` int(1) DEFAULT '0' NOT NULL,
`date_format` varchar(40) NOT NULL,
`time_format` varchar(40) NOT NULL,
`dropdown` text NOT NULL,
`enable_email` int(1) DEFAULT '0' NOT NULL,
`perpage` int(3) DEFAULT '0' NOT NULL,
`enable_report` int(1) DEFAULT '1',
PRIMARY KEY (`id`)
) ENGINE=MyISAM AUTO_INCREMENT=2;
-- --------------------------------------------------------------------------------
-- pafiledb_users
-- --------------------------------------------------------------------------------
CREATE TABLE IF NOT EXISTS `pafiledb_users`
(
`user_id` mediumint(1) unsigned NOT NULL AUTO_INCREMENT,
`user_username` varchar(25) NOT NULL,
`user_password` varchar(32) NOT NULL,
`user_mail` varchar(50) NOT NULL,
`user_permission` mediumint(1) unsigned NOT NULL,
PRIMARY KEY (`user_id`)
) ENGINE=MyISAM AUTO_INCREMENT=1;
nice huh
till next blog.Sunday, December 24, 2006 2:54:49 PM

they are at difficulty 10 or higher
Friday, December 15, 2006 8:53:39 PM


Thursday, December 14, 2006 10:05:10 PM


that`s all that still needs to be done for the notification script 
depends on how well it`s actually going.
currently the place where the security stuff is downoaded from is a XML file.. now this isn`t big at all at this moment, BUT imagine that there are 10 bug fixes a year, 10 security hole fixes and 10 new releases.. a clean beta 1 install will than show 30!!! notifications and besides that that will be serveral pages full with notifications the xml file will also get alot bigger... i think about 500KB.. so in later releases i will probably need to change to .tar.gz packages that get downloaded and contain the xml file.. that`s alot smaller.. the only bad thing about that is that it`s not so simple to do that... and some hosts don`t allow the downloading of files
o well.. this is a problem that currently doesn`t pose a thread and doesn`t need fixing at the moment... buy my oh my how will i do this when Extreme Edition 2.0.0 is about done :S
if you do things like that you just ask to get hacked and perhaps i`m also gonna add a bug gount nr next to the version number just to kinda "force" the users of this script to update to be as safe as possible.Sunday, December 10, 2006 8:50:39 PM

it has about the same powers as DATE_FORMAT() so that fixed that bug. the date is now seen as: YEAR MONTH DAY HOUR MINUTE and you can search through that. i don`t know if i`m gonna link that with the date format field that you have in the admin panel.

Wednesday, November 29, 2006 8:23:49 PM
..
another thing that must be in this notify script is a mail system that will mail all the admins to notify them of the security hole. and i need to script my fancy notifications in 
this was all that i needed:
Tuesday, November 28, 2006 1:13:39 AM


the final release won`t have a banner.. it will just have a text row.
.................
the security bug has been resolved (though i don`t like the current admin system.. i will probably redo it again) and some other optimizations have also been done.
)
Sunday, November 26, 2006 3:09:18 PM



Friday, November 24, 2006 1:57:32 PM
ofcause there will be a option to disable this security warning 
that system can also be used to update extreme edition beta 1 to beta 2 if all is going fine of cause.
and i hope i`ve fixed all bugs by than.Tuesday, November 21, 2006 10:05:57 PM

Sunday, November 19, 2006 7:26:02 PM

Saturday, November 18, 2006 12:26:43 AM

Monday, November 13, 2006 4:40:25 PM

when that`s done i will remove Fedora Core 6 (i have to many issues with it anyway) and install the latest version of Ubuntu edgy eft 6.10 that should work way more smooth and easyer anyway
and it looks betterMonday, October 16, 2006 12:54:58 AM


Thursday, September 28, 2006 7:22:35 PM



and it can still be improved..
(it`s being requited 2 few times now so i guess i need to make it..)Wednesday, September 20, 2006 12:57:31 PM


Monday, September 18, 2006 12:27:39 AM


probly somewhere arround december 2006.Wednesday, September 13, 2006 7:24:06 PM
it`s already working on most of the pages that have files in them.
Sunday, September 10, 2006 6:37:28 PM
give me my rest 
Wednesday, August 30, 2006 7:36:10 PM


Thursday, August 10, 2006 9:36:20 PM
Wednesday, August 9, 2006 10:40:34 PM
Sunday, August 6, 2006 11:03:58 PM
Saturday, August 5, 2006 4:08:22 PM
Tuesday, July 11, 2006 1:49:37 PM

it`s just on hold for a while till i get enough of LightAdmin
than i continue with Extreme Edition.
Friday, July 7, 2006 1:02:50 PM
Saturday, July 1, 2006 3:01:15 PM

Sunday, June 25, 2006 10:24:07 PM
Saturday, June 24, 2006 8:47:54 PM
Friday, June 23, 2006 12:25:04 PM
Thursday, June 22, 2006 8:23:34 PM
Thursday, June 22, 2006 9:49:04 AM

Wednesday, June 21, 2006 10:02:23 PM
Friday, June 16, 2006 8:11:34 PM
Wednesday, June 14, 2006 12:04:40 PM
Monday, June 12, 2006 11:48:00 PM


| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
|
| ||||||
| 1 | 2 | 3 | 4 | |||
| 5 | 6 | 7 | 8 | 9 | 10 | 11 |
| 12 | 13 | 14 | 15 | 16 | 17 | 18 |
| 19 | 20 | 21 | 22 | 23 | 24 | 25 |
| 26 | 27 | 28 | 29 | |||