| 239 | |
| 240 | 2) This problem can also be caused by inappropriate permissions if your PHP is installed as CGI (common gateway interface). |
| 241 | |
| 242 | To check the mode your PHP is running in, create the file '''phpinfo.php''' with the following contents: |
| 243 | {{{ |
| 244 | <?php |
| 245 | phpinfo(); |
| 246 | ?> |
| 247 | |
| 248 | }}} |
| 249 | and upload it to the Dolphin installation directory. Then open this file in a browser. |
| 250 | |
| 251 | When you're sure that your PHP is running in CGI mode, you should set the permissions of all folders to 755 and files to 644; the file '''ray/modules/global/app/ffmpeg.exe''' should be set to 755 as well. |
| 252 | To do this quickly, you can run the following commands when you're in the Dolphin installation folder under your SSH account: |
| 253 | {{{ |
| 254 | find ./ -type d -exec chmod 755 {} \; |
| 255 | find ./ -type f -exec chmod 644 {} \; |
| 256 | chmod 755 ray/modules/global/app/ffmpeg.exe; |
| 257 | |
| 258 | }}} |
| 259 | |
| 260 | Now you need to let Ray determine your new permissions properly. To do so, open the file '''ray/modules/global/inc/function.inc.php''' and insert these lines of code: |
| 261 | {{{ |
| 262 | $sResult = ""; |
| 263 | $bDir = is_dir($sFilePath); |
| 264 | if(is_readable($sFilePath)) $sResult = $bDir ? "755" : "644"; |
| 265 | if(is_writable($sFilePath)) $sResult = $bDir ? "777" : "666"; |
| 266 | if(!$bDir && is_executable($sFilePath)) $sResult = "777"; |
| 267 | |
| 268 | }}} |
| 269 | |
| 270 | before the line |
| 271 | |
| 272 | {{{ |
| 273 | return $sResult; |
| 274 | |
| 275 | }}} |
| 276 | |
| 277 | in the function '''checkPermissions($sFileName)'''. |