Chicken-run Manager
Posts: 9
58 credits Members referred : 0
« Reply #22 on: Jun 18, 2008, 03:35:16 pm »
UNTESTED CODE!!!
With the prevois Version of my code, Passwords would have been updated to plaintext. That's not what we want. So let's try this:
Code:
<?php
/* * Updates a property. Data must be in the form 'property' => 'value' * @param array * @return bool */ public function updateProperty($properties) { if(is_array($properties) && count($properties) > 1) { $i=1; $query = "UPDATE `".$this->dbTable."` SET ";
« Last Edit: Jun 18, 2008, 04:50:46 pm by Downlord »
OMG!I am geek
Gender:
Posts: 50
312 credits Members referred : 0
in a world of php
« Reply #23 on: Sep 30, 2008, 04:27:32 pm »
hi first of all id like to say great work to nick and all others who may of helped. its great to see a open source project going along nice n strong as i am creating a smalled based cms which will b open sourced to.
i was wondering if are u able to post a basic example of the updateProperty() function please.
it mite just b because its heading 11.30pm here or i just cant figured it out, any help would b much grateful Ty in advanced
I am a metal monkey!
Administrator Community Supporter?
Jedai Sword Master
Gender:
Posts: 5657
45575 credits Members referred : 3
« Reply #24 on: Sep 30, 2008, 06:26:38 pm »
It should get an array which has the form :
'tableField' => 'newValue'
But please check it out because none has tested this function (but in the next version it will be working anyway)
OMG!I am geek
Gender:
Posts: 50
312 credits Members referred : 0
in a world of php
updateProperty works
« Reply #25 on: Oct 05, 2008, 03:08:21 pm »
i have had a play around with the updateProperty function a bit and it seems to only work when u give it a full case of arrays, not just a single case. ill post a little example to help with the explaining.