Revision history for CodeSnippets


Revision [345]

Last edited on 2008-02-14 00:48:01 by WojciechLisiewicz
Additions:
// w pliku /formatters/wikka.php od linijki ok. 452
//$text = preg_replace("/(art(\.?)|(§)) (.*? [A-Za-z0-9]*)/i", "{{pu przepis=\"$4\"}}", $text);
$text = preg_replace("/((art\.?)|(§)) (.*?) ([A-Za-z0-9]*)/i", "<b><a href=\"javascript:myOpen('norm=$4&skrot=$5', 'przepis_$4_$5');\">$1 $4 $5</a></b>", $text);
//<b><a href="javascript:myOpen('norm=535&skrot=KC', 'przepis_3');">art. 535 KC</a></b>
//{{pu przepis="353 KC"}}


Additions:
komornik varchar(75) NOT NULL,
ocena smallint(6) NOT NULL DEFAULT '0',
opinia text NOT NULL,
username varchar(75) NOT NULL,
,\n `area` varchar(10) collate utf8_bin NOT NULL,\n `pagename` varchar(50) collate utf8_bin NOT NULL,\n `username` varchar(75) collate utf8_bin NOT NULL,\n `latest` enum('Y','N') collate utf8_bin NOT NULL default 'N',\n PRIMARY KEY (`id`)\n) ENGINE=MyISAM AUTO_INCREMENT=6 DEFAULT CHARSET=utf8 COLLATE=utf8_bin";

Deletions:
name varchar(30) collate utf8_bin NOT NULL,\n `firstname` varchar(30) collate utf8_bin NOT NULL,\n `town` varchar(50) collate utf8_bin NOT NULL,\n `area` varchar(10) collate utf8_bin NOT NULL,\n `pagename` varchar(50) collate utf8_bin NOT NULL,\n `username` varchar(75) collate utf8_bin NOT NULL,\n `latest` enum('Y','N') collate utf8_bin NOT NULL default 'N',\n PRIMARY KEY (`id`)\n) ENGINE=MyISAM AUTO_INCREMENT=6 DEFAULT CHARSET=utf8 COLLATE=utf8_bin";


Additions:
$new_table = "CREATE TABLE komornik_opinie (
id int(10) unsigned NOT NULL auto_increment,
name varchar(30) collate utf8_bin NOT NULL,\n `firstname` varchar(30) collate utf8_bin NOT NULL,\n `town` varchar(50) collate utf8_bin NOT NULL,\n `area` varchar(10) collate utf8_bin NOT NULL,\n `pagename` varchar(50) collate utf8_bin NOT NULL,\n `username` varchar(75) collate utf8_bin NOT NULL,\n `latest` enum('Y','N') collate utf8_bin NOT NULL default 'N',\n PRIMARY KEY (`id`)\n) ENGINE=MyISAM AUTO_INCREMENT=6 DEFAULT CHARSET=utf8 COLLATE=utf8_bin";
$rsstr = "INSERT INTO komornik_opinie (komornik, ocena, opinia) VALUES ('".$item."', ".$_POST["ocena"].",'".$_POST["opinia"]."');";
//wykonaj operacje na bazie

// show form - on access only
// for all - show results:
$rssstr = "SELECT * FROM komornik_opinie WHERE ";

Deletions:
$rsstr = "INSERT INTO komornik_opinie (komornik, ocena, opinia) VALUES (".$item.");";


Additions:
%%(php;1)
$item = zmienna przekazywana w action {{komornik item="$item"}}
%%

Deletions:
##
##



No Differences

Revision [332]

The oldest known version of this page was created on 2008-01-23 16:29:43 by WojciechLisiewicz
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki