Changeset 3061816
- Timestamp:
- 03/31/2024 08:39:24 PM (2 years ago)
- Location:
- petmatchpro/trunk
- Files:
-
- 24 edited
-
CHANGE-LOG.docx (modified) (previous)
-
CHANGE-LOG.pdf (modified) (previous)
-
CHANGE-LOG.txt (modified) (1 diff)
-
README.txt (modified) (1 diff)
-
admin/class-pet-match-pro-admin-settings.php (modified) (3 diffs)
-
admin/partials/pmp-admin-info.php (modified) (1 diff)
-
admin/partials/pmp-option-levels-general.php (modified) (1 diff)
-
includes/class-pet-match-pro-activator.php (modified) (2 diffs)
-
includes/pp/class-pet-match-pro-pp-api.php (modified) (7 diffs)
-
includes/rg/class-pet-match-pro-rg-api.php (modified) (4 diffs)
-
pet-match-pro.php (modified) (2 diffs)
-
public/partials/pet-match-pro-public-color-css.php (modified) (1 diff)
-
public/templates/pp/adoptable-conversion-no-app.php (modified) (2 diffs)
-
public/templates/pp/adoptable-conversion-poster.php (modified) (2 diffs)
-
public/templates/pp/adoptable-conversion-with-app.php (modified) (2 diffs)
-
public/templates/pp/adoptable-conversion.php (modified) (2 diffs)
-
public/templates/pp/adoptable-default.php (modified) (2 diffs)
-
public/templates/pp/adoptable-wide.php (modified) (2 diffs)
-
public/templates/pp/found-default.php (modified) (2 diffs)
-
public/templates/pp/found-poster.php (modified) (2 diffs)
-
public/templates/pp/lost-default.php (modified) (2 diffs)
-
public/templates/pp/lost-poster.php (modified) (2 diffs)
-
public/templates/rg/adoptable-cpa.php (modified) (2 diffs)
-
public/templates/rg/adoptable-default.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
petmatchpro/trunk/CHANGE-LOG.txt
r3057448 r3061816 1 Version 4.7.3 - March 31, 2024 2 + /admin/class-pet-match-pro-admin-settings.php 3 * Only include color css styles when the Colors tab is active. 4 * Add unique setting to General tab to control the max number of thumbnails displayed on the animal detail pages. 5 + /admin/partials/pmp-option-levels-general.php 6 * Add level value for new detail thumbnail max General setting. 7 + /admin/partials/pmp-admin-info.php 8 * Add help field value for new detail thumbnail max General setting. 9 + /includes/pp/class-pet-match-pro-pp-api.php 10 * Correct issue displaying animal details when key value does not exist. 11 * Update to use new thumbnail max setting. 12 + /includes/rg/class-pet-match-pro-rg-api.php 13 * Update to use new thumbnail max setting. 14 * Correct error when displaying animal detail that does not exist. 15 + /public/templates/pp/*.php 16 * Update detail templates to use new thumbnail max setting. 17 + /public/templates/rg/*.php 18 * Update detail templates to use new thumbnail max setting. 19 + /includes/class-pet-match-pro-activator.php 20 * Assign default value to new thumbnail max setting. 21 + /admin/partials/pet-match-pro-public-color-css.php 22 * Extend the Adoptable Details Title class to paragraphs and spans. 23 1 24 Version 4.7.2 - March 23, 2024 2 25 + /public/class-pet-match-pro-public.php -
petmatchpro/trunk/README.txt
r3057448 r3061816 6 6 Requires at least: 5.0 7 7 Tested up to: 6.4 8 Stable tag: 4.7. 28 Stable tag: 4.7.3 9 9 License: GPLv2 or later 10 10 License URI: http://www.gnu.org/licenses/gpl-2.0.html -
petmatchpro/trunk/admin/class-pet-match-pro-admin-settings.php
r3057448 r3061816 546 546 add_settings_field( 547 547 'Results per Row ', 548 __(' Results per Row ', 'pet-match-pro-plugin'),548 __('Search Results per Row ', 'pet-match-pro-plugin'), 549 549 array($this, 'select_element_callback'), 550 550 'pet-match-pro-general-options', … … 609 609 ) 610 610 ); 611 611 612 //echo 'level_detail_thumbs_max_adopt = ' . $pmpOptionLevelsGeneral['level_detail_thumbs_max_adopt'] . '<br>'; 613 if ( (array_key_exists('level_detail_thumbs_max_adopt', $pmpOptionLevelsGeneral)) && ($this->PMPLicenseTypeID <= $pmpOptionLevelsGeneral['level_detail_thumbs_max_adopt']) && (!empty($this->pmpLicenseKey)) ) { 614 $classDetailThumbsMax = 'pmp-detail-thumbs-max-adopt'; 615 } else { 616 $classDetailThumbsMax = 'pmp-option-disable'; 617 } 618 619 add_settings_field( 620 'adoptable_animal_detail_thumbs_max', 621 __('Max Detail Thumbnails ', 'pet-match-pro-plugin'), 622 array($this, 'select_element_callback'), 623 'pet-match-pro-general-options', 624 'general_settings_section', 625 array('pet-match-pro-general-options', 626 'adoptable_animal_detail_thumbs_max', 627 array('1' => '1', '2' => '2', '3' => '3', '4' => '4', '5' => '5', '6' => '6', '7' => '7', '8' => '8', '9' => '9', '10' => '10', '11' => '11', '12' => '12'), 628 $this->pmpAdminInfo['adoptable_animal_detail_thumbs_max'], 629 'class' => $classDetailThumbsMax 630 ) 631 ); 632 612 633 //echo 'level_animal_detail_icons_adopt = ' . $pmpOptionLevelsGeneral['level_animal_detail_icons_adopt'] . '<br>'; 613 634 if ( (array_key_exists('level_animal_detail_icons_adopt', $pmpOptionLevelsGeneral)) && ($this->PMPLicenseTypeID <= $pmpOptionLevelsGeneral['level_animal_detail_icons_adopt']) && (!empty($this->pmpLicenseKey)) ) { … … 1618 1639 //$PMPLicenseTypeID = 4; 1619 1640 1641 /* Determine if Tab is Active */ 1642 $colorsActive = false; 1643 if (isset($_GET['subpage'])) { 1644 $activeTab = sanitize_text_field( $_GET['subpage'] ); 1645 if ($activeTab == 'color_options') { 1646 $colorsActive = true; 1647 } 1648 } 1649 1620 1650 /* Get the Settings for Use in Formatting the Labels */ 1621 if ( ( is_array($this->colorOptions)) && (count($this->colorOptions) > 0) ) {1651 if ( ($colorsActive == true) && (is_array($this->colorOptions)) && (count($this->colorOptions) > 0) ) { 1622 1652 echo '<style id="pmp-color-options">'; 1623 1653 foreach ($this->colorOptions as $key=>$value) { -
petmatchpro/trunk/admin/partials/pmp-admin-info.php
r3057448 r3061816 18 18 $this->pmpAdminInfo['adoptable_animal_search_icons_max'] = 'Select maximum icons to display in adoptable search results.'; 19 19 /*$this->pmpAdminInfo['adoptable_animal_search_icon_fields'] = 'Check to display the icon data fields as well as their icons.';*/ 20 $this->pmpAdminInfo[' detail_thumbnails'] = 'Select the number ofthumbnails to display on the animal detail page.';20 $this->pmpAdminInfo['adoptable_animal_detail_thumbs_max'] = 'Select the maximum thumbnails to display on the animal detail page.'; 21 21 $this->pmpAdminInfo['adoptable_animal_detail_icons'] = 'Check to show icons in adoptable detail page.'; 22 22 $this->pmpAdminInfo['adoptable_animal_detail_icons_max'] = 'Select maximum icons to display on adoptable detail page.'; -
petmatchpro/trunk/admin/partials/pmp-option-levels-general.php
r3050057 r3061816 9 9 'level_search_icons_max_adopt' => 2, 10 10 /*'level_search_icon_fields_adopt' => 2, */ 11 'level_detail_thumb nails' => 2,11 'level_detail_thumbs_max_adopt' => 2, 12 12 'level_animal_detail_icons_adopt' => 2, 13 13 'level_animal_detail_icons_max_adopt' => 2, -
petmatchpro/trunk/includes/class-pet-match-pro-activator.php
r3050057 r3061816 17 17 'adoptable_animal_search_icons' => '', 18 18 'adoptable_animal_search_icons_max' => '3', 19 /* 'detail_thumbnails' => '3', */ 19 'adoptable_animal_detail_thumbs_max' => '3', 20 20 'adoptable_animal_detail_icons' => '', 21 21 'adoptable_animal_detail_icons_max' => '3', … … 25 25 'details_template_found' => 'found-default', 26 26 'details_page_adopt' => '0', 27 'details_page_lost' => '0 /',27 'details_page_lost' => '0', 28 28 'details_page_found' => '0', 29 29 'details_page_poster' => '0', -
petmatchpro/trunk/includes/pp/class-pet-match-pro-pp-api.php
r3057448 r3061816 1377 1377 //create search details based on details set by admin or shortcode 1378 1378 1379 $detailsPage = $selfURLIN . '?method=' . $detailsFunc . '&animalID=' . $results['id']; 1379 if (array_key_exists('id', $results)) { 1380 $detailsPage = $selfURLIN . '?method=' . $detailsFunc . '&animalID=' . $results['id']; 1381 } else { 1382 $detailsPage = $selfURLIN . '?method=' . $detailsFunc . '&animalID=' . constant('ERROR'); 1383 } 1380 1384 //use override details to show $searchResultDetails if defined in admin and or shortcode 1381 1385 … … 1402 1406 1403 1407 //if name is forced to be excluded get the name but dont include in array 1408 if (!array_key_exists('name', $results)) { 1409 $results['name'] = constant('EMPTY_VALUE'); 1410 } 1404 1411 $animalName = $results['name']; 1405 1412 if (!array_key_exists('name', $searchResultDetails)) { … … 1424 1431 //for sex in whole world used on found and lost 1425 1432 if ($key == constant('PETPOINT_SEX')) { 1426 if ($results[$key] == 'M') { 1427 $DetailsOutput[$key]['value'] = 'Male'; 1428 } elseif ($results[$key] == 'F') { 1429 $DetailsOutput[$key]['value'] = 'Female'; 1430 } elseif ($results[$key] == 'U') { 1433 if ( (array_key_exists($key, $results)) ) { 1434 if ($results[$key] == 'M') { 1435 $DetailsOutput[$key]['value'] = 'Male'; 1436 } elseif ($results[$key] == 'F') { 1437 $DetailsOutput[$key]['value'] = 'Female'; 1438 } elseif ($results[$key] == 'U') { 1439 $DetailsOutput[$key]['value'] = 'Unknown'; 1440 } 1441 } else { 1431 1442 $DetailsOutput[$key]['value'] = 'Unknown'; 1432 }1433 }1443 } 1444 } 1434 1445 //for age compute in years and months 1435 1446 if ($key == constant('PETPOINT_AGE')) { 1436 1447 //echo 'Results Age Value is ' . $results[$key] . '<br>'; 1437 1448 //echo 'Converted Age is ' . $this->convertAge($results[$key], array_key_exists('age_in_years', $general_options)) . '<br>'; 1438 $DetailsOutput[$key]['value'] = $this->convertAge($results[$key], array_key_exists('age_in_years', $general_options)); 1449 if (array_key_exists($key, $results)) { 1450 $DetailsOutput[$key]['value'] = $this->convertAge($results[$key], array_key_exists('age_in_years', $general_options)); 1451 } else { 1452 $DetailsOutput[$key]['value'] = constant('EMPTY_VALUE'); 1453 } 1439 1454 //if (array_key_exists('age_in_years', $FilterAdminOptions)) { /* RMB - Switch to General Options */ 1440 1455 // if ( (array_key_exists('age_in_years', $general_options)) && ($licenseTypeID != constant('FREE_LEVEL')) ) { … … 1959 1974 $animalDetails[$key]['value'] = $detailsItem[$key]; 1960 1975 } 1961 if ( ($key == constant('PETPOINT_SEX')) && (array_key_exists('value', $animalDetails[$key])) ) { 1962 if ($animalDetails[$key]['value'] == 'M') { 1963 $animalDetails[$key]['value'] = 'Male'; 1964 } elseif ($animalDetails[$key]['value'] == 'F') { 1965 $animalDetails[$key]['value'] = 'Female'; 1966 } 1976 if ($key == constant('PETPOINT_SEX')) { 1977 if (array_key_exists('value', $animalDetails[$key])) { 1978 if ($animalDetails[$key]['value'] == 'M') { 1979 $animalDetails[$key]['value'] = 'Male'; 1980 } elseif ($animalDetails[$key]['value'] == 'F') { 1981 $animalDetails[$key]['value'] = 'Female'; 1982 } 1983 } else { 1984 $animalDetails[$key]['value'] = constant('EMPTY_VALUE'); 1985 } 1967 1986 } 1968 1987 if (array_key_exists($key, $detailsItem)) { … … 1984 2003 } 1985 2004 if ($key == constant('PETPOINT_AGE')) { 1986 $animalDetails[$key]['value'] = $this->convertAge($detailsItem[$key], array_key_exists('age_in_years', $general_options)); 1987 } 2005 if (array_key_exists(constant('PETPOINT_AGE'), $detailsItem)) { 2006 $animalDetails[$key]['value'] = $this->convertAge($detailsItem[$key], array_key_exists('age_in_years', $general_options)); 2007 } else { 2008 $animalDetails[$key]['value'] = constant('EMPTY_VALUE'); 2009 } 2010 } 1988 2011 /* RMB - Remove Time from Date Fields */ 1989 2012 if (str_contains($key, 'date')) { 1990 //echo 'Removing Time from Key ' . $key . '<br>'; 1991 $animalDetails[$key]['value'] = date("m-d-Y",strtotime($detailsItem[$key])); 2013 if (array_key_exists($key, $detailsItem)) { 2014 //echo 'Removing Time from Key ' . $key . '<br>'; 2015 $animalDetails[$key]['value'] = date("m-d-Y",strtotime($detailsItem[$key])); 2016 } else { 2017 $animalDetails[$key]['value'] = constant('EMPTY_VALUE'); 2018 } 1992 2019 } 1993 2020 if (!is_array($item)) { … … 2055 2082 2056 2083 //include the photos 2084 if (array_key_exists('adoptable_animal_detail_thumbs_max', $this->generalOptions)) { 2085 $maxThumbs = $this->generalOptions['adoptable_animal_detail_thumbs_max']; 2086 } else { 2087 $maxThumbs = 3; 2088 } 2089 //echo '<pre>DETAIL ITEMS<br>'; print_r($detailsItem); echo '</pre>'; 2090 $thumb = 1; 2057 2091 if ($callFunc == 'AdoptableDetails') { 2058 if (!empty($detailsItem['photo1'])) { 2059 $animalDetails[constant('PETPOINT_PHOTOS')][] = $detailsItem['photo1']; 2060 } 2061 if (!empty($detailsItem['photo2'])) { 2062 $animalDetails[constant('PETPOINT_PHOTOS')][] = $detailsItem['photo2']; 2063 } 2064 if (!empty($detailsItem['photo3'])) { 2065 $animalDetails[constant('PETPOINT_PHOTOS')][] = $detailsItem['photo3']; 2066 } 2092 while ($thumb <= $maxThumbs) { 2093 $thumbKey = 'photo' . $thumb; 2094 //echo 'Processing Thumb Key ' . $thumbKey . '<br>'; 2095 if (!empty($detailsItem[$thumbKey])) { 2096 $animalDetails[constant('PETPOINT_PHOTOS')][] = $detailsItem[$thumbKey]; 2097 //echo 'Added Thumb Key ' . $thumbKey . ' to AnimalDetails Array.<br>'; 2098 } 2099 $thumb = $thumb + 1; 2100 } 2101 // if (!empty($detailsItem['photo1'])) { 2102 // $animalDetails[constant('PETPOINT_PHOTOS')][] = $detailsItem['photo1']; 2103 // } 2104 // if (!empty($detailsItem['photo2'])) { 2105 // $animalDetails[constant('PETPOINT_PHOTOS')][] = $detailsItem['photo2']; 2106 // } 2107 // if (!empty($detailsItem['photo3'])) { 2108 // $animalDetails[constant('PETPOINT_PHOTOS')][] = $detailsItem['photo3']; 2109 // } 2067 2110 if (!empty($detailsItem[constant('PETPOINT_VIDEOS')])) { 2068 2111 $animalDetails[constant('PETPOINT_VIDEOS')] = $detailsItem['videoid']; … … 2072 2115 } else { 2073 2116 if (!empty($detailsItem['photo'])) { 2117 //echo 'Added 1st Thumb<br>'; 2074 2118 $animalDetails[constant('PETPOINT_PHOTOS')][] = $detailsItem['photo']; 2075 } 2076 if (!empty($detailsItem['photo1'])) { 2077 $animalDetails[constant('PETPOINT_PHOTOS')][] = $detailsItem['photo1']; 2078 } 2079 if (!empty($detailsItem['photo2'])) { 2080 $animalDetails[constant('PETPOINT_PHOTOS')][] = $detailsItem['photo2']; 2081 } 2119 $maxThumbs = $maxThumbs - 1; 2120 //echo 'Decremented Max Thumbs to ' . $maxThumbs . '<br>'; 2121 } 2122 while ($thumb <= $maxThumbs) { 2123 $thumbKey = 'photo' . $thumb; 2124 //echo 'Processing Thumb Key ' . $thumbKey . '<br>'; 2125 if (!empty($detailsItem[$thumbKey])) { 2126 $animalDetails[constant('PETPOINT_PHOTOS')][] = $detailsItem[$thumbKey]; 2127 //echo 'Added Thumb Key ' . $thumbKey . ' to AnimalDetails Array.<br>'; 2128 } 2129 $thumb = $thumb + 1; 2130 } 2131 2132 // if (!empty($detailsItem['photo1'])) { 2133 // $animalDetails[constant('PETPOINT_PHOTOS')][] = $detailsItem['photo1']; 2134 // } 2135 // if (!empty($detailsItem['photo2'])) { 2136 // $animalDetails[constant('PETPOINT_PHOTOS')][] = $detailsItem['photo2']; 2137 // } 2082 2138 } 2083 2139 -
petmatchpro/trunk/includes/rg/class-pet-match-pro-rg-api.php
r3057448 r3061816 1123 1123 1124 1124 //include the photos 1125 $numPhotos = intval($this->generalOptions['adoptable_animal_detail_icons_max']) + 1; 1126 //echo 'Number of Photos is ' . $numPhotos . '<br>'; 1127 if ( is_int($numPhotos) ) { 1125 // $numPhotos = intval($this->generalOptions['adoptable_animal_detail_icons_max']) + 1; 1126 if (array_key_exists('adoptable_animal_detail_thumbs_max', $this->generalOptions)) { 1127 $maxThumbs = intval($this->generalOptions['adoptable_animal_detail_thumbs_max']); 1128 } else { 1129 $maxThumbs = 3; 1130 } 1131 //echo 'Max Thumbs is ' . $maxThumbs . '<br>'; 1132 //echo '<pre>DETAIL ITEMS<br>'; print_r($detailsItem); echo '</pre>'; 1133 if ( is_int($maxThumbs) ) { 1134 //echo 'Max thumbs is an Integer.<br>'; 1128 1135 $counter = 1; 1129 while ($counter <= $ numPhotos) {1136 while ($counter <= $maxThumbs) { 1130 1137 $photoKey = $counter - 1; 1131 //echo 'Processing Photo with Index' . $photoKey . '<br>';1138 //echo 'Processing Counter ' . $counter . ' with Key ' . $photoKey . '<br>'; 1132 1139 if (!empty($detailsItem[constant('RESCUEGROUPS_PHOTOS')][$photoKey])) { 1133 1140 $animalDetails[constant('RESCUEGROUPS_PHOTOS')][] = $detailsItem[constant('RESCUEGROUPS_PHOTOS')][$photoKey]['urlSecureThumbnail']; 1141 //echo 'Added Animal Photo<br>'; 1134 1142 } 1135 1143 $counter = $counter + 1; … … 1143 1151 } 1144 1152 1145 1146 1153 //get template options if defined in shortcode 1147 1154 if (is_array($items)) { … … 1236 1243 ); 1237 1244 $animalDetails = $this->fetch_rg_data($apiData, 'singleDetail', $item); 1238 $animalDetails = $animalDetails['data'][0]; 1245 if (is_array($animalDetails)) { 1246 if (array_key_exists('data', $animalDetails)) { 1247 $animalDetails = $animalDetails['data'][0]; 1248 } else { 1249 return constant('ERROR'); 1250 } 1251 } else { 1252 return constant('ERROR'); 1253 } 1239 1254 //echo '<pre>ANIMAL DETAILS<br>'; print_r($animalDetails); echo '</pre>'; 1240 1255 // $details = array(); - RMB … … 1246 1261 //vd($details); 1247 1262 } else { /* RMB */ 1248 return null; /* RMB */ 1263 return constant('ERROR'); 1264 // return null; /* RMB */ 1249 1265 } /* RMB */ 1250 1266 // return $details[$item]; RMB 1251 } else return null; /* RMB */ 1267 } else return constant('ERROR'); 1268 // } else return null; /* RMB */ 1252 1269 } 1253 1270 -
petmatchpro/trunk/pet-match-pro.php
r3057448 r3061816 13 13 * Plugin Name: PetMatchPro 14 14 * Description: Integrates animal search and details from your PetPoint/Petango or RescueGroups account into your website with simple shortcodes. 15 * Version: 4.7. 215 * Version: 4.7.3 16 16 * Author: PetMatchPro 17 17 * Author URI: https://PetMatchPro.com … … 28 28 * Current plugin version. 29 29 */ 30 define('PET_MATCH_PRO_VERSION', '4.7. 2');30 define('PET_MATCH_PRO_VERSION', '4.7.3'); 31 31 32 32 /* Define Global Variables */ -
petmatchpro/trunk/public/partials/pet-match-pro-public-color-css.php
r3057448 r3061816 120 120 $color = trim($colorOptions['detail_result_title']); 121 121 echo 'h1.pmp-adoptable-details-title {color:' . $color . '}'; 122 echo 'p.pmp-adoptable-details-title {color:' . $color . '}'; 123 echo 'span.pmp-adoptable-details-title {color:' . $color . '}'; 122 124 } 123 125 -
petmatchpro/trunk/public/templates/pp/adoptable-conversion-no-app.php
r3057448 r3061816 65 65 66 66 if ( !empty($this->PMPLicenseTypeID) && ($this->PMPLicenseTypeID != constant('FREE_LEVEL')) ) { 67 if (array_key_exists('adoptable_animal_detail_ icons_max', $this->generalOptions)) {68 $maxThumbs = $this->generalOptions['adoptable_animal_detail_ icons_max'];67 if (array_key_exists('adoptable_animal_detail_thumbs_max', $this->generalOptions)) { 68 $maxThumbs = $this->generalOptions['adoptable_animal_detail_thumbs_max']; 69 69 } else { 70 70 $maxThumbs = 6; … … 80 80 $gaParamArray['page_url'] = $_SERVER['REQUEST_URI']; 81 81 82 $thumb = 1;82 $thumb = 0; 83 83 if ( (array_key_exists(constant('PETPOINT_PHOTOS'), $animalDetails)) && ($this->PMPLicenseTypeID <= $pmpFieldLevelsAdopt['level_detail_photo_adopt']) ) { 84 84 // if ( $this->PMPLicenseTypeID <= $pmpFieldLevelsAdopt['level_detail_photo_adopt'] ) { -
petmatchpro/trunk/public/templates/pp/adoptable-conversion-poster.php
r3057448 r3061816 65 65 66 66 if ( !empty($this->PMPLicenseTypeID) && ($this->PMPLicenseTypeID != constant('FREE_LEVEL')) ) { 67 if (array_key_exists('adoptable_animal_detail_ icons_max', $this->generalOptions)) {68 $maxThumbs = $this->generalOptions['adoptable_animal_detail_ icons_max'];67 if (array_key_exists('adoptable_animal_detail_thumbs_max', $this->generalOptions)) { 68 $maxThumbs = $this->generalOptions['adoptable_animal_detail_thumbs_max']; 69 69 } else { 70 70 $maxThumbs = 6; … … 81 81 $gaParamArray['page_url'] = $_SERVER['REQUEST_URI']; 82 82 83 $thumb = 1;83 $thumb = 0; 84 84 if ( (array_key_exists(constant('PETPOINT_PHOTOS'), $animalDetails)) && ($this->PMPLicenseTypeID <= $pmpFieldLevelsAdopt['level_detail_photo_adopt']) && ($thumb <= $maxThumbs) ) { 85 85 // if ( $this->PMPLicenseTypeID <= $pmpFieldLevelsAdopt['level_detail_photo_adopt'] ) { -
petmatchpro/trunk/public/templates/pp/adoptable-conversion-with-app.php
r3057448 r3061816 65 65 66 66 if ( !empty($this->PMPLicenseTypeID) && ($this->PMPLicenseTypeID != constant('FREE_LEVEL')) ) { 67 if (array_key_exists('adoptable_animal_detail_ icons_max', $this->generalOptions)) {68 $maxThumbs = $this->generalOptions['adoptable_animal_detail_ icons_max'];67 if (array_key_exists('adoptable_animal_detail_thumbs_max', $this->generalOptions)) { 68 $maxThumbs = $this->generalOptions['adoptable_animal_detail_thumbs_max']; 69 69 } else { 70 70 $maxThumbs = 6; … … 79 79 $gaParamArray['page_url'] = $_SERVER['REQUEST_URI']; 80 80 81 $thumb = 1;81 $thumb = 0; 82 82 if ( (array_key_exists(constant('PETPOINT_PHOTOS'), $animalDetails)) && ($this->PMPLicenseTypeID <= $pmpFieldLevelsAdopt['level_detail_photo_adopt']) && ($thumb <= $maxThumbs) ) { 83 83 // if ( $this->PMPLicenseTypeID <= $pmpFieldLevelsAdopt['level_detail_photo_adopt'] ) { -
petmatchpro/trunk/public/templates/pp/adoptable-conversion.php
r3057448 r3061816 65 65 66 66 if ( !empty($this->PMPLicenseTypeID) && ($this->PMPLicenseTypeID != constant('FREE_LEVEL')) ) { 67 if (array_key_exists('adoptable_animal_detail_ icons_max', $this->generalOptions)) {68 $maxThumbs = $this->generalOptions['adoptable_animal_detail_ icons_max'];67 if (array_key_exists('adoptable_animal_detail_thumbs_max', $this->generalOptions)) { 68 $maxThumbs = $this->generalOptions['adoptable_animal_detail_thumbs_max']; 69 69 } else { 70 70 $maxThumbs = 6; … … 80 80 $gaParamArray['page_url'] = $_SERVER['REQUEST_URI']; 81 81 82 $thumb = 1;82 $thumb = 0; 83 83 if ( (array_key_exists(constant('PETPOINT_PHOTOS'), $animalDetails)) && ($this->PMPLicenseTypeID <= $pmpFieldLevelsAdopt['level_detail_photo_adopt']) && ($thumb <= $maxThumbs) ) { 84 84 // if ( $this->PMPLicenseTypeID <= $pmpFieldLevelsAdopt['level_detail_photo_adopt'] ) { -
petmatchpro/trunk/public/templates/pp/adoptable-default.php
r3057448 r3061816 68 68 69 69 if ( !empty($this->PMPLicenseTypeID) && ($this->PMPLicenseTypeID != constant('FREE_LEVEL')) ) { 70 if (array_key_exists('adoptable_animal_detail_ icons_max', $this->generalOptions)) {71 $maxThumbs = $this->generalOptions['adoptable_animal_detail_ icons_max'];70 if (array_key_exists('adoptable_animal_detail_thumbs_max', $this->generalOptions)) { 71 $maxThumbs = $this->generalOptions['adoptable_animal_detail_thumbs_max']; 72 72 } else { 73 73 $maxThumbs = 6; … … 82 82 $gaParamArray['page_url'] = $_SERVER['REQUEST_URI']; 83 83 84 $thumb = 1;84 $thumb = 0; 85 85 if ( (array_key_exists(constant('PETPOINT_PHOTOS'), $animalDetails)) && ($this->PMPLicenseTypeID <= $pmpFieldLevelsAdopt['level_detail_photo_adopt']) && ($thumb <= $maxThumbs) ) { 86 86 foreach($animalDetails[constant('PETPOINT_PHOTOS')] as $photoURL){ -
petmatchpro/trunk/public/templates/pp/adoptable-wide.php
r3057448 r3061816 67 67 68 68 if ( !empty($this->PMPLicenseTypeID) && ($this->PMPLicenseTypeID != constant('FREE_LEVEL')) ) { 69 if (array_key_exists('adoptable_animal_detail_ icons_max', $this->generalOptions)) {70 $maxThumbs = $this->generalOptions['adoptable_animal_detail_ icons_max'];69 if (array_key_exists('adoptable_animal_detail_thumbs_max', $this->generalOptions)) { 70 $maxThumbs = $this->generalOptions['adoptable_animal_detail_thumbs_max']; 71 71 } else { 72 72 $maxThumbs = 6; … … 81 81 $gaParamArray['page_url'] = $_SERVER['REQUEST_URI']; 82 82 83 $thumb = 1;83 $thumb = 0; 84 84 if ( (array_key_exists(constant('PETPOINT_PHOTOS'), $animalDetails)) && ($this->PMPLicenseTypeID <= $pmpFieldLevelsAdopt['level_detail_photo_adopt']) && ($thumb <= $maxThumbs) ) { 85 85 // if ( $this->PMPLicenseTypeID <= $pmpFieldLevelsAdopt['level_detail_photo_adopt'] ) { -
petmatchpro/trunk/public/templates/pp/found-default.php
r3057448 r3061816 66 66 67 67 if ( !empty($this->PMPLicenseTypeID) && ($this->PMPLicenseTypeID != constant('FREE_LEVEL')) ) { 68 if (array_key_exists('adoptable_animal_detail_ icons_max', $this->generalOptions)) {69 $maxThumbs = $this->generalOptions['adoptable_animal_detail_ icons_max'];68 if (array_key_exists('adoptable_animal_detail_thumbs_max', $this->generalOptions)) { 69 $maxThumbs = $this->generalOptions['adoptable_animal_detail_thumbs_max']; 70 70 } else { 71 71 $maxThumbs = 6; … … 80 80 $gaParamArray['event_action'] = 'Select'; 81 81 $gaParamArray['page_url'] = $_SERVER['REQUEST_URI']; 82 $thumb = 1; 82 83 $thumb = 0; 83 84 if ( (array_key_exists(constant('PETPOINT_PHOTOS'), $animalDetails)) && ($this->PMPLicenseTypeID <= $pmpFieldLevelsFound['level_detail_photo_found']) && ($thumb <= $maxThumbs) ) { 84 85 // if ( $this->PMPLicenseTypeID <= $pmpFieldLevelsFound['level_detail_photo_found'] ) { -
petmatchpro/trunk/public/templates/pp/found-poster.php
r3057448 r3061816 66 66 67 67 if ( !empty($this->PMPLicenseTypeID) && ($this->PMPLicenseTypeID != constant('FREE_LEVEL')) ) { 68 $maxThumbs = $this->generalOptions['adoptable_animal_detail_icons_max']; 69 if (!is_numeric($maxThumbs)) { 68 if (array_key_exists('adoptable_animal_detail_thumbs_max', $this->generalOptions)) { 69 $maxThumbs = $this->generalOptions['adoptable_animal_detail_thumbs_max']; 70 } else { 70 71 $maxThumbs = 6; 71 72 } 72 73 } 73 74 74 75 if ( !empty($this->PMPLicenseTypeID) && ($this->PMPLicenseTypeID != constant('FREE_LEVEL')) ) { 75 76 $output .= ' <div class="pmp-details-thumbs">'; … … 82 83 $gaParamArray['page_url'] = $_SERVER['REQUEST_URI']; 83 84 84 $thumb = 1;85 $thumb = 0; 85 86 if ( (array_key_exists(constant('PETPOINT_PHOTOS'), $animalDetails)) && ($this->PMPLicenseTypeID <= $pmpFieldLevelsFound['level_detail_photo_found']) && ($thumb <= $maxThumbs) ) { 86 87 // if ( $this->PMPLicenseTypeID <= $pmpFieldLevelsFound['level_detail_photo_found'] ) { -
petmatchpro/trunk/public/templates/pp/lost-default.php
r3057448 r3061816 66 66 67 67 if ( !empty($this->PMPLicenseTypeID) && ($this->PMPLicenseTypeID != constant('FREE_LEVEL')) ) { 68 if (array_key_exists('adoptable_animal_detail_ icons_max', $this->generalOptions)) {69 $maxThumbs = $this->generalOptions['adoptable_animal_detail_ icons_max'];68 if (array_key_exists('adoptable_animal_detail_thumbs_max', $this->generalOptions)) { 69 $maxThumbs = $this->generalOptions['adoptable_animal_detail_thumbs_max']; 70 70 } else { 71 71 $maxThumbs = 6; … … 80 80 $gaParamArray['event_action'] = 'Select'; 81 81 $gaParamArray['page_url'] = $_SERVER['REQUEST_URI']; 82 $thumb = 1; 82 83 $thumb = 0; 83 84 if ( (array_key_exists(constant('PETPOINT_PHOTOS'), $animalDetails)) && ($this->PMPLicenseTypeID <= $pmpFieldLevelsLost['level_detail_photo_lost']) && ($thumb <= $maxThumbs) ) { 84 85 // if ( $this->PMPLicenseTypeID <= $pmpFieldLevelsLost['level_detail_photo_lost'] ) { -
petmatchpro/trunk/public/templates/pp/lost-poster.php
r3057448 r3061816 66 66 67 67 if ( !empty($this->PMPLicenseTypeID) && ($this->PMPLicenseTypeID != constant('FREE_LEVEL')) ) { 68 $maxThumbs = $this->generalOptions['adoptable_animal_detail_icons_max']; 69 if (!is_numeric($maxThumbs)) { 68 if (array_key_exists('adoptable_animal_detail_thumbs_max', $this->generalOptions)) { 69 $maxThumbs = $this->generalOptions['adoptable_animal_detail_thumbs_max']; 70 } else { 70 71 $maxThumbs = 6; 71 72 } … … 82 83 $gaParamArray['page_url'] = $_SERVER['REQUEST_URI']; 83 84 84 $thumb = 1;85 $thumb = 0; 85 86 if ( (array_key_exists(constant('PETPOINT_PHOTOS'), $animalDetails)) && ($this->PMPLicenseTypeID <= $pmpFieldLevelsLost['level_detail_photo_lost']) && ($thumb <= $maxThumbs) ) { 86 87 // if ( $this->PMPLicenseTypeID <= $pmpFieldLevelsLost['level_detail_photo_lost'] ) { -
petmatchpro/trunk/public/templates/rg/adoptable-cpa.php
r3057448 r3061816 100 100 101 101 if ( !empty($this->PMPLicenseTypeID) && ($this->PMPLicenseTypeID != constant('FREE_LEVEL')) ) { 102 if (array_key_exists('adoptable_animal_detail_ icons_max', $this->generalOptions)) {103 $maxThumbs = $this->generalOptions['adoptable_animal_detail_ icons_max'];102 if (array_key_exists('adoptable_animal_detail_thumbs_max', $this->generalOptions)) { 103 $maxThumbs = $this->generalOptions['adoptable_animal_detail_thumbs_max']; 104 104 } else { 105 105 $maxThumbs = 6; … … 115 115 $gaParamArray['page_url'] = $_SERVER['REQUEST_URI']; 116 116 117 $thumb = 1;117 $thumb = 0; 118 118 $photoLevelKey = constant('LEVEL_PREFIX_ANIMAL_DETAIL') . constant('RESCUEGROUPS_PHOTOS') . '_adopt'; 119 119 //echo 'Photo Level Key = ' . $photoLevelKey . '<br>'; -
petmatchpro/trunk/public/templates/rg/adoptable-default.php
r3057448 r3061816 72 72 73 73 if ( !empty($this->PMPLicenseTypeID) && ($this->PMPLicenseTypeID != constant('FREE_LEVEL')) ) { 74 if (array_key_exists('adoptable_animal_detail_ icons_max', $this->generalOptions)) {75 $maxThumbs = $this->generalOptions['adoptable_animal_detail_ icons_max'];74 if (array_key_exists('adoptable_animal_detail_thumbs_max', $this->generalOptions)) { 75 $maxThumbs = $this->generalOptions['adoptable_animal_detail_thumbs_max']; 76 76 } else { 77 77 $maxThumbs = 6; … … 87 87 $gaParamArray['page_url'] = $_SERVER['REQUEST_URI']; 88 88 89 $thumb = 1;89 $thumb = 0; 90 90 $photoLevelKey = constant('LEVEL_PREFIX_ANIMAL_DETAIL') . constant('RESCUEGROUPS_PHOTOS') . '_adopt'; 91 91 //echo 'Photo Level Key = ' . $photoLevelKey . '<br>';
Note: See TracChangeset
for help on using the changeset viewer.