Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Find this:
- // Get Patterns into a drop-down list
- $patterns = array();
- if(is_dir(TEMPLATEPATH . "/images/backgrounds/")) {
- if($open_dirs = opendir(TEMPLATEPATH . "/images/backgrounds/")) {
- while(($pattern = readdir($open_dirs)) !== false) {
- if(stristr($pattern, ".png") !== false) {
- $patterns[] = $pattern;
- }
- }
- }
- }
- $pattern_dropdown = sort($patterns);
- array_unshift($patterns, "None");
- # Change to this:
- // Get Patterns into a drop-down list
- $patterns = array();
- if(is_dir(TEMPLATEPATH . "/images/backgrounds/")) {
- if($open_dirs = opendir(TEMPLATEPATH . "/images/backgrounds/")) {
- while(($pattern = readdir($open_dirs)) !== false) {
- if(stristr($pattern, ".png") !== false || stristr($pattern, ".jpg") !== false) {
- $patterns[] = $pattern;
- }
- }
- }
- }
- $pattern_dropdown = sort($patterns);
- array_unshift($patterns, "None");
Add Comment
Please, Sign In to add comment