[Loris-dev] Fwd: LORIS Document Repository

Ganesh Chauhan (CBR) ganesh.chauhan at cbr.iisc.ac.in
Wed Jul 5 00:17:39 EDT 2017


Dear Shen, 

Excellent. I made the changes you suggested and it works for me. Now I can add a category and upload files. 
Many thanks. 

With best regards, 
Ganesh 


From: "Shen Wang" <wangshen.mcin at gmail.com> 
To: "Ganesh Chauhan, CBR" <ganesh.chauhan at cbr.iisc.ac.in> 
Cc: "Bonhwang Koo" <Bonhwang.Koo at childmind.org>, "Samir Das" <samir.das at mcgill.ca>, "loris-dev" <Loris-dev at bic.mni.mcgill.ca> 
Sent: Wednesday, July 5, 2017 12:58:43 AM 
Subject: Re: [Loris-dev] Fwd: LORIS Document Repository 

Hi Bonhwang, Ganesh 

Thank you for helping me debug this issue. This is a bug. After Loris updates from MySQL 5.6 to MySQL 5.7, 
The null data can not insert into the database. It causes the 500 error. And I have fixed it, 
" [ https://github.com/aces/Loris/pull/2924 | https://github.com/aces/Loris/pull/2924 ] " this is my pull request to fix the issue. It is waiting to test and merge. 
You could update your Loris manually or wait for new Loris release. 

Thank guys! 

Best regards 
Shen 

On 4 July 2017 at 04:48, Ganesh Chauhan (CBR) < [ mailto:ganesh.chauhan at cbr.iisc.ac.in | ganesh.chauhan at cbr.iisc.ac.in ] > wrote: 



Hi, 

The errors that I got are as follows: 

[Tue Jul 04 14:12:59.397979 2017] [:error] [pid 4223] [client [ http://10.150.10.76:45030/ | MailScanner warning: numerical links are often malicious: 10.150.10.76:45030 ] ] PHP Notice: Undefined index: openAccordion in /var/www/lorisinstall/Loris/modules/document_repository/php/NDB_Menu_Filter_document_repository.class.inc on line 61, referer: [ http://alzheimersproject.cns.iisc.ac.in/main.php | http://alzheimersproject.cns.iisc.ac.in/main.php ] ? 
[Tue Jul 04 14:12:59.398064 2017] [:error] [pid 4223] [client [ http://10.150.10.76:45030/ | MailScanner warning: numerical links are often malicious: 10.150.10.76:45030 ] ] PHP Notice: Undefined index: filtered in /var/www/lorisinstall/Loris/modules/document_repository/php/NDB_Menu_Filter_document_repository.class.inc on line 63, referer: [ http://alzheimersproject.cns.iisc.ac.in/main.php | http://alzheimersproject.cns.iisc.ac.in/main.php ] ? 
[Tue Jul 04 14:12:59.446023 2017] [:error] [pid 4223] [client [ http://10.150.10.76:45030/ | MailScanner warning: numerical links are often malicious: 10.150.10.76:45030 ] ] PHP Notice: Undefined variable: fileCategories in /var/www/lorisinstall/Loris/modules/document_repository/php/NDB_Menu_Filter_document_repository.class.inc on line 125, referer: [ http://alzheimersproject.cns.iisc.ac.in/main.php | http://alzheimersproject.cns.iisc.ac.in/main.php ] ? 
[Tue Jul 04 14:12:59.447476 2017] [:error] [pid 4223] [client [ http://10.150.10.76:45030/ | MailScanner warning: numerical links are often malicious: 10.150.10.76:45030 ] ] PHP Warning: Invalid argument supplied for foreach() in /var/www/lorisinstall/Loris/modules/document_repository/php/NDB_Menu_Filter_document_repository.class.inc on line 152, referer: [ http://alzheimersproject.cns.iisc.ac.in/main.php | http://alzheimersproject.cns.iisc.ac.in/main.php ] ? 
[Tue Jul 04 14:12:59.447527 2017] [:error] [pid 4223] [client [ http://10.150.10.76:45030/ | MailScanner warning: numerical links are often malicious: 10.150.10.76:45030 ] ] PHP Notice: Undefined variable: fileCategories in /var/www/lorisinstall/Loris/modules/document_repository/php/NDB_Menu_Filter_document_repository.class.inc on line 261, referer: [ http://alzheimersproject.cns.iisc.ac.in/main.php | http://alzheimersproject.cns.iisc.ac.in/main.php ] ? 
[Tue Jul 04 14:12:59.462133 2017] [:error] [pid 4223] [client [ http://10.150.10.76:45030/ | MailScanner warning: numerical links are often malicious: 10.150.10.76:45030 ] ] PHP Warning: Invalid argument supplied for foreach() in /var/www/lorisinstall/Loris/php/libraries/LorisForm.class.inc on line 685, referer: [ http://alzheimersproject.cns.iisc.ac.in/main.php | http://alzheimersproject.cns.iisc.ac.in/main.php ] ? 
[Tue Jul 04 14:13:14.657022 2017] [:error] [pid 4715] [client [ http://10.150.10.76:45036/ | MailScanner warning: numerical links are often malicious: 10.150.10.76:45036 ] ] PHP Notice: A session had already been started - ignoring session_start() in /var/www/lorisinstall/Loris/php/libraries/NDB_Client.class.inc on line 122, referer: [ http://alzheimersproject.cns.iisc.ac.in/document_repository/ | http://alzheimersproject.cns.iisc.ac.in/document_repository/ ] 
[Tue Jul 04 14:13:14.657118 2017] [:error] [pid 4715] [client [ http://10.150.10.76:45036/ | MailScanner warning: numerical links are often malicious: 10.150.10.76:45036 ] ] PHP Notice: Undefined variable: comments in /var/www/lorisinstall/Loris/modules/document_repository/ajax/addCategory.php on line 60, referer: [ http://alzheimersproject.cns.iisc.ac.in/document_repository/ | http://alzheimersproject.cns.iisc.ac.in/document_repository/ ] 
[Tue Jul 04 14:13:14.657489 2017] [:error] [pid 4715] [client [ http://10.150.10.76:45036/ | MailScanner warning: numerical links are often malicious: 10.150.10.76:45036 ] ] PHP Warning: PDOStatement::execute(): SQLSTATE[HY000]: General error: 1366 Incorrect integer value: ' ' for column 'parent_id' at row 1 in /var/www/lorisinstall/Loris/php/libraries/Database.class.inc on line 312, referer: [ http://alzheimersproject.cns.iisc.ac.in/document_repository/ | http://alzheimersproject.cns.iisc.ac.in/document_repository/ ] 
[Tue Jul 04 14:13:14.666803 2017] [:error] [pid 4715] [client [ http://10.150.10.76:45036/ | MailScanner warning: numerical links are often malicious: 10.150.10.76:45036 ] ] Could not execute INSERT INTO document_repository_categories SET `category_name`=:category_name,`parent_id`=:parent_id,`comments`=:comments. Stack trace#0 /var/www/lorisinstall/Loris/php/libraries/Database.class.inc(243): Database->_realinsert('document_reposi...', Array, true)\n#1 /var/www/lorisinstall/Loris/modules/document_repository/ajax/addCategory.php(60): Database->insert('document_reposi...', Array)\n#2 /var/www/lorisinstall/Loris/htdocs/AjaxHelper.php(93): require('/var/www/lorisi...')\n#3 {main}, referer: [ http://alzheimersproject.cns.iisc.ac.in/document_repository/ | http://alzheimersproject.cns.iisc.ac.in/document_repository/ ] 
[Tue Jul 04 14:13:14.666897 2017] [:error] [pid 4715] [client [ http://10.150.10.76:45036/ | MailScanner warning: numerical links are often malicious: 10.150.10.76:45036 ] ] PHP Fatal error: Uncaught DatabaseException: Insert statement did not execute successfully: Array\n(\n [0] => HY000\n [1] => 1366\n [2] => Incorrect integer value: ' ' for column 'parent_id' at row 1\n)\n in /var/www/lorisinstall/Loris/php/libraries/Database.class.inc:314\nStack trace:\n#0 /var/www/lorisinstall/Loris/php/libraries/Database.class.inc(243): Database->_realinsert('document_reposi...', Array, true)\n#1 /var/www/lorisinstall/Loris/modules/document_repository/ajax/addCategory.php(60): Database->insert('document_reposi...', Array)\n#2 /var/www/lorisinstall/Loris/htdocs/AjaxHelper.php(93): require('/var/www/lorisi...')\n#3 {main}\n thrown in /var/www/lorisinstall/Loris/php/libraries/Database.class.inc on line 314, referer: [ http://alzheimersproject.cns.iisc.ac.in/document_repository/ | http://alzheimersproject.cns.iisc.ac.in/document_repository/ ] 
[Tue Jul 04 14:13:16.091641 2017] [:error] [pid 4716] [client [ http://10.150.10.76:45038/ | MailScanner warning: numerical links are often malicious: 10.150.10.76:45038 ] ] PHP Notice: A session had already been started - ignoring session_start() in /var/www/lorisinstall/Loris/php/libraries/NDB_Client.class.inc on line 122, referer: [ http://alzheimersproject.cns.iisc.ac.in/document_repository/ | http://alzheimersproject.cns.iisc.ac.in/document_repository/ ] 
[Tue Jul 04 14:13:16.091692 2017] [:error] [pid 4716] [client [ http://10.150.10.76:45038/ | MailScanner warning: numerical links are often malicious: 10.150.10.76:45038 ] ] PHP Notice: Undefined variable: comments in /var/www/lorisinstall/Loris/modules/document_repository/ajax/addCategory.php on line 60, referer: [ http://alzheimersproject.cns.iisc.ac.in/document_repository/ | http://alzheimersproject.cns.iisc.ac.in/document_repository/ ] 
[Tue Jul 04 14:13:16.091878 2017] [:error] [pid 4716] [client [ http://10.150.10.76:45038/ | MailScanner warning: numerical links are often malicious: 10.150.10.76:45038 ] ] PHP Warning: PDOStatement::execute(): SQLSTATE[HY000]: General error: 1366 Incorrect integer value: ' ' for column 'parent_id' at row 1 in /var/www/lorisinstall/Loris/php/libraries/Database.class.inc on line 312, referer: [ http://alzheimersproject.cns.iisc.ac.in/document_repository/ | http://alzheimersproject.cns.iisc.ac.in/document_repository/ ] 
[Tue Jul 04 14:13:16.091930 2017] [:error] [pid 4716] [client [ http://10.150.10.76:45038/ | MailScanner warning: numerical links are often malicious: 10.150.10.76:45038 ] ] Could not execute INSERT INTO document_repository_categories SET `category_name`=:category_name,`parent_id`=:parent_id,`comments`=:comments. Stack trace#0 /var/www/lorisinstall/Loris/php/libraries/Database.class.inc(243): Database->_realinsert('document_reposi...', Array, true)\n#1 /var/www/lorisinstall/Loris/modules/document_repository/ajax/addCategory.php(60): Database->insert('document_reposi...', Array)\n#2 /var/www/lorisinstall/Loris/htdocs/AjaxHelper.php(93): require('/var/www/lorisi...')\n#3 {main}, referer: [ http://alzheimersproject.cns.iisc.ac.in/document_repository/ | http://alzheimersproject.cns.iisc.ac.in/document_repository/ ] 
[Tue Jul 04 14:13:16.091969 2017] [:error] [pid 4716] [client [ http://10.150.10.76:45038/ | MailScanner warning: numerical links are often malicious: 10.150.10.76:45038 ] ] PHP Fatal error: Uncaught DatabaseException: Insert statement did not execute successfully: Array\n(\n [0] => HY000\n [1] => 1366\n [2] => Incorrect integer value: ' ' for column 'parent_id' at row 1\n)\n in /var/www/lorisinstall/Loris/php/libraries/Database.class.inc:314\nStack trace:\n#0 /var/www/lorisinstall/Loris/php/libraries/Database.class.inc(243): Database->_realinsert('document_reposi...', Array, true)\n#1 /var/www/lorisinstall/Loris/modules/document_repository/ajax/addCategory.php(60): Database->insert('document_reposi...', Array)\n#2 /var/www/lorisinstall/Loris/htdocs/AjaxHelper.php(93): require('/var/www/lorisi...')\n#3 {main}\n thrown in /var/www/lorisinstall/Loris/php/libraries/Database.class.inc on line 314, referer: [ http://alzheimersproject.cns.iisc.ac.in/document_repository/ | http://alzheimersproject.cns.iisc.ac.in/document_repository/ ] 


Thanks for your help. 

With best reagrds, 
Ganesh 


From: "Bonhwang Koo" < [ mailto:Bonhwang.Koo at childmind.org | Bonhwang.Koo at childmind.org ] > 
To: "Shen Wang" < [ mailto:wangshen.mcin at gmail.com | wangshen.mcin at gmail.com ] > 
Cc: "Ganesh Chauhan, CBR" < [ mailto:ganesh.chauhan at cbr.iisc.ac.in | ganesh.chauhan at cbr.iisc.ac.in ] >, "Samir Das" < [ mailto:samir.das at mcgill.ca | samir.das at mcgill.ca ] >, "loris-dev" < [ mailto:Loris-dev at bic.mni.mcgill.ca | Loris-dev at bic.mni.mcgill.ca ] > 
Sent: Monday, July 3, 2017 11:51:33 PM 

Subject: Re: [Loris-dev] Fwd: LORIS Document Repository 



Here’s the error message: 



[Mon Jul 03 18:06:11.093590 2017] [:error] [pid 19414] [client [ http://67.220.146.162:22132/ | MailScanner warning: numerical links are often malicious: 67.220.146.162:22132 ] ] PHP Notice: Undefined variable: fileCategories in /var/www/loris/modules/document_repository/php/NDB_Menu_Filter_document_repository.class.inc on line 125, referer: [ http://data.healthybrainnetwork.org/document_repository/ | http://data.healthybrainnetwork.org/document_repository/ ] 

[Mon Jul 03 18:06:11.093883 2017] [:error] [pid 19414] [client [ http://67.220.146.162:22132/ | MailScanner warning: numerical links are often malicious: 67.220.146.162:22132 ] ] PHP Notice: Undefined variable: tree in /var/www/loris/modules/document_repository/php/NDB_Menu_Filter_document_repository.class.inc on line 244, referer: [ http://data.healthybrainnetwork.org/document_repository/ | http://data.healthybrainnetwork.org/document_repository/ ] 

[Mon Jul 03 18:06:11.093897 2017] [:error] [pid 19414] [client [ http://67.220.146.162:22132/ | MailScanner warning: numerical links are often malicious: 67.220.146.162:22132 ] ] PHP Warning: Invalid argument supplied for foreach() in /var/www/loris/modules/document_repository/php/NDB_Menu_Filter_document_repository.class.inc on line 152, referer: [ http://data.healthybrainnetwork.org/document_repository/ | http://data.healthybrainnetwork.org/document_repository/ ] 

[Mon Jul 03 18:06:11.093903 2017] [:error] [pid 19414] [client [ http://67.220.146.162:22132/ | MailScanner warning: numerical links are often malicious: 67.220.146.162:22132 ] ] PHP Notice: Undefined variable: fileCategories in /var/www/loris/modules/document_repository/php/NDB_Menu_Filter_document_repository.class.inc on line 261, referer: [ http://data.healthybrainnetwork.org/document_repository/ | http://data.healthybrainnetwork.org/document_repository/ ] 

[Mon Jul 03 18:06:11.099870 2017] [:error] [pid 19414] [client [ http://67.220.146.162:22132/ | MailScanner warning: numerical links are often malicious: 67.220.146.162:22132 ] ] PHP Warning: Invalid argument supplied for foreach() in /var/www/loris/php/libraries/LorisForm.class.inc on line 685, referer: [ http://data.healthybrainnetwork.org/document_repository/ | http://data.healthybrainnetwork.org/document_repository/ ] 

[Mon Jul 03 18:06:23.562950 2017] [:error] [pid 3629] [client [ http://67.220.146.162:48512/ | MailScanner warning: numerical links are often malicious: 67.220.146.162:48512 ] ] PHP Notice: A session had already been started - ignoring session_start() in /var/www/loris/php/libraries/NDB_Client.class.inc on line 122, referer: [ http://data.healthybrainnetwork.org/document_repository/?filtered=true | http://data.healthybrainnetwork.org/document_repository/?filtered=true ] 

[Mon Jul 03 18:06:23.562988 2017] [:error] [pid 3629] [client [ http://67.220.146.162:48512/ | MailScanner warning: numerical links are often malicious: 67.220.146.162:48512 ] ] PHP Notice: Undefined variable: comments in /var/www/loris/modules/document_repository/ajax/addCategory.php on line 60, referer: [ http://data.healthybrainnetwork.org/document_repository/?filtered=true | http://data.healthybrainnetwork.org/document_repository/?filtered=true ] 

[Mon Jul 03 18:06:23.563178 2017] [:error] [pid 3629] [client [ http://67.220.146.162:48512/ | MailScanner warning: numerical links are often malicious: 67.220.146.162:48512 ] ] PHP Warning: PDOStatement::execute(): SQLSTATE[HY000]: General error: 1366 Incorrect integer value: ' ' for column 'parent_id' at row 1 in /var/www/loris/php/libraries/Database.class.inc on line 312, referer: [ http://data.healthybrainnetwork.org/document_repository/?filtered=true | http://data.healthybrainnetwork.org/document_repository/?filtered=true ] 

[Mon Jul 03 18:06:23.563229 2017] [:error] [pid 3629] [client [ http://67.220.146.162:48512/ | MailScanner warning: numerical links are often malicious: 67.220.146.162:48512 ] ] Could not execute INSERT INTO document_repository_categories SET `category_name`=:category_name,`parent_id`=:parent_id,`comments`=:comments. Stack trace#0 /var/www/loris/php/libraries/Database.class.inc(243): Database->_realinsert('document_reposi...', Array, true)\n#1 /var/www/loris/modules/document_repository/ajax/addCategory.php(60): Database->insert('document_reposi...', Array)\n#2 /var/www/loris/htdocs/AjaxHelper.php(93): require('/var/www/loris/...')\n#3 {main}, referer: [ http://data.healthybrainnetwork.org/document_repository/?filtered=true | http://data.healthybrainnetwork.org/document_repository/?filtered=true ] 

[Mon Jul 03 18:06:23.563249 2017] [:error] [pid 3629] [client [ http://67.220.146.162:48512/ | MailScanner warning: numerical links are often malicious: 67.220.146.162:48512 ] ] PHP Fatal error: Uncaught DatabaseException: Insert statement did not execute successfully: Array\n(\n [0] => HY000\n [1] => 1366\n [2] => Incorrect integer value: ' ' for column 'parent_id' at row 1\n)\n in /var/www/loris/php/libraries/Database.class.inc:314\nStack trace:\n#0 /var/www/loris/php/libraries/Database.class.inc(243): Database->_realinsert('document_reposi...', Array, true)\n#1 /var/www/loris/modules/document_repository/ajax/addCategory.php(60): Database->insert('document_reposi...', Array)\n#2 /var/www/loris/htdocs/AjaxHelper.php(93): require('/var/www/loris/...')\n#3 {main}\n thrown in /var/www/loris/php/libraries/Database.class.inc on line 314, referer: [ http://data.healthybrainnetwork.org/document_repository/?filtered=true | http://data.healthybrainnetwork.org/document_repository/?filtered=true ] 



I tried the second suggestion as well—the “test” category shows up in the document repository, but when I try to add a file, it takes me to a broken link (document_repository/ajax/documentEditUpload.php), and the error log gives me the following message: 



[Mon Jul 03 18:17:27.494508 2017] [:error] [pid 14300] [client [ http://67.220.146.162:39842/ | MailScanner warning: numerical links are often malicious: 67.220.146.162:39842 ] ] PHP Notice: Only variables should be passed by reference in /var/www/loris/modules/document_repository/ajax/documentEditUpload.php on line 39, referer: [ http://data.healthybrainnetwork.org/document_repository/ | http://data.healthybrainnetwork.org/document_repository/ ] 

[Mon Jul 03 18:17:27.494866 2017] [:error] [pid 14300] [client [ http://67.220.146.162:39842/ | MailScanner warning: numerical links are often malicious: 67.220.146.162:39842 ] ] PHP Warning: PDOStatement::execute(): SQLSTATE[HY000]: General error: 1366 Incorrect integer value: '' for column 'For_site' at row 1 in /var/www/loris/php/libraries/Database.class.inc on line 312, referer: [ http://data.healthybrainnetwork.org/document_repository/ | http://data.healthybrainnetwork.org/document_repository/ ] 

[Mon Jul 03 18:17:27.494920 2017] [:error] [pid 14300] [client [ http://67.220.146.162:39842/ | MailScanner warning: numerical links are often malicious: 67.220.146.162:39842 ] ] Could not execute INSERT INTO document_repository SET `File_category`=:File_category,`For_site`=:For_site,`comments`=:comments,`version`=:version,`File_name`=:File_name,`File_size`=:File_size,`Data_dir`=:Data_dir,`uploaded_by`=:uploaded_by,`Instrument`=:Instrument,`PSCID`=:PSCID,`visitLabel`=:visitLabel,`File_type`=:File_type. Stack trace#0 /var/www/loris/php/libraries/Database.class.inc(243): Database->_realinsert('document_reposi...', Array, true)\n#1 /var/www/loris/modules/document_repository/ajax/documentEditUpload.php(61): Database->insert('document_reposi...', Array)\n#2 /var/www/loris/htdocs/AjaxHelper.php(93): require('/var/www/loris/...')\n#3 {main}, referer: [ http://data.healthybrainnetwork.org/document_repository/ | http://data.healthybrainnetwork.org/document_repository/ ] 

[Mon Jul 03 18:17:27.494941 2017] [:error] [pid 14300] [client [ http://67.220.146.162:39842/ | MailScanner warning: numerical links are often malicious: 67.220.146.162:39842 ] ] PHP Fatal error: Uncaught DatabaseException: Insert statement did not execute successfully: Array\n(\n [0] => HY000\n [1] => 1366\n [2] => Incorrect integer value: '' for column 'For_site' at row 1\n)\n in /var/www/loris/php/libraries/Database.class.inc:314\nStack trace:\n#0 /var/www/loris/php/libraries/Database.class.inc(243): Database->_realinsert('document_reposi...', Array, true)\n#1 /var/www/loris/modules/document_repository/ajax/documentEditUpload.php(61): Database->insert('document_reposi...', Array)\n#2 /var/www/loris/htdocs/AjaxHelper.php(93): require('/var/www/loris/...')\n#3 {main}\n thrown in /var/www/loris/php/libraries/Database.class.inc on line 314, referer: [ http://data.healthybrainnetwork.org/document_repository/ | http://data.healthybrainnetwork.org/document_repository/ ] 






-- 

Bonhwang Koo 

Research Assistant, CDB 

Child Mind Institute 

[ http://childmind.org/ | childmind.org ] 

445 Park Avenue (entrance on 56th Street) 

New York, NY 10022 

E: [ mailto:Bonhwang.Koo at childmind.org | Bonhwang.Koo at childmind.org ] 

p: [ tel:(646)%20625-4398 | 646.625.4398 ] 

f: [ tel:(646)%20625-4348 | 646.625.4348 ] 



Facebook: [ http://facebook.com/ChildMindInstitute | facebook.com/ChildMindInstitute ] | Follow us on Twitter: [ http://twitter.com/ChildMindDotOrg | twitter.com/ChildMindDotOrg ] 



--- 




This email message, including any attachments, is for the sole use of the intended recipient(s) and may contain information that is proprietary, confidential, and exempt from disclosure under applicable law. Any unauthorized review, use, disclosure, or distribution is prohibited. If you have received this email in error please notify the sender by return email and delete the original message. Please note, the recipient should check this email and any attachments for the presence of viruses. The organization accepts no liability for any damage caused by any virus transmitted by this email. 




From: Shen Wang < [ mailto:wangshen.mcin at gmail.com | wangshen.mcin at gmail.com ] > 
Date: Monday, July 3, 2017 at 2:07 PM 
To: Bonhwang Koo < [ mailto:Bonhwang.Koo at childmind.org | Bonhwang.Koo at childmind.org ] > 
Cc: "Ganesh Chauhan (CBR)" < [ mailto:ganesh.chauhan at cbr.iisc.ac.in | ganesh.chauhan at cbr.iisc.ac.in ] >, Samir Das < [ mailto:samir.das at mcgill.ca | samir.das at mcgill.ca ] >, loris-dev < [ mailto:Loris-dev at bic.mni.mcgill.ca | Loris-dev at bic.mni.mcgill.ca ] > 
Subject: Re: [Loris-dev] Fwd: LORIS Document Repository 





Hi Bonhwang, 





I tested Loris 17.0 on my VM, it works fine. It is difficult to debug without error log. 


Could you show me more error log or error message ? 


1, Run "sudo tail -f /var/log/apache2/loris-error.log" when you add a category. Please show me the message. 


2, Or Run "insert into document_repository_categories (id,category_name,parent_id,comments) values('777','test','0',null)" in your loris database. You should see the new test category. Then try upload a file under test category. Tell me the result. 





Best wishes 





On 3 July 2017 at 11:08, Shen Wang < [ mailto:wangshen.mcin at gmail.com | wangshen.mcin at gmail.com ] > wrote: 
BQ_BEGIN



Hi Ganesh 


You can get the "Document Repository" module functional without email server. 


Could you show me the error log or error message when you want to add a category? 





Shen 





On 3 July 2017 at 10:14, Bonhwang Koo < [ mailto:Bonhwang.Koo at childmind.org | Bonhwang.Koo at childmind.org ] > wrote: 
BQ_BEGIN



17.0.3 




-- 

Bonhwang Koo 

Research Assistant, CDB 

Child Mind Institute 

[ http://childmind.org/ | childmind.org ] 

445 Park Avenue (entrance on 56th Street) 

New York, NY 10022 

E: [ mailto:Bonhwang.Koo at childmind.org | Bonhwang.Koo at childmind.org ] 

p: [ tel:(646)%20625-4398 | 646.625.4398 ] 

f: [ tel:(646)%20625-4348 | 646.625.4348 ] 



Facebook: [ http://facebook.com/ChildMindInstitute | facebook.com/ChildMindInstitute ] | Follow us on Twitter: [ http://twitter.com/ChildMindDotOrg | twitter.com/ChildMindDotOrg ] 



--- 




This email message, including any attachments, is for the sole use of the intended recipient(s) and may contain information that is proprietary, confidential, and exempt from disclosure under applicable law. Any unauthorized review, use, disclosure, or distribution is prohibited. If you have received this email in error please notify the sender by return email and delete the original message. Please note, the recipient should check this email and any attachments for the presence of viruses. The organization accepts no liability for any damage caused by any virus transmitted by this email. 




From: Shen Wang < [ mailto:wangshen.mcin at gmail.com | wangshen.mcin at gmail.com ] > 
Date: Monday, July 3, 2017 at 10:04 AM 
To: Bonhwang Koo < [ mailto:Bonhwang.Koo at childmind.org | Bonhwang.Koo at childmind.org ] > 
Cc: "Ganesh Chauhan (CBR)" < [ mailto:ganesh.chauhan at cbr.iisc.ac.in | ganesh.chauhan at cbr.iisc.ac.in ] >, Samir Das < [ mailto:samir.das at mcgill.ca | samir.das at mcgill.ca ] >, loris-dev < [ mailto:Loris-dev at bic.mni.mcgill.ca | Loris-dev at bic.mni.mcgill.ca ] > 



Subject: Re: [Loris-dev] Fwd: LORIS Document Repository 





Hi 


Could you tell me which version of Loris do you have? I will check it. 





Best wishes 


Shen 





On 29 June 2017 at 17:03, Bonhwang Koo < [ mailto:Bonhwang.Koo at childmind.org | Bonhwang.Koo at childmind.org ] > wrote: 
BQ_BEGIN



I followed your suggestion, although I ran the command for a slightly different directory: “sudo chmod 777 /var/www/loris/modules/document_repository/user_uploads”, and I still have the same issue. This isn’t working even though I have a mail server installed via PostFix. I took a look at the console on my browser, and this is the error I’m getting: 









This is the corresponding code in document_repository_helper.js:89 : 

$.ajax( { 

url: loris.BaseURL + "/document_repository/ajax/addCategory.php" , 

type: "POST" , 

data: $( "#addCategoryForm" ).serialize(), 

success: function () { 

$( "#addCategoryModal" ).modal( 'hide' ); 

$( "#addCategoryCategory" ).removeClass( "has-error" ); 

$( "#categoryAddError" ).hide(); 

$( '.add-success' ).show(); 

setTimeout( function () { 

$( '.add-success' ).hide(); 

} , 3000); 

setTimeout( function () { 

location .reload(); 

} , 3000); 

} , 

error: function (jqXHR, textStatus, errorThrown) { 

if (jqXHR. status === 400) { 

$( "#addCategoryCategory" ).addClass( "has-error" ); 

$( "#categoryAddError" ).show() 

} 

} 

} ); 








-- 

Bonhwang Koo 

Research Assistant, CDB 

Child Mind Institute 

[ http://childmind.org/ | childmind.org ] 

445 Park Avenue (entrance on 56th Street) 

New York, NY 10022 

E: [ mailto:Bonhwang.Koo at childmind.org | Bonhwang.Koo at childmind.org ] 

p: [ tel:(646)%20625-4398 | 646.625.4398 ] 

f: [ tel:(646)%20625-4348 | 646.625.4348 ] 



Facebook: [ http://facebook.com/ChildMindInstitute | facebook.com/ChildMindInstitute ] | Follow us on Twitter: [ http://twitter.com/ChildMindDotOrg | twitter.com/ChildMindDotOrg ] 



--- 




This email message, including any attachments, is for the sole use of the intended recipient(s) and may contain information that is proprietary, confidential, and exempt from disclosure under applicable law. Any unauthorized review, use, disclosure, or distribution is prohibited. If you have received this email in error please notify the sender by return email and delete the original message. Please note, the recipient should check this email and any attachments for the presence of viruses. The organization accepts no liability for any damage caused by any virus transmitted by this email. 




From: "Ganesh Chauhan (CBR)" < [ mailto:ganesh.chauhan at cbr.iisc.ac.in | ganesh.chauhan at cbr.iisc.ac.in ] > 
Date: Thursday, June 29, 2017 at 12:21 AM 
To: Shen Wang < [ mailto:wangshen.mcin at gmail.com | wangshen.mcin at gmail.com ] > 
Cc: Samir Das < [ mailto:samir.das at mcgill.ca | samir.das at mcgill.ca ] >, loris-dev < [ mailto:Loris-dev at bic.mni.mcgill.ca | Loris-dev at bic.mni.mcgill.ca ] >, Bonhwang Koo < [ mailto:Bonhwang.Koo at childmind.org | Bonhwang.Koo at childmind.org ] > 



Subject: Re: [Loris-dev] Fwd: LORIS Document Repository 





Hi, 





I have had the same problem of not being able to add a category despite having file permissions. 


Though I still do not have the email server setup for LORIS. Hence do you think that without the email server we cannot get the "Document Repository" module functional. 





Thanks for your suggestion. 





With best regards, 


Ganesh 






From: "Shen Wang" < [ mailto:wangshen.mcin at gmail.com | wangshen.mcin at gmail.com ] > 
To: "Samir Das" < [ mailto:samir.das at mcgill.ca | samir.das at mcgill.ca ] > 
Cc: "loris-dev" < [ mailto:Loris-dev at bic.mni.mcgill.ca | Loris-dev at bic.mni.mcgill.ca ] >, "Bonhwang Koo" < [ mailto:Bonhwang.Koo at childmind.org | Bonhwang.Koo at childmind.org ] > 
Sent: Thursday, June 29, 2017 12:52:48 AM 
Subject: Re: [Loris-dev] Fwd: LORIS Document Repository 





Hello: 


Maybe you need to have file system permission to create the upload directory. 


I think It is not a Loris issue. 


As a quick fix, you can do: "sudo chmod 777 /var/www/loris/ document_repository/user_uploads". 


/var/www/loris/ will be replaced by your loris directory. 


I hope this can help you. 





Shen 





On 27 June 2017 at 16:09, Samir Das < [ mailto:samir.das at mcgill.ca | samir.das at mcgill.ca ] > wrote: 
BQ_BEGIN






---------- Forwarded message ---------- 
From: Bonhwang Koo < [ mailto:Bonhwang.Koo at childmind.org | Bonhwang.Koo at childmind.org ] > 
Date: Mon, Jun 26, 2017 at 8:28 AM 
Subject: LORIS Document Repository 
To: " [ mailto:loris.info at mcin.ca | loris.info at mcin.ca ] " < [ mailto:loris.info at mcin.ca | loris.info at mcin.ca ] > 


Hello, 



I am working with the Child Mind Institute’s Healthy Brain Network initiative, and we created a LORIS instance to allow users query data from our recent data release. I want to use the document repository feature, but it won’t allow me to upload a file without a category, so when I try to add a new category, nothing happens. Can you help me resolve this issue? 



Best, 

-- 

Bonhwang Koo 

Research Assistant, CDB 

Child Mind Institute 

[ http://childmind.org/ | childmind.org ] 

445 Park Avenue (entrance on 56th Street) 

New York, NY 10022 

E: [ mailto:Bonhwang.Koo at childmind.org | Bonhwang.Koo at childmind.org ] 

p: [ tel:(646)%20625-4398 | 646.625.4398 ] 

f: [ tel:(646)%20625-4348 | 646.625.4348 ] 



Facebook: [ http://facebook.com/ChildMindInstitute | facebook.com/ChildMindInstitute ] | Follow us on Twitter: [ http://twitter.com/ChildMindDotOrg | twitter.com/ChildMindDotOrg ] 



--- 



This email message, including any attachments, is for the sole use of the intended recipient(s) and may contain information that is proprietary, confidential, and exempt from disclosure under applicable law. Any unauthorized review, use, disclosure, or distribution is prohibited. If you have received this email in error please notify the sender by return email and delete the original message. Please note, the recipient should check this email and any attachments for the presence of viruses. The organization accepts no liability for any damage caused by any virus transmitted by this email. 








_______________________________________________ 
Loris-dev mailing list 
[ mailto:Loris-dev at bic.mni.mcgill.ca | Loris-dev at bic.mni.mcgill.ca ] 
[ http://www.bic.mni.mcgill.ca/mailman/listinfo/loris-dev | http://www.bic.mni.mcgill.ca/mailman/listinfo/loris-dev ] 








_______________________________________________ 
Loris-dev mailing list 
[ mailto:Loris-dev at bic.mni.mcgill.ca | Loris-dev at bic.mni.mcgill.ca ] 
[ http://www.bic.mni.mcgill.ca/mailman/listinfo/loris-dev | http://www.bic.mni.mcgill.ca/mailman/listinfo/loris-dev ] 





-- 


Ganesh Chauhan (PhD) 
Scientist 
Centre for Brain Research (CBR) 
Indian Institute of Science (IISc) 
Bengaluru, INDIA 
[ tel:+91%2080%202293%203009 | +91 80 2293 3009 ] 
[ https://www.cbr.iisc.ac.in/ | https://www.cbr.iisc.ac.in ] 

BQ_END





BQ_END





BQ_END






-- 
Ganesh Chauhan (PhD) 
Scientist 
Centre for Brain Research (CBR) 
Indian Institute of Science (IISc) 
Bengaluru, INDIA 
[ tel:+91%2080%202293%203009 | +91 80 2293 3009 ] 
[ https://www.cbr.iisc.ac.in/ | https://www.cbr.iisc.ac.in ] 

BQ_END



-- 
Ganesh Chauhan (PhD) 
Scientist 
Centre for Brain Research (CBR) 
Indian Institute of Science (IISc) 
Bengaluru, INDIA 
+91 80 2293 3009 
https://www.cbr.iisc.ac.in 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.bic.mni.mcgill.ca/pipermail/loris-dev/attachments/20170705/e68f4e05/attachment-0001.html>


More information about the Loris-dev mailing list