james182 Posted January 15, 2009 Share Posted January 15, 2009 the expand / contract of my my won't work correctly and it adds itself again & again on every click [attachment deleted by admin] Link to comment https://forums.phpfreaks.com/topic/140897-menu-problem/ Share on other sites More sharing options...
lordphate Posted January 15, 2009 Share Posted January 15, 2009 Do you have a demo online so we know what is happening ? Link to comment https://forums.phpfreaks.com/topic/140897-menu-problem/#findComment-737477 Share on other sites More sharing options...
ngreenwood6 Posted January 15, 2009 Share Posted January 15, 2009 I think this should be in the ajax forum by looking at your test.php file. Link to comment https://forums.phpfreaks.com/topic/140897-menu-problem/#findComment-737479 Share on other sites More sharing options...
lordphate Posted January 15, 2009 Share Posted January 15, 2009 yes, jQuery is ajax, i would have to second that, as there is no PHP in the test.php... Link to comment https://forums.phpfreaks.com/topic/140897-menu-problem/#findComment-737485 Share on other sites More sharing options...
james182 Posted January 15, 2009 Author Share Posted January 15, 2009 look in the "jqueryFileTree.php" file then also here the DB dump. CREATE TABLE tbl_tree_menu ( treeview_id int(11) NOT NULL auto_increment, treeview_name varchar(155) NOT NULL, treeview_desc varchar(155) NOT NULL, treeview_ext varchar(4) NOT NULL, treeview_parent_id int(11) NOT NULL, PRIMARY KEY (treeview_id) ) TYPE=MyISAM AUTO_INCREMENT=79 ; -- -- Dumping data for table 'tbl_tree_menu' -- INSERT INTO tbl_tree_menu (treeview_id, treeview_name, treeview_desc, treeview_ext, treeview_parent_id) VALUES (1, 'root', 'folder', 0), (2, '1. Corporate', 'folder', 1), (3, '2. Divisional', 'folder', 1), (4, '1. Systems', 'folder', 2), (5, '2. Policies', 'folder', 2), (6, '3. Processes', 'folder', 2), (7, '4. Quality Assurance', 'folder', 2), (8, '5. Risk Management', 'folder', 2), (9, '6. Administration', 'folder', 2), (10, '1. Standards', 'folder', 7), (11, '2. Guidelines', 'folder', 7), (12, '3. Templates', 'folder', 7), (13, '4. Forms', 'folder', 7), (14, '5. Registers', 'folder', 7), (15, '1. Standards', 'folder', , (16, '2. Guidelines', 'folder', , (17, '3. Templates', 'folder', , (18, '4. Forms', 'folder', , (19, '5. Registers', 'folder', , (20, '1. General Administration', 'folder', 9), (21, '2. Human Resources', 'folder', 9), (22, '3. WH&S', 'folder', 9), (23, '4. Finance', 'folder', 9), (24, '5. IT', 'folder', 9), (25, '6. Legal', 'folder', 9), (26, '1. Civil', 'folder', 3), (27, '2. Structural', 'folder', 3), (28, '3. Hydraulic', 'folder', 3), (29, '4. Building', 'folder', 3), (30, '5. Telco', 'folder', 3), (31, '6. Project Management', 'folder', 3), (32, '7. Drafting', 'folder', 3), (33, '8. Cross Divisional General', 'folder', 3), (34, '1. Standards', 'folder', 26), (35, '2. Guidelines', 'folder', 26), (36, '3. Templates', 'folder', 26), (37, '4. Forms', 'folder', 26), (38, '5. Register', 'folder', 26), (39, '1. Standards', 'folder', 27), (40, '2. Guidelines', 'folder', 27), (41, '3. Templates', 'folder', 27), (42, '4. Forms', 'folder', 27), (43, '5. Registers', 'folder', 27), (44, '1. Standards', 'folder', 28), (45, '2. Guidelines', 'folder', 28), (46, '3. Templates', 'folder', 28), (47, '4. Forms', 'folder', 28), (48, '5. Registers', 'folder', 28), (49, '1. Standards', 'folder', 29), (50, '2. Guidelines', 'folder', 29), (51, '3. Templates', 'folder', 29), (52, '4. Forms', 'folder', 29), (53, '5. Registers', 'folder', 29), (54, '1. Standards', 'folder', 30), (55, '2. Guidelines', 'folder', 30), (56, '3. Templates', 'folder', 30), (57, '4. Forms', 'folder', 30), (58, '5. Registers', 'folder', 30), (59, '1. Standards', 'folder', 31), (60, '2. Guidelines', 'folder', 31), (61, '3. Templates', 'folder', 31), (62, '4. Forms', 'folder', 31), (63, '5. Registers', 'folder', 31), (64, '1. Standards', 'folder', 32), (65, '2. Guidelines', 'folder', 32), (66, '3. Templates', 'folder', 32), (67, '4. Forms', 'folder', 32), (68, '5. Registers', 'folder', 32), (69, '1. Standards', 'folder', 33), (70, '2. Guidelines', 'folder', 33), (71, '3. Templates', 'folder', 33), (72, '4. Forms', 'folder', 33), (73, '5. Registers', 'folder', 33); (74, 'MyDocument', 'document', 'doc', 4), (75, 'my Document 2', 'document', 'jpg', 4), (76, 'my Document 3', 'document', 'doc', 4), (77, 'My Testing', 'document', 'xls', 10), (78, 'My Dooda', 'document', 'xml', 10); Link to comment https://forums.phpfreaks.com/topic/140897-menu-problem/#findComment-737493 Share on other sites More sharing options...
lordphate Posted January 15, 2009 Share Posted January 15, 2009 James, there is nothing wrong with jQuery. this is an ajax issue. PLease open a thread there you'll get more help Link to comment https://forums.phpfreaks.com/topic/140897-menu-problem/#findComment-737496 Share on other sites More sharing options...
RussellReal Posted January 15, 2009 Share Posted January 15, 2009 you're saying it keeps adding the data below alrdy filled elements.. your onclick event handling function inside there do like theElement.innerHTML = ""; that way it empties the element before putting more content into it. Link to comment https://forums.phpfreaks.com/topic/140897-menu-problem/#findComment-737502 Share on other sites More sharing options...
james182 Posted January 15, 2009 Author Share Posted January 15, 2009 do you have an example, ta Link to comment https://forums.phpfreaks.com/topic/140897-menu-problem/#findComment-737517 Share on other sites More sharing options...
RussellReal Posted January 15, 2009 Share Posted January 15, 2009 whatever element your ajax is filling.. thats the element you set it's property .innerHTML to "" Link to comment https://forums.phpfreaks.com/topic/140897-menu-problem/#findComment-737533 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.