From: Alessandro P. (T. / J578) <al...@ti...> - 2002-01-07 15:20:55
|
On Sat, 2002-01-05 at 08:09, spiggy wrote: > Vlad Sedov wrote: > > >Ok, here's a minor problem i had with CVS tarball and blocks - > > > >remember I complained that I could not add blocks (they were somehow > >directed into oblivion)? > >I made the id field in the core_blocks table auto_increment, and voila! > >Blocks started showing up. > > > >the saving query looks like this: > > > >mysql_query("INSERT INTO " . $table_prefix."core_blocks VALUES (NULL, > >$block_order+1, '$block_location', '1',.......... etc etc > > > >from what I could figure out, if you're trying to pass NULL to the primary > >key field that doesn't auto-increment, the query succeeds but doesn't > >actually add anything to the table. > > > >Has anyone else had this problem?... > > > > mine increments just fine but there is a missing value in the middle of > the insert statement, namely 'docking',. i havent figured out the > meaning of it so if i insert docking as zero (NULL, $block_order+1, > '$block_location', '0', '1', '$data') the block gets inserted into the > table. > > paivi I've deeply tested the blocks feature and the codelines both of you pointed out: Vlad: it is _not_ normal that your id column doesn't auto_increment. Please try reinstalling from scratch the latest CVS version. Btw code is okay: I installed it and my core_blocks->id has auto_increment as expected. paivi: the docking element is _not_ part of the standard core_clocks table; I mean: it does not come in phpwebsite db schema for install. As for Vlad, please try reinstalling from scrath the latest CVS version, due to the fact that code is okay. Please feel free to report me any further problem HTH Kind Regards, Alessandro -- Alessandro "TXM" Pisani - al...@ti... - ICQ #2209087 phpWebSite Development Team http://phpwebsite.appstate.edu INWO Project coordinator http://inwoproject.sourceforge.net "I will carry you through, hicking and screaming, and in the end you will thank me" - Tyler Durden [from "Fight Club"] |