CyberX

RevolveR CMS v.1.2.6 :: added query box

In this update RevolveR CMS v1.2.6 added query box and search route. For now visiotors and users of sites thats used RevolveR CMS can did search in nodes contents. Added new core DBX queries types(RR CMS goes to be a framework slowly).

In next releases query box should be upgraded to allow you search not only in nodes. Will be added parametrized search of comments, nodes and forum topics with options of finding in headlines and contents. Also I've develop an extra highligting of keywords in text.

v.1.2.6 avalible on github: https://github.com/xShiftx/RevolveR_CMS

RevolveR CMS v.1.2.5 release

As I promised, a little earlier than planned, I was release RevolveR CMS version 1.2.5 with Turbo Cache based on static files and new way optimized queries by DBX engine.

It's a big changes because now cached by default and under cache updated state by default CMS eats only 2 queries when visitors just watch contents(one query for check cache hash and one for writing statistics). Only two queries and we have 100% working site ability.

Next changes thats released is an INJECT queries for DBX engine. Before RevolveR CMS needs to execute for every field update new UPDATE query, for now all fields UPDATE goes once by query.

Now I can say about it's a time when I should to release forum functionality. Many ideas are collected and it's time to create new system module.

Download RevolveR CMS v.1.2.5.

MySQL UPDATE query without WHERE statement simple

There are some interesting things in world of SQL thats you can like to use. For example we can look at the statement thats works like INSERT MySQL query when you define auto increment field value of zero and work like an UPDATE MySQL query when it's defined as existing auto increment id.

Merge insert and update queries
INSERT INTO `revolver__comments` (`field_id`, `field_content`) 
VALUES ('0', 'TEST LAST INSERT') 
ON DUPLICATE KEY UPDATE `field_id`='0', `field_content`='TEST LAST INSERT';

Look at this statement. If field_id=0 it works like INSERT query but we can use it for UPDATE query also in one instruction:

INSERT INTO `revolver__comments` (`field_id`, `field_content`) 
VALUES ('5', 'TEST UPDATE') 
ON DUPLICATE KEY UPDATE `field_id`='5', `field_content`='TEST UPDATE';

With code bellow MySQL do something like update but it's not need to write WHERE instruction and into field_id having index 5 row fields will putted new data.

Where to use it? For example it can be used when you programming own DataBase engine. For example, my DataBase based on structures instead of queries and I can write something like that:

$STRUCT_COMMENTS = [
	'field_id' => [
		'type'   => 'num', // int
		'auto'   => true,  // auto increment
		'length' => 255,
		'value'  => 0
	],
	'field_node_id' => [
		'type'   => 'num',
		'length' => 50,
		'fill'	 => true
	],
	'field_user_id' => [
		'type'   => 'num',
		'length' => 50,
		'fill'	 => true
	],
	'field_user_name' => [
		'type'   => 'text',
		'length' => 100,
		'fill'	 => true
	],
	'field_content' => [
		'type'   => 'text', // varchar
		'length' => 30000,
		'fill'   => true
	],
	'field_time' => [
		'type'   => 'text',
		'length' => 100,
		'fill'	 => true
	],
	'field_published' => [
		'type' 	 => 'num',
		'length' => 1,
		'fill'	 => false
	]
];

It's an example of table in data base thats created fast and simple with:

// create comments
$dbx::query('c', 'revolver__comments', $STRUCT_COMMENTS);

And next I can insert or update comments data using following structure:

// create comments

$STRUCT = [
	'field_id' => [
		'value'  => 0
	],
	'field_node_id' => [
		'value'	 => 2334
	],
	'field_user_id' => [
		'value'	 => 1
	],
	'field_user_name' => [
		'value'	 => 'CyberX'
	],
	'field_content' => [
		'value'	 => 'Comment text'
	],
	'field_time' => [
		'value'	 => '11/07/2018'
	],
	'field_published' => [
		'value'	 => 1
	]
];

$dbx::query('in', 'revolver__comments', $STRUCT);

Code bellow does an INSERT because field_id value is 0. If this value have an index of existing comment in database this instruction will work like UPDATE. Simple.

Next time I should simplify DELETE query because I do not like WHERE statement.

RevolveR CMS v.1.2.5 coming soon

Good news! In next week I've release a new RevolveR CMS version with big changes in performance plan. For now released and under testing a file cache system thats improves system performance in several times.

RevolveR Turbo Cache

Revolve Cache system based on MD5 hashing of MySQL tables contains site data. Every change runs rehashing mechanism and automatic dump of fresh datas to files for every table. If hashes equals engine nothin to do and just use cache files to render a site. Cache files to be updated automatically at every UPDATE, INSERT or DELETE queries. Simple.

Next change is an INSERT and UPDATE queries merge mechanism. Yes, it's real to use only inject query for update and insert queries. It's based on 'ON DUPLICATE KEY UPDATE' feature and does a simplify all that we want do with database.

v.1.2.5 under testing for now. Release in plans in 20th July.

Sad bug does me a pause in development

I don't know how long it is have an affect on my sytes because I found it accidentally. Usually I work and surf in Safari and do not need any other browser because it is most advanced and stable application for Web.

One day I open my site used front end library RevolveR and found a chrome tab crashed. All other browsers can execute my code perfectly without any problems. Long time I spent to find real Chrome browser developers and write about this issue on Chrome developers forum. There I hear a lot of recommendations without any argumented opinion from not very competent support team. And then I realized about this guys and girls is not real developers of most popular browser ... Apparently the only take icon and make repainted icon for Chrome. The same shit applies to Opera, Yandex browser and a lot of southens.

In the end I was given something like a link on Chromium bugs tracker where I write about problem with my code.

We have to wait for July 19th to resolve this bug thats marked as RB-Stable. I Don't want to do anything for this time. Hope it can be fixed.