[ZendTo] Re: 4.11 working okay?

Artyom Aleksandrov mailing.list at tem4uk.ru
Mon Nov 19 14:51:58 GMT 2012


Five strings for postinst. If php5-sqlite does not support sqlite2, sed
change default data engine in preferences file.
In this case user don't get error during install.


## Apache restart before

# Check version of libsqlite use and change database engine if needed
libsqlite_check=`dpkg-query -W -f='${Depends}\n' php5-sqlite | grep
libsqlite0`
res_libsqlite=$?
if [ ! $res_libsqlite -eq 0 ]; then
    sed "s/^define('SqlBackend', 'SQLite')/define('SqlBackend',
'SQLite3')/" -i /opt/zendto/config/preferences.php
fi


### Setup all the stats logging below




On Mon, Nov 19, 2012 at 5:16 PM, Artyom Aleksandrov
<mailing.list at tem4uk.ru>wrote:

> I still got error ('Warning: SQLite3::exec(): table addressbook already
> exists in /opt/zendto/lib/SQLite3.php on line 345 ') with your SQLite3 from
> attach.
>
> So, I changed it again and  add function DBCheckTable($table).
> You can found patch, src file (from this tread) and patched file in attach.
>
>
>
> And another one problem in DBUpdateAddressbook().
>
> 1) First string
>   // SLASH $user =
> sqlite_escape_string($user);
>
>     $user = $this->database->escapeString($user);
>
> 2) End of func
>       $now = time();
>       $query = $this->database->exec(
>                  sprintf("INSERT INTO addressbook
> (username,name,email,lastused) VALUES ('%s','%s','%s','%d')",
>                  $user, $name, $email, $now));
>
> As I see 'lastused' set not NULL but in code INSERT do not use this.
> I do not include DBUPdateAddressbook in patch because do not understand
> exactly what it should do.
>
>
>
>
> On Mon, Nov 19, 2012 at 1:24 PM, Jules <Jules at zend.to> wrote:
>
>>
>> On 16/11/2012 16:19, Artyom Aleksandrov wrote:
>>
>> Hi,
>>
>> Today I tried last version from site  (4.11-1) on Ubuntu 12.04 with
>> sqlite3.
>> It's not good =(
>>
>> 1) After install from deb I got follow error:
>>
>> PHP Fatal error:  Class 'SQLiteDatabase' not found in
>> /opt/zendto/lib/SQLite.php on line 57
>>
>> Ok. 'postinst' script do not understand that I use sqlite3. It's not
>> seriously but not nice for user.
>> Just edit preference.conf for use SQlite3 and run dpkg-reconfigure.
>>
>> I can submit patch for 'postinst' here if you want.
>>
>> If you've got a change to postinst that would enable it to default to
>> SQLite3 on Ubuntu 12 or higher, that would be great, thanks! The postinst
>> script currently does not edit preferences.php *at all*, as you'll have to
>> edit it by hand anyway before things will work to insert your domain in
>> various places and set up the captcha keys.
>>
>>
>> 2) Ops! I catch next error:
>>
>> PHP Warning:  SQLite3::exec() expects exactly 1 parameter, 2 given in
>> /opt/zendto/lib/SQLite3.php on line 331
>> ...
>> PHP Fatal error:  Call to a member function writeToLog() on a non-object
>> in /opt/zendto/lib/SQLite3.php on line 78
>>
>> After fast comment this if statement with $query->columnType(0) ==
>> SQLITE3_NULL I can add user and login.
>>
>> I have already fixed those two, new (gzipped) SQLite3.php is attached.
>>
>> Cheers,
>> Jules.
>>
>>
>>
>>
>> So, it's not really good, I think. I'll continue test this case on next
>> week.
>>
>> Good weekends and thank you.
>>
>>
>>
>> On Mon, Oct 29, 2012 at 1:00 PM, Jules <Jules at zend.to> wrote:
>>
>>> There isn't at the moment, but I might change that, yes.
>>>
>>> At the moment, I'm afraid you'll have to stick to the betas and so on
>>> that I release via http://zend.to.
>>>
>>> Have you tried 4.11? If not, is there any way you could please?
>>> Many thanks!
>>>
>>> Jules.
>>>
>>> On 26/10/2012 19:31, Brendon Baumgartner wrote:
>>> > Is there an svn server we can connect to? Any plans for one if not?
>>> >
>>> > Sent from my SmartPhone
>>> >
>>> > On Oct 26, 2012, at 3:04, Jules <Jules at zend.to> wrote:
>>> >
>>> >> Have people tried the version 4.11 beta release I published?
>>> >> Does it work okay?
>>> >>
>>> >> I need confirmation that there aren't any show-stopping bugs in it
>>> >> before I release a "release" version of 4.11.
>>> >>
>>> >> Thanks all!
>>> >>
>>> >> Jules
>>> >>
>>> >> --
>>> >> Julian Field MEng MBCS CITP CEng
>>> >> www.Zend.To
>>> >>
>>> >> Twitter: @JulesFM
>>> >> PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415 B654
>>> >>
>>> >> 'A committee is a group of the unwilling, chosen from the unfit,
>>> >>   to do the unnecessary.' - Anon
>>> >>
>>> >> _______________________________________________
>>> >> ZendTo mailing list
>>> >> ZendTo at zend.to
>>> >> http://mailman.ecs.soton.ac.uk/mailman/listinfo/zendto
>>> > _______________________________________________
>>> > ZendTo mailing list
>>> > ZendTo at zend.to
>>> > http://mailman.ecs.soton.ac.uk/mailman/listinfo/zendto
>>> >
>>> > Jules
>>> >
>>> > --
>>> > Julian Field MEng MBCS CITP CEng
>>> > www.Zend.To
>>> >
>>> > Twitter: @JulesFM
>>> > PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415 B654
>>> >
>>>  > 'It's in Apple's DNA that technology alone is not enough. It's
>>> >   technology married with liberal arts, married with the humanities,
>>> >   that yields us the result that makes our hearts sing.' - Steve Jobs
>>>  _______________________________________________
>>> ZendTo mailing list
>>> ZendTo at zend.to
>>> http://mailman.ecs.soton.ac.uk/mailman/listinfo/zendto
>>>
>>
>>
>>
>> _______________________________________________
>> ZendTo mailing listZendTo at zend.tohttp://mailman.ecs.soton.ac.uk/mailman/listinfo/zendto
>>
>>
>> Jules
>>
>> --
>> Julian Field MEng MBCS CITP CEngwww.Zend.To
>>
>>
>> Twitter: @JulesFM
>> PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415 B654
>>
>> 'When a man points a finger at someone else, he should remember
>>  that four of his fingers are pointing at himself.' - Louis Nizer
>>
>>
>> _______________________________________________
>> ZendTo mailing list
>> ZendTo at zend.to
>> http://mailman.ecs.soton.ac.uk/mailman/listinfo/zendto
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ecs.soton.ac.uk/pipermail/zendto/attachments/20121119/275b8f0c/attachment.html 


More information about the ZendTo mailing list