<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-21485253</id><updated>2011-04-21T21:42:59.792-07:00</updated><title type='text'>SAPID CMS :: Web-programmer's Blog</title><subtitle type='html'>This blog is devoted to the Sapid Content Management System</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://sapidcmsen.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21485253/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://sapidcmsen.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Pavel Brovchenko</name><uri>http://www.blogger.com/profile/12360174651893719775</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>8</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-21485253.post-115547419624206787</id><published>2006-08-13T06:02:00.000-07:00</published><updated>2006-08-13T06:03:16.260-07:00</updated><title type='text'>get_mysql v0.9</title><content type='html'>get_mysql is an extension for using data from MySQL.&lt;br /&gt;&lt;br /&gt;All needed information in Readme.&lt;br /&gt;&lt;br /&gt;In archive you can find three examples:&lt;br /&gt;&lt;br /&gt;•    get_mysql_news.xml –news line;&lt;br /&gt;•    get_mysql_catalog.xml – catalog;&lt;br /&gt;•    get_mysql_search.xml – search for catalog.&lt;br /&gt;&lt;br /&gt;Download: &lt;a href="http://zik.djmazai.ru/sapid/get_mysql.zip"&gt;get_mysql.zip &lt;/a&gt;&lt;br /&gt;For version: &lt;span style="font-weight: bold;"&gt;Sapid 1.2.3.06&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21485253-115547419624206787?l=sapidcmsen.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sapidcmsen.blogspot.com/feeds/115547419624206787/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21485253&amp;postID=115547419624206787' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21485253/posts/default/115547419624206787'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21485253/posts/default/115547419624206787'/><link rel='alternate' type='text/html' href='http://sapidcmsen.blogspot.com/2006/08/getmysql-v09.html' title='get_mysql v0.9'/><author><name>Pavel Brovchenko</name><uri>http://www.blogger.com/profile/12360174651893719775</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21485253.post-114324619038611928</id><published>2006-03-24T16:14:00.000-08:00</published><updated>2006-03-24T16:23:10.433-08:00</updated><title type='text'>Themes for admin area</title><content type='html'>It is dirty work, but someone should do it. At last I finished Sapid extension for changing decoration themes of admin area. It is not a beta, only alpha version yet. But it works. Even one theme was designed by me :) If someone interested in it, please, test it and tell me about your experience here in comments.&lt;br /&gt;&lt;br /&gt;Download: &lt;a href="http://zik.djmazai.ru/sapid/themes.zip"&gt;themes.zip&lt;/a&gt;&lt;br /&gt;For version: &lt;span style="font-weight: bold;"&gt;Sapid CMS 1.2.3.06&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21485253-114324619038611928?l=sapidcmsen.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sapidcmsen.blogspot.com/feeds/114324619038611928/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21485253&amp;postID=114324619038611928' title='9 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21485253/posts/default/114324619038611928'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21485253/posts/default/114324619038611928'/><link rel='alternate' type='text/html' href='http://sapidcmsen.blogspot.com/2006/03/themes-for-admin-area.html' title='Themes for admin area'/><author><name>Pavel Brovchenko</name><uri>http://www.blogger.com/profile/12360174651893719775</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>9</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21485253.post-114139896314339570</id><published>2006-03-03T07:09:00.001-08:00</published><updated>2006-03-03T07:29:44.066-08:00</updated><title type='text'>Bug with definition of GD. Attempt #2</title><content type='html'>I have decided to go by the simple way, but 100% correct. If function &lt;span style="font-weight: bold;"&gt;createimagetruecolor()&lt;/span&gt; exists it is determined as GD2 if is not - present GD. Actually, likely, only I still have GD, therefore I had problems with it.&lt;br /&gt;In a file &lt;span style="font-style: italic;"&gt;/usr/system/image_resize.inc.php&lt;/span&gt; instead of it (contents standard file &lt;span style="font-style: italic;"&gt;/usr/system/image_resize.inc.php&lt;/span&gt; from Sapid 1.2.3.06):&lt;br /&gt;&lt;span style="color: rgb(51, 51, 51);font-family:courier new;font-size:85%;"  &gt;&lt;blockquote&gt;function _sysB_chkgd2()&lt;br /&gt;{&lt;br /&gt;     $rep=false;&lt;br /&gt;     if(isset($GLOBALS["gBGDVersion"])) {&lt;br /&gt;             $rep=$GLOBALS["gBGDVersion"];&lt;br /&gt;     } else {&lt;br /&gt;             if(function_exists("gd_info")) {&lt;br /&gt;                     $gdver=gd_info();&lt;br /&gt;                     $GLOBALS["gBGDVersion"]=$rep=preg_replace("/^(.*)(\d+?\.?\d+?\.?)(.*)$/", "\\2", $gdver["GD Version"]);&lt;br /&gt;             } else {&lt;br /&gt;                     $arr=get_loaded_extensions();&lt;br /&gt;                     if(in_array("gd", $arr) and $im=@imagecreatetruecolor(1,1)) {&lt;br /&gt;                             imagedestroy($im);&lt;br /&gt;                             $GLOBALS["gBGDVersion"]=$rep="2.0";&lt;br /&gt;                     }elseif (in_array("gd", $arr) and $im=@imagecreate(1,1)){&lt;br /&gt;                             imagedestroy($im);&lt;br /&gt;                             $GLOBALS["gBGDVersion"]=$rep="1.6";&lt;br /&gt;                     }&lt;br /&gt;             }&lt;br /&gt;     }&lt;br /&gt;     return $GLOBALS["gBGDVersion"];&lt;br /&gt;}&lt;/blockquote&gt;&lt;/span&gt;Input next:&lt;br /&gt;&lt;span style="color: rgb(51, 51, 51);font-family:courier new;font-size:85%;"  &gt;&lt;blockquote&gt;function _sysB_chkgd2()&lt;br /&gt;{&lt;br /&gt;     $rep=false;&lt;br /&gt;     if(isset($GLOBALS["gBGDVersion"])) {&lt;br /&gt;             $rep=$GLOBALS["gBGDVersion"];&lt;br /&gt;     } else {&lt;br /&gt;             $arr=get_loaded_extensions();&lt;br /&gt;             if(in_array("gd", $arr) and function_exists(imagecreatetruecolor)) {&lt;br /&gt;                     $GLOBALS["gBGDVersion"]=$rep="2.0";&lt;br /&gt;             }elseif (in_array("gd", $arr) and !function_exists(imagecreatetruecolor)){&lt;br /&gt;                     $GLOBALS["gBGDVersion"]=$rep="1.6";&lt;br /&gt;             }&lt;br /&gt;     }&lt;br /&gt;     return $GLOBALS["gBGDVersion"];&lt;br /&gt;}&lt;/blockquote&gt;&lt;/span&gt;It's all.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21485253-114139896314339570?l=sapidcmsen.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sapidcmsen.blogspot.com/feeds/114139896314339570/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21485253&amp;postID=114139896314339570' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21485253/posts/default/114139896314339570'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21485253/posts/default/114139896314339570'/><link rel='alternate' type='text/html' href='http://sapidcmsen.blogspot.com/2006/03/bug-with-definition-of-gd-attempt-2.html' title='Bug with definition of GD. Attempt #2'/><author><name>Pavel Brovchenko</name><uri>http://www.blogger.com/profile/12360174651893719775</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21485253.post-113987501232993123</id><published>2006-02-05T01:29:00.000-08:00</published><updated>2006-02-13T15:59:22.996-08:00</updated><title type='text'>Classic Photo Gallery</title><content type='html'>&lt;span style="font-weight: bold;"&gt;Classic Photo Gallery&lt;/span&gt; represents equally that follows from the name, i.e. a classical photo gallery.&lt;br /&gt;&lt;br /&gt;I have made some changes in files &lt;span style="font-style: italic;"&gt;/usr/system/image_resize.inc.php&lt;/span&gt; and &lt;span style="font-style: italic;"&gt;/usr/system/insert_qcimage.php&lt;/span&gt;. Now in parameter QC of a picture with an icon it is possible to specify in parameter resize not height and width but only width, and the height will be automatically selected. In a standard variant we should specify necessarily both height and width, in that case happens, that cut the most interesting part of the image.&lt;br /&gt;&lt;br /&gt;Basically, all completely can be understood by looking example DDC and already created galleries. But it is possible to list that has been realized:&lt;br /&gt;&lt;ul&gt;   &lt;li&gt;Creation of albums from admin area;&lt;/li&gt;   &lt;li&gt;Addition of a photo from admin area;&lt;/li&gt;   &lt;li&gt;Editing albums and a photo;&lt;/li&gt;   &lt;li&gt;A paginal conclusion of albums and photos;&lt;/li&gt;   &lt;li&gt;The opportunity of use the module of the comments working on virtual pages;&lt;/li&gt; &lt;/ul&gt; Download: &lt;a href="http://zik.djmazai.ru/sapid/classic_gallery.zip"&gt;classic_gallery.zip&lt;/a&gt;&lt;br /&gt;For version: &lt;span style="font-weight: bold;"&gt;Sapid 1.2.3 RC3&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;Version with comments (the module and the extension of comments which work on virtual pages are included in archive besides gallery)&lt;br /&gt;&lt;br /&gt;Download: &lt;a href="http://zik.djmazai.ru/sapid/classic_gallery+comments.zip"&gt;classic_gallery+comments.zip&lt;/a&gt;&lt;br /&gt;For version: &lt;span style="font-weight: bold;"&gt;Sapid 1.2.3 RC3&lt;/span&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;&lt;span style="font-weight: bold;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21485253-113987501232993123?l=sapidcmsen.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sapidcmsen.blogspot.com/feeds/113987501232993123/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21485253&amp;postID=113987501232993123' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21485253/posts/default/113987501232993123'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21485253/posts/default/113987501232993123'/><link rel='alternate' type='text/html' href='http://sapidcmsen.blogspot.com/2006/02/classic-photo-gallery.html' title='Classic Photo Gallery'/><author><name>Pavel Brovchenko</name><uri>http://www.blogger.com/profile/12360174651893719775</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21485253.post-113987329842920786</id><published>2006-02-02T00:12:00.000-08:00</published><updated>2006-02-13T15:47:18.540-08:00</updated><title type='text'>Bug of sorting by date</title><content type='html'>One more bug, and in familiar place - in sorting. Binary-safe comparison of values has not coped with correct sorting according to a kind "21/01/2006".&lt;br /&gt;&lt;br /&gt;How to struggle? If your purpose stands sorting by field DATE, instead of DATE_CREATE or ID, i.e. during addition of news you add news backdating or on the contrary, you need this cnahges.&lt;br /&gt;&lt;br /&gt;So, we open&lt;span style="font-style: italic;"&gt;/usr/system/common_extfunctions.inc.php&lt;/span&gt; (for the greater clearness in an example I use a standard file, instead of that I already corrected as it was described earlier in it blog). Further we find there such lines:&lt;br /&gt;&lt;br /&gt;&lt;span style="color: rgb(51, 51, 51);font-family:courier new;font-size:85%;"  &gt; &lt;blockquote&gt;if(!defined("cmp_indexasc")) {&lt;br /&gt;   function cmp_indexasc($a, $b) {&lt;br /&gt;          global $sapi_obj;&lt;br /&gt;          $index = $sapi_obj-&gt;env["index"];&lt;br /&gt;          return strcmp($a[$index], $b[$index]);&lt;br /&gt;  }&lt;br /&gt;  define("cmp_indexasc", 1);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;if(!defined("cmp_indexdesc")) {&lt;br /&gt;  function cmp_indexdesc($a, $b) {&lt;br /&gt;          global $sapi_obj;&lt;br /&gt;          $index = $sapi_obj-&gt;env["index"];&lt;br /&gt;          return strcmp($a[$index], $b[$index]);&lt;br /&gt;  }&lt;br /&gt;  define("cmp_indexdesc", 1);&lt;br /&gt;}&lt;/blockquote&gt; &lt;/span&gt;&lt;span style="font-size:100%;"&gt; By the way pay attention, here you can see one more bug which is obvious - and in case ASC sorting and in case DESC the same sorting is made. But now we will correct all this bugs. We replace this with the following:&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="color: rgb(51, 51, 51);font-family:courier new;font-size:85%;"  &gt; &lt;blockquote&gt;if(!defined("cmp_indexasc")) {&lt;br /&gt;  function cmp_indexasc($a, $b) {&lt;br /&gt;          global $sapi_obj;&lt;br /&gt;          $index = $sapi_obj-&gt;env["index"];&lt;br /&gt;          if($index=='ID')&lt;br /&gt;                  return ($a[$index] &gt; $b[$index]) ? -1 : 1;&lt;br /&gt;          else if ($index=='DATE'){&lt;br /&gt;                  $date_a=explode('/',$a[$index]);&lt;br /&gt;                  $date_b=explode('/',$b[$index]);&lt;br /&gt;                  $a_index=mktime (0,0,0,$date_a[1], $date_a[0], $date_a[2]);&lt;br /&gt;                  $b_index=mktime (0,0,0, $date_b[1], $date_b[0], $date_b[2]);&lt;br /&gt;                  return strcmp($a_index,$b_index);&lt;br /&gt;}&lt;br /&gt;          else&lt;br /&gt;                  return strcmp($a[$index], $b[$index]);&lt;br /&gt;  }&lt;br /&gt;  define("cmp_indexasc", 1);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;if(!defined("cmp_indexdesc")) {&lt;br /&gt;  function cmp_indexdesc($a, $b) {&lt;br /&gt;          global $sapi_obj;&lt;br /&gt;          $index = $sapi_obj-&gt;env["index"];&lt;br /&gt;          if($index=='ID')&lt;br /&gt;                  return ($a[$index] &gt; $b[$index]) ? 1 : -1;&lt;br /&gt;          else if ($index=='DATE'){&lt;br /&gt;                  $date_a=explode('/',$a[$index]);&lt;br /&gt;                  $date_b=explode('/',$b[$index]);&lt;br /&gt;                  $a_index=mktime (0,0,0, $date_a[1],$date_a[0], $date_a[2]);&lt;br /&gt;                  $b_index=mktime (0,0,0, $date_b[1], $date_b[0], $date_b[2]);&lt;br /&gt;                  return strcmp($b_index,$a_index);&lt;br /&gt;          }&lt;br /&gt;          else&lt;br /&gt;                  return strcmp($b[$index],$a[$index]);&lt;br /&gt;  }&lt;br /&gt;  define("cmp_indexdesc", 1);&lt;br /&gt;}&lt;/blockquote&gt; &lt;/span&gt;Download: &lt;a href="http://zik.djmazai.ru/sapid/common_extfunctions.inc.zip"&gt;common_extfunctions.inc.zip&lt;/a&gt;&lt;br /&gt;For verion: &lt;span style="font-weight: bold;"&gt;Sapid 1.2.3 RC3&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;If someone will use it, please, tell me about results in comments.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21485253-113987329842920786?l=sapidcmsen.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sapidcmsen.blogspot.com/feeds/113987329842920786/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21485253&amp;postID=113987329842920786' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21485253/posts/default/113987329842920786'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21485253/posts/default/113987329842920786'/><link rel='alternate' type='text/html' href='http://sapidcmsen.blogspot.com/2006/02/bug-of-sorting-by-date.html' title='Bug of sorting by date'/><author><name>Pavel Brovchenko</name><uri>http://www.blogger.com/profile/12360174651893719775</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21485253.post-113918874063868292</id><published>2006-02-01T23:46:00.000-08:00</published><updated>2006-02-13T15:36:49.866-08:00</updated><title type='text'>get_comments - application for comments</title><content type='html'>The standard Sapid's module of comments doesn't work on virtual pages. Therefore, I also have made the following extension (and DDC which not strongly differs from the original) which allows to insert comments on virtual pages without any problems. It allows to create new sections, combining, for example, the standard module such as news and the module of comments to create blogs, etc.&lt;br /&gt;&lt;br /&gt;I have actually made it for a long time ago, and now just simply put in order, something have corrected.&lt;br /&gt;&lt;br /&gt;In archive are submitted following files:&lt;br /&gt;&lt;ul&gt;   &lt;li&gt;/usr/extensions/get_comments.inc.php - the extension;&lt;/li&gt;   &lt;li&gt;/usr/xml/fullcomments.xml - DDC which can be inserted into others DDC;&lt;/li&gt;   &lt;li&gt;/mvc/controller/postmethod_analysis.inc.php - this file should be rewritten atop of standard. They differ very little, namely the redirect after addition of the comment on the same page (protection from refresh-flood), and still some insignificant things in section of addition comments.&lt;/li&gt; &lt;/ul&gt; Download: &lt;a href="http://zik.djmazai.ru/sapid/get_comments.zip"&gt;get_comments.zip&lt;/a&gt;&lt;br /&gt;For version: &lt;span style="font-weight: bold;"&gt;SAPID 1.2.3 RC3&lt;/span&gt;&lt;br /&gt;The note: Correct work only with mod_rewrite.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21485253-113918874063868292?l=sapidcmsen.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sapidcmsen.blogspot.com/feeds/113918874063868292/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21485253&amp;postID=113918874063868292' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21485253/posts/default/113918874063868292'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21485253/posts/default/113918874063868292'/><link rel='alternate' type='text/html' href='http://sapidcmsen.blogspot.com/2006/02/getcomments-application-for-comments.html' title='get_comments - application for comments'/><author><name>Pavel Brovchenko</name><uri>http://www.blogger.com/profile/12360174651893719775</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21485253.post-113831482800739584</id><published>2006-01-26T14:16:00.000-08:00</published><updated>2006-02-05T16:07:41.626-08:00</updated><title type='text'>Bug of sorting numerical values</title><content type='html'>The bug consists in not correct comparison of two numerical values in sorting functions of a file &lt;span style="font-style: italic;"&gt;/usr/system/common_extfunctions.inc.php&lt;/span&gt;. I.e., for example, we sort on &lt;span style="font-weight: bold;"&gt;ID&lt;/span&gt;, we have records with &lt;span style="font-weight: bold;"&gt;ID&lt;/span&gt;: &lt;span style="font-style: italic;"&gt;1,2,3,4,5,6,7,8,9,10,11&lt;/span&gt; in database. After performance of sorting &lt;span style="font-weight: bold;"&gt;_ORDER (INDEX, ID, ASC) _&lt;/span&gt; in application&lt;span style="font-style: italic;"&gt; get_infochannel&lt;/span&gt; (or anyone similar) the result will be following: &lt;span style="font-style: italic;"&gt;1,&lt;span style="color: rgb(153, 0, 0);"&gt;10&lt;/span&gt;,&lt;span style="color: rgb(153, 0, 0);"&gt;11&lt;/span&gt;,2,3,4,5,6,7,8,9&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;Here it is an example of what there was and on what I have changed it, I'll not explain, who knows - all easily will understand:&lt;br /&gt;&lt;blockquote style="color: rgb(51, 51, 51);"&gt;&lt;span style="color: rgb(51, 51, 51);font-family:courier new;font-size:85%;"  &gt;// What there was&lt;br /&gt;if(!defined("cmp_indexasc")) {&lt;br /&gt;function cmp_indexasc($a, $b) {&lt;br /&gt;     global $sapi_obj;&lt;br /&gt;     $index = $sapi_obj-&gt;env["index"];&lt;br /&gt;     return strcmp($a[$index], $b[$index]);&lt;br /&gt;}&lt;br /&gt;define("cmp_indexasc", 1);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;if(!defined("cmp_indexdesc")) {&lt;br /&gt;function cmp_indexdesc($a, $b) {&lt;br /&gt;     global $sapi_obj;&lt;br /&gt;     $index = $sapi_obj-&gt;env["index"];&lt;br /&gt;     return strcmp($a[$index], $b[$index]);&lt;br /&gt;}&lt;br /&gt;define("cmp_indexdesc", 1);&lt;br /&gt;}&lt;/span&gt;&lt;br /&gt;&lt;/blockquote&gt; &lt;span style="color: rgb(51, 51, 51);font-family:courier new;font-size:85%;"  &gt;&lt;/span&gt;&lt;span style="color: rgb(51, 51, 51);font-family:courier new;font-size:85%;"  &gt;&lt;/span&gt;&lt;blockquote  style="color: rgb(51, 51, 51);font-family:courier new;"&gt;&lt;span style="font-size:100%;"&gt;&lt;span style="font-size:85%;"&gt;// On what we change&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;if(!defined("cmp_indexasc")) {&lt;br /&gt;function cmp_indexasc($a, $b) {&lt;br /&gt;     global $sapi_obj;&lt;br /&gt;     $index = $sapi_obj-&gt;env["index"];&lt;br /&gt;     if(is_numeric($a[$index]))&lt;br /&gt;             return ($a[$index] &gt; $b[$index]) ? -1 : 1;&lt;br /&gt;     else&lt;br /&gt;             return strcmp($a[$index], $b[$index]);&lt;br /&gt;}&lt;br /&gt;define("cmp_indexasc", 1);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;if(!defined("cmp_indexdesc")) {&lt;br /&gt;function cmp_indexdesc($a, $b) {&lt;br /&gt;     global $sapi_obj;&lt;br /&gt;     $index = $sapi_obj-&gt;env["index"];&lt;br /&gt;     if(is_numeric($a[$index]))&lt;br /&gt;             return ($a[$index] &gt; $b[$index]) ? 1 : -1;&lt;br /&gt;     else&lt;br /&gt;             return strcmp($a[$index], $b[$index]);&lt;br /&gt;}&lt;br /&gt;define("cmp_indexdesc", 1);&lt;br /&gt;}&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/blockquote&gt;Also I offer to download already corrected file if suddenly someone laziness to correct it by himself ;)&lt;br /&gt;&lt;br /&gt;Download: &lt;a href="http://zik.djmazai.ru/sapid/common_extfunctions.inc.zip"&gt;common_extfunctions.inc.zip&lt;/a&gt;&lt;br /&gt;For version: &lt;span style="font-weight: bold;"&gt;Sapid 1.2.3 RC3&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21485253-113831482800739584?l=sapidcmsen.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sapidcmsen.blogspot.com/feeds/113831482800739584/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21485253&amp;postID=113831482800739584' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21485253/posts/default/113831482800739584'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21485253/posts/default/113831482800739584'/><link rel='alternate' type='text/html' href='http://sapidcmsen.blogspot.com/2006/01/bug-of-sorting-numerical-values.html' title='Bug of sorting numerical values'/><author><name>Pavel Brovchenko</name><uri>http://www.blogger.com/profile/12360174651893719775</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21485253.post-113818664620218634</id><published>2006-01-25T02:55:00.000-08:00</published><updated>2006-02-13T15:33:39.080-08:00</updated><title type='text'>Lite version of get_infochannel</title><content type='html'>One of these days I've made the extension which is the lite version of get_infochannel, but as against it doesn't create any folders like /usr/xml/vdb/news/ in database, the index file is created only.&lt;br /&gt;&lt;br /&gt;The given module is ideal for creation of various lists, price-lists, etc.&lt;br /&gt;&lt;br /&gt;Download: &lt;a href="http://zik.djmazai.ru/sapid/get_list.zip"&gt;get_list.zip&lt;/a&gt;&lt;br /&gt;For version: &lt;span style="font-weight: bold;"&gt;Sapid 1.2.3 RC3&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21485253-113818664620218634?l=sapidcmsen.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sapidcmsen.blogspot.com/feeds/113818664620218634/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21485253&amp;postID=113818664620218634' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21485253/posts/default/113818664620218634'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21485253/posts/default/113818664620218634'/><link rel='alternate' type='text/html' href='http://sapidcmsen.blogspot.com/2006/01/lite-version-of-getinfochannel.html' title='Lite version of get_infochannel'/><author><name>Pavel Brovchenko</name><uri>http://www.blogger.com/profile/12360174651893719775</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry></feed>
