xoops forums

Forum Index


Board index » All Posts (luciorota)




luciorota

Module Developer
Posted on: Yesterday 11:37
luciorota
luciorota (Show more)
Module Developer
Posts: 185
Since: 2007/4/20
#1

Re: Database: How do I set a column value to NULL

Hi Mamba
Everything checked

I think it is a Xoops limit...


luciorota

Module Developer
Posted on: 2018/12/14 22:15
luciorota
luciorota (Show more)
Module Developer
Posts: 185
Since: 2007/4/20
#2

Re: Database: How do I set a column value to NULL

Thanks Mamba
I would like to reset time_update value to NULL
When i use an expression like this:

$itemObj->setVar('myDate'NULL);


does note set 'MyDate' field to NULL but to '0000-00-00'
are there some tips to solve my question?

Thanks again


luciorota

Module Developer
Posted on: 2018/12/12 15:43
luciorota
luciorota (Show more)
Module Developer
Posts: 185
Since: 2007/4/20
#3

Database: How do I set a column value to NULL

I have a question.

I have to set a database column value to NULL but ...
My object is an extension of XoopsPersistableObject class.
Var 'date' data type is XOBJ_DTYPE_DATE
Database field is defines as
date DATE NULL DEFAULT NULL

Any suggestion?


luciorota

Module Developer
Posted on: 2018/12/3 15:54
luciorota
luciorota (Show more)
Module Developer
Posts: 185
Since: 2007/4/20
#4

FOREIGN KEY

Hi everybody
How can I set FOREIGN KEY on module tables when I use Xoops modules installation procedure?
Thanks
Lucio


luciorota

Module Developer
Posted on: 10/15 18:17
luciorota
luciorota (Show more)
Module Developer
Posts: 185
Since: 2007/4/20
#5

Smarty 3.1.33

Hi to everybody
why not update Xoops 2.5.10 Smarty version to 3.xx trunk?
I did not find compatibility problems in my tests.

Lucio


luciorota

Module Developer
Posted on: 9/12 20:12
luciorota
luciorota (Show more)
Module Developer
Posts: 185
Since: 2007/4/20
#6

Re: Xoops uploader

This code works

for ($i 0$i count($_FILES['files']['name']); $i++) {
    echo 
"[{$i}]";
    if (
$uploader->fetchMedia('files'$i)) {
        if (!
$uploader->upload()) {
            echo 
$uploader->getErrors();
        } else {
            echo 
'<h4>File uploaded successfully!</h4>';
            echo 
'Saved as: ' $uploader->getSavedFileName() . '<br>';
            echo 
'Full path: ' $uploader->getSavedDestination();
        }
    } else {
        echo 
$uploader->getErrors();
    }
}


luciorota

Module Developer
Posted on: 9/12 12:13
luciorota
luciorota (Show more)
Module Developer
Posts: 185
Since: 2007/4/20
#7

Xoops uploader

Hi
In my experience XoopsMediaUploader class does not support miltiple uploads.

For example, how can I upload files in this case?

...
$formFile = new XoopsFormFile('files''files[]'0);
$formFile->setExtra('multiple''multiple');
...


Someone can suggest me a solution?


luciorota

Module Developer
Posted on: 6/9 19:47
luciorota
luciorota (Show more)
Module Developer
Posts: 185
Since: 2007/4/20
#8

Re: Wfdownloads 3.30 Beta-1 for XOOPS 2.5.9 and PHP 5.6+

Hi
I fork to test but I cannot install.

Fatal error: Class 'WfdownloadsUtility' not found in C:\wamp64\www\xoops.259\modules\wfdownloads\include\oninstall.php on line 49



luciorota

Module Developer
Posted on: 2016/6/29 7:59
luciorota
luciorota (Show more)
Module Developer
Posts: 185
Since: 2007/4/20
#9

Re: Is there a working newsletter module?

this is my latest...
https://github.com/luciorota/xnewsletter


luciorota

Module Developer
Posted on: 2016/6/8 13:08
luciorota
luciorota (Show more)
Module Developer
Posts: 185
Since: 2007/4/20
#10

Re: strtotime in edit mod

Hi
In my latest modules I solved the date format problem using the php DateTime object in this way

in form ...
// set date in a timestamp format
$item_date = ...
// form datetime element
$form->addElement(new XoopsFormDateTime(_ITEM_DATE'item_date'15$this->getVar('item_date'), true));


in form request handler...
// get date in a timestamp format
$dateTimeObj DateTime::createFromFormat(_SHORTDATESTRING$_REQUEST['item_date']['date']);
$dateTimeObj->setTime(000);
// date timestamp
$item_date $dateTimeObj->getTimestamp() + $_REQUEST['item_date']['time'];
unset(
$dateTimeObj);


I think it's a solution that could work well

Bye Lucio



TopTop
(1) 2 3 4 ... 14 »