Hey guys, well, I started editing CKFinder and I found a way to solve my problem (Security issues, I wanted to make CKFinder as similar to windows explorer when it comes to permissions) I want to create a new accessControl type, and I want it to be sorta like this:
This is how it looks now.
Dim accessControl(0)
Set accessControl(0) = DefineAccessControlItem("*", "*", "/", true, true, true, true, true, true, true, true)
This is how I intend to make so it will (at lest my logical thinking says it would) work the way I need.
Dim accessControl (8)
Set accessControl(0) = DefineAccessControlItem("*", "adm", "/", true, true, true, true, true, true, true, true)
Set accessControl(1) = DefineAccessControlItem("1", "ime", "/", true, true, true, true, true, true, true, true)
Set accessControl(2) = DefineAccessControlItem("2", "publico", "/", true, true, true, true, true, true, true, true)
Set accessControl(3) = DefineAccessControlItem("3", "puc-rio", "/", true, true, true, true, true, true, true, true)
Set accessControl(4) = DefineAccessControlItem("4", "ufes", "/", true, true, true, true, true, true, true, true)
Set accessControl(5) = DefineAccessControlItem("5", "ufms", "/", true, true, true, true, true, true, true, true)
Set accessControl(6) = DefineAccessControlItem("6", "ufrj", "/", true, true, true, true, true, true, true, true)
Set accessControl(7) = DefineAccessControlItem("7", "ufscar", "/", true, true, true, true, true, true, true, true)
Set accessControl(8) = DefineAccessControlItem("8", "unb", "/", true, true, true, true, true, true, true, true)
But I've also should have changed the: ResourceTypes. I've put as it follows.
Dim ResourceTypes(8)
Set ResourceTypes(0) = DefineResourceType( _
"Administração", _
baseUrl & "adm", _
baseDir & "adm", _
0, _
"", _
"" _
)
Set ResourceTypes(1) = DefineResourceType( _
"Ime", _
baseUrl & "ime", _
baseDir & "ime", _
0, _
"txt,rtf,doc,docx,xls,xlsx,ppt,pptx,pdf,zip,rar,xml,avi,bmp,csv,fla,flv,gif,jpeg,jpg,mov,mp3,mp4,mpeg,ods,odt,png,tif,tiff,wav,wmv", _
"" _
)
Set ResourceTypes(2) = DefineResourceType( _
"Público", _
baseUrl & "publico", _
baseDir & "publico", _
0, _
"txt,rtf,doc,docx,xls,xlsx,ppt,pptx,pdf,zip,rar,xml,avi,bmp,csv,fla,flv,gif,jpeg,jpg,mov,mp3,mp4,mpeg,ods,odt,png,tif,tiff,wav,wmv", _
"" _
)
Set ResourceTypes(3) = DefineResourceType( _
"Puc-Rio", _
baseUrl & "puc-Rio", _
baseDir & "puc-Rio", _
0, _
"txt,rtf,doc,docx,xls,xlsx,ppt,pptx,pdf,zip,rar,xml,avi,bmp,csv,fla,flv,gif,jpeg,jpg,mov,mp3,mp4,mpeg,ods,odt,png,tif,tiff,wav,wmv", _
"" _
)
Set ResourceTypes(4) = DefineResourceType( _
"UFES", _
baseUrl & "ufes", _
baseDir & "ufes", _
0, _
"txt,rtf,doc,docx,xls,xlsx,ppt,pptx,pdf,zip,rar,xml,avi,bmp,csv,fla,flv,gif,jpeg,jpg,mov,mp3,mp4,mpeg,ods,odt,png,tif,tiff,wav,wmv", _
"" _
)
Set ResourceTypes(5) = DefineResourceType( _
"UFMS", _
baseUrl & "ufms", _
baseDir & "ufms", _
0, _
"txt,rtf,doc,docx,xls,xlsx,ppt,pptx,pdf,zip,rar,xml,avi,bmp,csv,fla,flv,gif,jpeg,jpg,mov,mp3,mp4,mpeg,ods,odt,png,tif,tiff,wav,wmv", _
"" _
)
Set ResourceTypes(6) = DefineResourceType( _
"UFRJ", _
baseUrl & "ufrj", _
baseDir & "ufrj", _
0, _
"txt,rtf,doc,docx,xls,xlsx,ppt,pptx,pdf,zip,rar,xml,avi,bmp,csv,fla,flv,gif,jpeg,jpg,mov,mp3,mp4,mpeg,ods,odt,png,tif,tiff,wav,wmv", _
"" _
)
Set ResourceTypes(7) = DefineResourceType( _
"UFSCAR", _
baseUrl & "ufscar", _
baseDir & "ufscar", _
0, _
"txt,rtf,doc,docx,xls,xlsx,ppt,pptx,pdf,zip,rar,xml,avi,bmp,csv,fla,flv,gif,jpeg,jpg,mov,mp3,mp4,mpeg,ods,odt,png,tif,tiff,wav,wmv", _
"" _
)
Set ResourceTypes(8) = DefineResourceType( _
"UNB", _
baseUrl & "unb", _
baseDir & "unb", _
0, _
"txt,rtf,doc,docx,xls,xlsx,ppt,pptx,pdf,zip,rar,xml,avi,bmp,csv,fla,flv,gif,jpeg,jpg,mov,mp3,mp4,mpeg,ods,odt,png,tif,tiff,wav,wmv", _
"" _
)
--------------------------
Did I do it right ?
I'm asking this because I don't know yet how to make my login page return a value to be attributed to the accessControl variable in CKFinder.
If anyone can help me with the login as well, I'd appreciate it.
Kind Regards
Yuri Valle.
This is how it looks now.
Dim accessControl(0)
Set accessControl(0) = DefineAccessControlItem("*", "*", "/", true, true, true, true, true, true, true, true)
This is how I intend to make so it will (at lest my logical thinking says it would) work the way I need.
Dim accessControl (8)
Set accessControl(0) = DefineAccessControlItem("*", "adm", "/", true, true, true, true, true, true, true, true)
Set accessControl(1) = DefineAccessControlItem("1", "ime", "/", true, true, true, true, true, true, true, true)
Set accessControl(2) = DefineAccessControlItem("2", "publico", "/", true, true, true, true, true, true, true, true)
Set accessControl(3) = DefineAccessControlItem("3", "puc-rio", "/", true, true, true, true, true, true, true, true)
Set accessControl(4) = DefineAccessControlItem("4", "ufes", "/", true, true, true, true, true, true, true, true)
Set accessControl(5) = DefineAccessControlItem("5", "ufms", "/", true, true, true, true, true, true, true, true)
Set accessControl(6) = DefineAccessControlItem("6", "ufrj", "/", true, true, true, true, true, true, true, true)
Set accessControl(7) = DefineAccessControlItem("7", "ufscar", "/", true, true, true, true, true, true, true, true)
Set accessControl(8) = DefineAccessControlItem("8", "unb", "/", true, true, true, true, true, true, true, true)
But I've also should have changed the: ResourceTypes. I've put as it follows.
Dim ResourceTypes(8)
Set ResourceTypes(0) = DefineResourceType( _
"Administração", _
baseUrl & "adm", _
baseDir & "adm", _
0, _
"", _
"" _
)
Set ResourceTypes(1) = DefineResourceType( _
"Ime", _
baseUrl & "ime", _
baseDir & "ime", _
0, _
"txt,rtf,doc,docx,xls,xlsx,ppt,pptx,pdf,zip,rar,xml,avi,bmp,csv,fla,flv,gif,jpeg,jpg,mov,mp3,mp4,mpeg,ods,odt,png,tif,tiff,wav,wmv", _
"" _
)
Set ResourceTypes(2) = DefineResourceType( _
"Público", _
baseUrl & "publico", _
baseDir & "publico", _
0, _
"txt,rtf,doc,docx,xls,xlsx,ppt,pptx,pdf,zip,rar,xml,avi,bmp,csv,fla,flv,gif,jpeg,jpg,mov,mp3,mp4,mpeg,ods,odt,png,tif,tiff,wav,wmv", _
"" _
)
Set ResourceTypes(3) = DefineResourceType( _
"Puc-Rio", _
baseUrl & "puc-Rio", _
baseDir & "puc-Rio", _
0, _
"txt,rtf,doc,docx,xls,xlsx,ppt,pptx,pdf,zip,rar,xml,avi,bmp,csv,fla,flv,gif,jpeg,jpg,mov,mp3,mp4,mpeg,ods,odt,png,tif,tiff,wav,wmv", _
"" _
)
Set ResourceTypes(4) = DefineResourceType( _
"UFES", _
baseUrl & "ufes", _
baseDir & "ufes", _
0, _
"txt,rtf,doc,docx,xls,xlsx,ppt,pptx,pdf,zip,rar,xml,avi,bmp,csv,fla,flv,gif,jpeg,jpg,mov,mp3,mp4,mpeg,ods,odt,png,tif,tiff,wav,wmv", _
"" _
)
Set ResourceTypes(5) = DefineResourceType( _
"UFMS", _
baseUrl & "ufms", _
baseDir & "ufms", _
0, _
"txt,rtf,doc,docx,xls,xlsx,ppt,pptx,pdf,zip,rar,xml,avi,bmp,csv,fla,flv,gif,jpeg,jpg,mov,mp3,mp4,mpeg,ods,odt,png,tif,tiff,wav,wmv", _
"" _
)
Set ResourceTypes(6) = DefineResourceType( _
"UFRJ", _
baseUrl & "ufrj", _
baseDir & "ufrj", _
0, _
"txt,rtf,doc,docx,xls,xlsx,ppt,pptx,pdf,zip,rar,xml,avi,bmp,csv,fla,flv,gif,jpeg,jpg,mov,mp3,mp4,mpeg,ods,odt,png,tif,tiff,wav,wmv", _
"" _
)
Set ResourceTypes(7) = DefineResourceType( _
"UFSCAR", _
baseUrl & "ufscar", _
baseDir & "ufscar", _
0, _
"txt,rtf,doc,docx,xls,xlsx,ppt,pptx,pdf,zip,rar,xml,avi,bmp,csv,fla,flv,gif,jpeg,jpg,mov,mp3,mp4,mpeg,ods,odt,png,tif,tiff,wav,wmv", _
"" _
)
Set ResourceTypes(8) = DefineResourceType( _
"UNB", _
baseUrl & "unb", _
baseDir & "unb", _
0, _
"txt,rtf,doc,docx,xls,xlsx,ppt,pptx,pdf,zip,rar,xml,avi,bmp,csv,fla,flv,gif,jpeg,jpg,mov,mp3,mp4,mpeg,ods,odt,png,tif,tiff,wav,wmv", _
"" _
)
--------------------------
Did I do it right ?
I'm asking this because I don't know yet how to make my login page return a value to be attributed to the accessControl variable in CKFinder.
If anyone can help me with the login as well, I'd appreciate it.
Kind Regards
Yuri Valle.
Re: Creating a new accessControl type