$address = $temple[0]->address; $googleaddress = trim($temple[0]->googleaddress); $phone = $temple[0]->phone; $general_info = $temple[0]->general_info; $description = $temple[0]->description; $heighlight = $temple[0]->heighlight; $latitude = $temple[0]->latitude; $longitude = $temple[0]->longitude; $location = $temple[0]->location; $nearrailway = $temple[0]->nearrailway; $nearairport = $temple[0]->nearairport; $accomodation = $temple[0]->accomodation; $post_id = $temple[0]->post_id; $accomodats = unserialize($accomodation); $stars = Stardetail(); $categories = Categorydetail(); $urchavar = Templeoption($temple_id, 'urchavar'); $mother = Templeoption($temple_id, 'mother'); $sacredtree = Templeoption($temple_id, 'sacredtree'); $tirtha = Templeoption($temple_id, 'tirtha'); $ecclesiasticus_pooja = Templeoption($temple_id, 'ecclesiasticus_pooja'); $creepy = Templeoption($temple_id, 'creepy'); $legendary_name = Templeoption($temple_id, 'legendary_name'); $trail = Templeoption($temple_id, 'trail'); $querystr = "SELECT * FROM " . $prefix . "temple_state"; $states = $wpdb->get_results($querystr, OBJECT); $querystr1 = "SELECT * FROM " . $prefix . "temple_city"; $cities = $wpdb->get_results($querystr1, OBJECT); $querystr2 = "SELECT * FROM " . $prefix . "temple_god"; $gods = $wpdb->get_results($querystr2, OBJECT); $packagetypes = packagetypedetail();
?> </div> <div class="all_temple"> <h1>Temples</h1> <ul class="left_ul"> <li><a href="<?php echo get_option('home'); ?> /ten-temples">To visit the temples of ten</a></li> <li><a href="<?php echo get_option('home'); ?> /star-temples">Star temples</a></li> <?php $categories = Categorydetail('', " order by id asc"); if (count($categories) > 0) { foreach ($categories as $category) { ?> <li><a href="<?php echo get_option('home'); ?> /category-temples/?cid=<?php echo $category->id; ?> "><?php _e($category->category); if ($category->showcount == '1') { $totaltemple = totalcategorytemples($category->id); if ($totaltemple > 0) { echo ' (' . $totaltemple . ')';
<?php global $wpdb, $signature; $prefix = $wpdb->base_prefix; $error = array(); $id = $_REQUEST['id']; $st = Categorydetail($id); $category = $st[0]->category; $showcount = $st[0]->showcount; if (isset($_POST['registration'])) { $category = $_POST['category']; if (trim($category) == '') { array_push($error, 'Please enter Category.'); } $showcount = $_POST['showcount']; if (count($error) <= 0) { $sql = "UPDATE `" . $prefix . "temple_categories` set category='{$category}', showcount='{$showcount}' where id='{$id}'"; $result = $wpdb->query($sql); $url = get_option('home') . '/wp-admin/admin.php?page=ManageCategories&update=succ'; echo "<script>window.location='" . $url . "'</script>"; } } ?> <link href="<?php echo get_option('home'); ?> /wp-content/plugins/temple/css/pagedesign.css" rel="stylesheet"/> <script type="text/javascript" src="<?php echo get_option('home'); ?> /wp-content/plugins/temple/js/jquery.js"></script>
<?php /* Template Name: Category Temples */ @session_start(); global $wpdb, $post; $prefix = $wpdb->base_prefix; get_header(); $category_id = ''; $title = ''; if (isset($_REQUEST['cid']) && trim($_REQUEST['cid']) != '' && trim($_REQUEST['cid']) > 0) { $category_id = $_REQUEST['cid']; $category = Categorydetail($category_id); if (count($category) > 0) { $title = $category[0]->category; } } ?> <div class="container"> <?php get_sidebar(); ?> <div class="mid_content"> <h1><?php _e($title); ?> </h1> <div class="science_box"> <div class="all_temple1">