| @@ 1187-1228 (lines=42) @@ | ||
| 1184 | ||
| 1185 | ||
| 1186 | $gd_page = ''; |
|
| 1187 | if ( geodir_is_page( 'home' ) ) {
|
|
| 1188 | $gd_page = 'home'; |
|
| 1189 | $meta_desc = ( get_option( 'geodir_meta_desc_homepage' ) ) ? get_option( 'geodir_meta_desc_homepage' ) : $meta_desc; |
|
| 1190 | } elseif ( geodir_is_page( 'detail' ) ) {
|
|
| 1191 | $gd_page = 'detail'; |
|
| 1192 | $meta_desc = ( get_option( 'geodir_meta_desc_detail' ) ) ? get_option( 'geodir_meta_desc_detail' ) : $meta_desc; |
|
| 1193 | } elseif ( geodir_is_page( 'pt' ) ) {
|
|
| 1194 | $gd_page = 'pt'; |
|
| 1195 | $meta_desc = ( get_option( 'geodir_meta_desc_pt' ) ) ? get_option( 'geodir_meta_desc_pt' ) : $meta_desc; |
|
| 1196 | } elseif ( geodir_is_page( 'listing' ) ) {
|
|
| 1197 | $gd_page = 'listing'; |
|
| 1198 | $meta_desc = ( get_option( 'geodir_meta_desc_listing' ) ) ? get_option( 'geodir_meta_desc_listing' ) : $meta_desc; |
|
| 1199 | } elseif ( geodir_is_page( 'location' ) ) {
|
|
| 1200 | $gd_page = 'location'; |
|
| 1201 | $meta_desc = ( get_option( 'geodir_meta_desc_location' ) ) ? get_option( 'geodir_meta_desc_location' ) : $meta_desc; |
|
| 1202 | $meta_desc = apply_filters( 'geodir_seo_meta_location_description', $meta_desc ); |
|
| 1203 | ||
| 1204 | } elseif ( geodir_is_page( 'search' ) ) {
|
|
| 1205 | $gd_page = 'search'; |
|
| 1206 | $meta_desc = ( get_option( 'geodir_meta_desc_search' ) ) ? get_option( 'geodir_meta_desc_search' ) : $meta_desc; |
|
| 1207 | } elseif ( geodir_is_page( 'add-listing' ) ) {
|
|
| 1208 | $gd_page = 'add-listing'; |
|
| 1209 | $meta_desc = ( get_option( 'geodir_meta_desc_add-listing' ) ) ? get_option( 'geodir_meta_desc_add-listing' ) : $meta_desc; |
|
| 1210 | } elseif ( geodir_is_page( 'author' ) ) {
|
|
| 1211 | $gd_page = 'author'; |
|
| 1212 | $meta_desc = ( get_option( 'geodir_meta_desc_author' ) ) ? get_option( 'geodir_meta_desc_author' ) : $meta_desc; |
|
| 1213 | } elseif ( geodir_is_page( 'login' ) ) {
|
|
| 1214 | $gd_page = 'login'; |
|
| 1215 | $meta_desc = ( get_option( 'geodir_meta_desc_login' ) ) ? get_option( 'geodir_meta_desc_login' ) : $meta_desc; |
|
| 1216 | } elseif ( geodir_is_page( 'listing-success' ) ) {
|
|
| 1217 | $gd_page = 'listing-success'; |
|
| 1218 | $meta_desc = ( get_option( 'geodir_meta_desc_listing-success' ) ) ? get_option( 'geodir_meta_desc_listing-success' ) : $meta_desc; |
|
| 1219 | } |
|
| 1220 | ||
| 1221 | ||
| 1222 | if ( $meta_desc ) {
|
|
| 1223 | $meta_desc = stripslashes_deep( $meta_desc ); |
|
| 1224 | /** |
|
| 1225 | * Filter page description to replace variables. |
|
| 1226 | * |
|
| 1227 | * @since 1.5.4 |
|
| 1228 | * |
|
| 1229 | * @param string $title The page description including variables. |
|
| 1230 | * @param string $gd_page The GeoDirectory page type if any. |
|
| 1231 | */ |
|
| @@ 1863-1902 (lines=40) @@ | ||
| 1860 | ||
| 1861 | ||
| 1862 | $gd_page = ''; |
|
| 1863 | if(geodir_is_page('home')){
|
|
| 1864 | $gd_page = 'home'; |
|
| 1865 | $title = (get_option('geodir_meta_title_homepage')) ? get_option('geodir_meta_title_homepage') : $title;
|
|
| 1866 | } |
|
| 1867 | elseif(geodir_is_page('detail')){
|
|
| 1868 | $gd_page = 'detail'; |
|
| 1869 | $title = (get_option('geodir_meta_title_detail')) ? get_option('geodir_meta_title_detail') : $title;
|
|
| 1870 | } |
|
| 1871 | elseif(geodir_is_page('pt')){
|
|
| 1872 | $gd_page = 'pt'; |
|
| 1873 | $title = (get_option('geodir_meta_title_pt')) ? get_option('geodir_meta_title_pt') : $title;
|
|
| 1874 | } |
|
| 1875 | elseif(geodir_is_page('listing')){
|
|
| 1876 | $gd_page = 'listing'; |
|
| 1877 | $title = (get_option('geodir_meta_title_listing')) ? get_option('geodir_meta_title_listing') : $title;
|
|
| 1878 | } |
|
| 1879 | elseif(geodir_is_page('location')){
|
|
| 1880 | $gd_page = 'location'; |
|
| 1881 | $title = (get_option('geodir_meta_title_location')) ? get_option('geodir_meta_title_location') : $title;
|
|
| 1882 | } |
|
| 1883 | elseif(geodir_is_page('search')){
|
|
| 1884 | $gd_page = 'search'; |
|
| 1885 | $title = (get_option('geodir_meta_title_search')) ? get_option('geodir_meta_title_search') : $title;
|
|
| 1886 | } |
|
| 1887 | elseif(geodir_is_page('add-listing')){
|
|
| 1888 | $gd_page = 'add-listing'; |
|
| 1889 | $title = (get_option('geodir_meta_title_add-listing')) ? get_option('geodir_meta_title_add-listing') : $title;
|
|
| 1890 | } |
|
| 1891 | elseif(geodir_is_page('author')){
|
|
| 1892 | $gd_page = 'author'; |
|
| 1893 | $title = (get_option('geodir_meta_title_author')) ? get_option('geodir_meta_title_author') : $title;
|
|
| 1894 | } |
|
| 1895 | elseif(geodir_is_page('login')){
|
|
| 1896 | $gd_page = 'login'; |
|
| 1897 | $title = (get_option('geodir_meta_title_login')) ? get_option('geodir_meta_title_login') : $title;
|
|
| 1898 | } |
|
| 1899 | elseif(geodir_is_page('listing-success')){
|
|
| 1900 | $gd_page = 'listing-success'; |
|
| 1901 | $title = (get_option('geodir_meta_title_listing-success')) ? get_option('geodir_meta_title_listing-success') : $title;
|
|
| 1902 | } |
|
| 1903 | ||
| 1904 | ||
| 1905 | /** |
|