101
Mamba
Re: How to use XOOPS tree?
  • 2023/7/23 8:27

  • Mamba

  • Moderator

  • Posts: 11366

  • Since: 2004/4/23


My mistake! My apologies!

It should be /xoopstree.php and not /tree.php

Please use this line:
require_once XOOPS_ROOT_PATH '/class/xoopstree.php';
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs



102
cadch
Re: How to use XOOPS tree?
  • 2023/7/21 14:33

  • cadch

  • Just popping in

  • Posts: 48

  • Since: 2007/12/17


I have a message
Error: Class "XoopsTree" not found

Can you help me



103
cadch
Re: How to use XOOPS tree?
  • 2023/7/21 11:38

  • cadch

  • Just popping in

  • Posts: 48

  • Since: 2007/12/17


Thank Mamba~



104
Mamba
Re: How to use XOOPS tree?
  • 2023/7/20 0:42

  • Mamba

  • Moderator

  • Posts: 11366

  • Since: 2004/4/23


To utilize the XOOPS tree structure for the given array, you can follow these steps:

1. Initialize the XOOPS Tree class:

require_once XOOPS_ROOT_PATH '/class/xoopstree.php';
$tree = new XoopsTree();


2. Define the XOOPS tree structure using the array:

$treeData = array(
    array(
'id' => 1'parent' => 0),
    array(
'id' => 2'parent' => 0),
    array(
'id' => 3'parent' => 0),
    array(
'id' => 4'parent' => 1),
    array(
'id' => 5'parent' => 4),
    array(
'id' => 6'parent' => 5)
);

foreach (
$treeData as $data) {
    
$tree->addNode($data['id'], $data['parent']);
}



3. Retrieve the tree structure using the XOOPS Tree class:

$treeStructure $tree->getChildTreeArray(0);


The `$treeStructure` variable will contain the hierarchical structure of the tree, starting from the root node with ID 0. You can then process and utilize this structure as per your requirements.
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs



105
zivXP
Re: Fatal error: Array and string offset access syntax with curly braces is no longer supported in /home
  • 2023/7/19 10:02

  • zivXP

  • Not too shy to talk

  • Posts: 113

  • Since: 2006/2/9 1


Quote:

Masxmas wrote:
It is the error that I get and I can not enter the xoops administration. Mark a file in php and the wrong line of code.


There is no such public_html/cms directory in xoops



106
Masxmas
Re: Fatal error: Array and string offset access syntax with curly braces is no longer supported in /home
  • 2023/7/18 14:30

  • Masxmas

  • Just popping in

  • Posts: 4

  • Since: 2023/7/8 2


It is the error that I get and I can not enter the xoops administration. Mark a file in php and the wrong line of code.



107
zivXP
Re: Fatal error: Array and string offset access syntax with curly braces is no longer supported in /home
  • 2023/7/18 6:52

  • zivXP

  • Not too shy to talk

  • Posts: 113

  • Since: 2006/2/9 1


Quote:

Masxmas wrote:
Fatal error: Array and string offset access syntax with curly braces is no longer supported in /home/midirecom/public_html/cms/class/file/folder.php on line 818

PHP 8.2


/cms/class/file/folder.php What is this?



108
Masxmas
Fatal error: Array and string offset access syntax with curly braces is no longer supported in /home
  • 2023/7/17 22:34

  • Masxmas

  • Just popping in

  • Posts: 4

  • Since: 2023/7/8 2


Fatal error: Array and string offset access syntax with curly braces is no longer supported in /home/midirecom/public_html/cms/class/file/folder.php on line 818

PHP 8.2



109
cadch
How to use XOOPS tree?
  • 2023/7/17 14:41

  • cadch

  • Just popping in

  • Posts: 48

  • Since: 2007/12/17


Hello~
My tree used
array(
array(
'id' => 1'parent' => 0),
array(
'id' => 2'parent' => 0),
array(
'id' => 3'parent' => 0),
array(
'id' => 4'parent' => 1),
array(
'id' => 5'parent' => 4),
array(
'id' => 6'parent' => 5)
);

How can I use XOOPS tree?



110
zivXP
Re: Create the "Test Constructor" module
  • 2023/7/10 20:23

  • zivXP

  • Not too shy to talk

  • Posts: 113

  • Since: 2006/2/9 1


Quote:

goffy wrote:
if you want to test quiz with XOOPS 2.5.11 RC2 then you can contact Mamba.
He has already updated a lot of modules to smarty 3, maybe he has also updated quiz module. if not I can do it.


Mamba wrote that he would update the modules as soon as he made a stable release of xoops. It will be very good.

I couldn't even figure out what functions this module has. Since the admin panel did not work. But judging by the tables used, there is not much functionality there.




TopTop
« 1 ... 8 9 10 (11) 12 13 14 ... 29422 »



Login

Who's Online

222 user(s) are online (149 user(s) are browsing Support Forums)


Members: 0


Guests: 222


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Apr 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits