root/ip/tags/release_1_3_0_53/adm/admin_album_cat.php
| 111 | 163 | ||
|---|---|---|---|
446 | if ($db->sql_numrows($result) > 0) | 446 | if ($db->sql_numrows($result) > 0) |
447 | { | 447 | { |
448 | $parent_cat_id = 0; | 448 | $parent_cat_id = 0; |
449 | if (isset($lang[$board_config['sitename']])) | 449 | if (isset($lang[ip_stripslashes($board_config['sitename'])])) |
450 | $parent_cat_title = sprintf($lang['Forum_Index'], $lang[$board_config['sitename']]); | 450 | $parent_cat_title = sprintf($lang['Forum_Index'], $lang[ip_stripslashes($board_config['sitename'])]); |
451 | else | 451 | else |
452 | $parent_cat_title = sprintf($lang['Forum_Index'], $board_config['sitename']); | 452 | $parent_cat_title = sprintf($lang['Forum_Index'], ip_stripslashes($board_config['sitename'])); |
453 | 453 | ||
454 | //it is so set the indicator that we are deleting a parent category | 454 | //it is so set the indicator that we are deleting a parent category |
455 | $parent_cat_deleted = true; | 455 | $parent_cat_deleted = true; |
... | ... | ||
512 | } | 512 | } |
513 | 513 | ||
514 | $file_part = explode('.', strtolower($pic_filename)); | 514 | $file_part = explode('.', strtolower($pic_filename)); |
515 | $pic_filetype = $file_part[count($file_part) - 1]; | 515 | $pic_filetype = $file_part[sizeof($file_part) - 1]; |
516 | $pic_filename_only = substr($pic_filename, 0, strlen($pic_filename) - strlen($pic_filetype) - 1); | 516 | $pic_filename_only = substr($pic_filename, 0, strlen($pic_filename) - strlen($pic_filetype) - 1); |
517 | $pic_base_path = ALBUM_UPLOAD_PATH; | 517 | $pic_base_path = IP_ROOT_PATH . ALBUM_UPLOAD_PATH; |
518 | $pic_extra_path = ''; | 518 | $pic_extra_path = ''; |
519 | $pic_new_filename = $pic_extra_path . $pic_filename; | 519 | $pic_new_filename = $pic_extra_path . $pic_filename; |
520 | $pic_fullpath = $pic_base_path . $pic_new_filename; | 520 | $pic_fullpath = $pic_base_path . $pic_new_filename; |
521 | $pic_thumbnail = $picrow[$i]['pic_thumbnail']; | 521 | $pic_thumbnail = $filerow[$i]['pic_thumbnail']; |
522 | $pic_thumbnail_fullpath = ALBUM_CACHE_PATH . $pic_thumbnail; | 522 | $pic_thumbnail_fullpath = IP_ROOT_PATH . ALBUM_CACHE_PATH . $pic_thumbnail; |
523 | 523 | ||
524 | if (USERS_SUBFOLDERS_ALBUM == true) | 524 | if (USERS_SUBFOLDERS_ALBUM == true) |
525 | { | 525 | { |
526 | if (count($pic_path) == 2) | 526 | if (sizeof($pic_path) == 2) |
527 | { | 527 | { |
528 | $pic_extra_path = $pic_path[0] . '/'; | 528 | $pic_extra_path = $pic_path[0] . '/'; |
529 | $pic_thumbnail_path = ALBUM_CACHE_PATH . $pic_extra_path; | 529 | $pic_base_full_path = IP_ROOT_PATH . ALBUM_UPLOAD_PATH . $pic_extra_path; |
530 | if (is_dir($pic_path_only)) | 530 | $pic_thumbnail_path = IP_ROOT_PATH . ALBUM_CACHE_PATH . $pic_extra_path; |
531 | if (is_dir($pic_base_full_path)) | ||
531 | { | 532 | { |
532 | $pic_new_filename = $pic_extra_path . $pic_filename; | 533 | $pic_new_filename = $pic_extra_path . $pic_filename; |
533 | $pic_fullpath = $pic_base_path . $pic_new_filename; | 534 | $pic_fullpath = $pic_base_path . $pic_new_filename; |
... | ... | ||
541 | } | 542 | } |
542 | 543 | ||
543 | @unlink($pic_thumbnail_fullpath); | 544 | @unlink($pic_thumbnail_fullpath); |
544 | @unlink(ALBUM_MED_CACHE_PATH . $pic_extra_path . $pic_thumbnail); | 545 | @unlink(IP_ROOT_PATH . ALBUM_MED_CACHE_PATH . $pic_extra_path . $pic_thumbnail); |
545 | @unlink(ALBUM_WM_CACHE_PATH . $pic_extra_path . $pic_thumbnail); | 546 | @unlink(IP_ROOT_PATH . ALBUM_WM_CACHE_PATH . $pic_extra_path . $pic_thumbnail); |
546 | @unlink($pic_fullpath); | 547 | @unlink($pic_fullpath); |
547 | } | 548 | } |
548 | 549 |
Download diff