asgalEffectgallery($content); return $returnGallery; } function appsliderPage() { add_menu_page('Apptha Slider Gallery', 'Apptha Slider Gallery', '4', 'slideAlbum', 'show_appslideMenu',get_bloginfo('url').'/wp-content/plugins/'.dirname(plugin_basename(__FILE__)).'/images/icon.png'); //add_submenu_page("asgallAlbum", "Mac Gallery", "Galleries",4, "macGallery","show_asgallMenu"); add_submenu_page('slideAlbum', 'Albums', 'Albums', 4, 'slideAlbum', 'show_appslideMenu'); add_submenu_page('slideAlbum', 'Image upload', 'Upload Photos', 'manage_options', 'slidePhotos', 'show_appslideMenu'); //add_submenu_page('asgallAlbum', 'Tags', 'Tags', 'manage_options', 'asgalltags', 'show_asgallMenu'); add_submenu_page('slideAlbum', 'Settings', 'Settings', 'manage_options', 'slideSettings', 'show_appslideMenu'); } function show_appslideMenu() { ?>
Note : Apptha Slider Gallery can be easily inserted to the Post / Page by adding the following code :

(i) [asgall] - Use this code to show entire gallery, use only once in a page/post.
(ii) [asgall albid=1] - Use this code to display photos from particular album [Here '1' is the AlbumId]
(iii) [asgall type=popular] - Use this code to display slider without albums, the photos are sorted based on type[Two other types are type=recent or type=featured or type=albid-1 ] , [Here '1' is the Album Id] use only once in particular page/post.
'', 'show'=>'', 'excerpt'=>'','exclude'=>''); } if(isset($_POST['submit_license'])) { $options['title'] = strip_tags(stripslashes($_POST['get_license'])); update_option('get_wpappslider_key', $options); } // Admin Setting For Mac Photo Gallery function asgall_get_domain($url) { $pieces = parse_url($url); $domain = isset($pieces['host']) ? $pieces['host'] : ''; if (preg_match('/(?P[a-z0-9][a-z0-9\-]{1,63}\.[a-z\.]{2,6})$/i', $domain, $regs)) { return $regs['domain']; } return false; } function asgallSettings() { global $wpdb; $folder = dirname(plugin_basename(__FILE__)); $site_url = get_bloginfo('url'); $split_title = $wpdb->get_var("SELECT option_value FROM ".$wpdb->prefix."options WHERE option_name='get_wpappslider_key'"); $get_title = unserialize($split_title); $strDomainName = $site_url; preg_match("/^(http:\/\/)?([^\/]+)/i", $strDomainName, $subfolder); preg_match("/(?P[a-z0-9][a-z0-9\-]{1,63}\.[a-z\.]{2,6})$/i", $subfolder[2], $matches); $customerurl = $matches['domain']; $customerurl = str_replace("www.", "", $customerurl); $customerurl = str_replace(".", "D", $customerurl); $customerurl = strtoupper($customerurl); $get_key = asgall_macgal_generate($customerurl); ?> get_results('SHOW COLUMNS FROM '. $wpdb->prefix . 'asgall_settings_menu'); $settingColumns = array('sno', 'asgall-slide-photo-width', 'asgall-slide-photo-height', 'asgall-alb-cols', 'asgall-alb-rows', 'asgall-alb-photo-width', 'asgall-alb-photo-Height', 'asgall-alb-vspace', 'asgall-alb-hspace', 'asgall-general-share-pho', 'asgall-general-download', 'asgall_facebook_api', 'asgall-photo-tumb-w', 'asgall-photo-tumb-h', 'asgall-photo-gene-w', 'asgall-photo-gene-h','asgall-slider','asgall-slider-type'); //print_r($settingColumns); $uploaddata = array(); for( $i = 0 ; $i < count($settingColumns) ; $i++ ){ if($i == 17) { $uploaddata[$settingColumns[17]] = trim($_REQUEST[$settingColumns[17]]).'-'.trim($_REQUEST['renderalblist']); } else { $uploaddata[$settingColumns[$i]] = trim($_REQUEST[$settingColumns[$i]]); } } $uploaddata['sno'] = 1; $tableName = $wpdb->prefix."asgall_settings_menu"; $wpdb->update( $tableName , $uploaddata , array( 'sno' => 1) ); $msg ='Updated Successfully'; } if( isset($_POST['Photos_Resize'] )) //resize the images isset($_POST['asgallSet_upt_gener'] ) { $tablename = $wpdb->prefix."asgall_settings_menu"; $settingValues = $wpdb->get_results("SELECT * FROM $tablename " ,ARRAY_A ); // echo "
";print_r($settingValues);echo "
";
  	 $colNames = array('asgall-slide-photo-width','asgall-slide-photo-height','asgall-alb-photo-width','asgall-alb-photo-Height','asgall-photo-tumb-w','asgall-photo-tumb-h','asgall-photo-gene-w','asgall-photo-gene-h');
  	 $numOfTimes = count($colNames);
  	 $findValues = array();
  	 $updateintable = array();  // use to update in table
  	 for($i = 0 ; $i < $numOfTimes ; $i++ )
  	 {		
  	 	  // echo $i.'***** '.$settingValues[0][$colNames[$i]]	.'=='.  $_REQUEST[$colNames[$i]]."
"; $isstore = $settingValues[0][$colNames[$i]] - $_REQUEST[$colNames[$i]]."
"; ; $isstore = intval($isstore); if($isstore){ $updateintable[$colNames[$i]] = $_REQUEST[$colNames[$i]] ; $findValues[] = $i; } } $tableName = $wpdb->prefix."asgall_settings_menu"; $wpdb->update( $tableName , $updateintable , array( 'sno' => 1) ); $c = count($findValues); if($c) { sort($findValues); $changeColNames = array(); for($j = 0 ; $j < $c ; $j++ ) { $changeColNames[] = $colNames[$findValues[$j]]; //$updateintable[$colNames[$findValues[$j]]] = $_REQUEST[$colNames[$j]] ; } $allPhotsData = array(); for ($i = 0 ; $i< $c ; $i++) { $value = intval($findValues[$i]); if($value % 2 == 0){ // if changed value start with even then if(in_array($value+1 , $findValues)){ // if he change same photo W & H $colW = $_REQUEST[$colNames[$value]]; //taking W value $colH = $_REQUEST[$colNames[$value+1]]; // Taking HEIGHT VALU $allPhotsData[$i] = array('name' => $changeColNames[$i], 'width' => $colW , 'height' => $colH); $i++; //deleting height value } else{ // if he chane only Height $colW = $_REQUEST[$colNames[$value]]; $colH = $settingValues[0][$colNames[$value+1]]; $allPhotsData[$i] = array('name' => $changeColNames[$i], 'width' => $colW , 'height' => $colH); } } else{ // if changed value is odd then if(in_array( ($value-1) , $findValues)){ $colW = $_REQUEST[$colNames[$value-1]]; $colH = $_REQUEST[$colNames[$value]]; $allPhotsData[$i] = array('name' => $changeColNames[$i], 'width' => $colW , 'height' => $colH); } else{ $colW = $settingValues[0][$colNames[$value-1]]; $colH = $_REQUEST[$colNames[$value]]; $allPhotsData[$i] = array('name' => $changeColNames[$i], 'width' => $colW , 'height' => $colH); } } }//for end }//if end //echo "
"; print_r($allPhotsData);	echo "
";
  	    
  echo "  ";
  echo "  ";
  if(is_array($allPhotsData))
  {
 	foreach($allPhotsData as $key => $values){
 	 
  	 echo "";
  
 	}
  }  	 
 
     
   }// IF END FOR RESIZE THUMBNILS

   $viewSetting = $wpdb->get_row("SELECT * FROM " . $wpdb->prefix . "asgall_settings_menu" , ARRAY_A);
   

  	        if($get_title['title'] != $get_key)
        {
        ?>







 

No of Columns
No of Rows
Slider /> Enable    /> Disable
Slider Image /> Popular /> Recent
/> Featured /> Albums #photohide { display:block; } '; } ?>
Album cover size Width  px   Height   px
Vertical Space px
Horizontal Space px
Size of Photo Width px   Height  px
General Settings
Download /> Enable    /> Disable
Facebook API Id
(Please provide API to enable facebook share)

To create new ID, Facebook App
Photo Settings
Generate Thumbnails Size Width px   Height  px
Single Photo View Stage Size Width px   Height  px

query("INSERT INTO " . $wpdb->prefix . "asgallalbum (`asgallAlbum_id`, `asgallAlbum_name`, `asgallAlbum_description`, `asgallAlbum_image`, `asgallAlbum_status`, `asgallAlbum_date`,`asgallGallery_id`,`is_delete`) VALUES (1, 'First Album', 'This is my first album ', '', 'ON', NOW(), 1, 0)"); $insertGalleryDefault = $wpdb->query("INSERT INTO " . $wpdb->prefix . "asgallgallery (`asgallGallery_id`, `asgallGallery_name`, `asgallGallery_status`) VALUES (1, 'Default Gallery', 'ON')"); } $lookupObj = array(); $chars_str; $chars_array = array(); function asgall_macgal_generate($domain) { $code=asgall_macgal_encrypt($domain); $code = substr($code,0,25)."CONTUS"; return $code; } // Include the respective page based of the page request in url function encrypt() { $iv = iv(); $encryptKey = get_option('EncriptionKey'); $data = mcrypt_encrypt(MCRYPT_RIJNDAEL_128, 'appthaslider', 'Powered By Apptha', MCRYPT_MODE_ECB, $iv); return base64_encode($data); } function iv() { $iv_size = mcrypt_get_iv_size(MCRYPT_RIJNDAEL_256, MCRYPT_MODE_ECB); $iv = mcrypt_create_iv($iv_size, MCRYPT_RAND); return $iv; } function apiKey_asgall() { $const = "+fKIAPT7CCcFHvkVYoXS5J8SQ3KKhLIybStOQZIumfexdp5FUHcL2x+wtCgrR9S7yPgE6B2r0x3wnvNXrBRqtj588gTqu17cYHkDyuSPZPM="; $iv_size = mcrypt_get_iv_size(MCRYPT_RIJNDAEL_256, MCRYPT_MODE_ECB); $iv = mcrypt_create_iv($iv_size, MCRYPT_RAND); $const = base64_decode($const); if (conf__PHSHOP_MACDOC_EXTENSION != 1) $val = mcrypt_decrypt(MCRYPT_RIJNDAEL_128, "appthaslider", $const, MCRYPT_MODE_ECB, $iv); return $val; } function asgall_macgal_encrypt($tkey) { $message = "EW-ASGMP0EFIL9XEV8YZAL7KCIUQ6NI5OREH4TSEB3TSRIF2SI1ROTAIDALG-JW"; for($i=0;$i=count($key_array)) { $kPos = 0; } } return $enc_message; } function asgall_macgal_getOffset($start, $end) { $chars_str = "WJ-GLADIATOR1IS2FIRST3BEST4HERO5IN6QUICK7LAZY8VEX9LIFEMP0"; for($i=0;$i=0;$i--) { $lookupObj[ord($chars_array[$i])] = $i; } $sNum = $lookupObj[ord($start)]; $eNum = $lookupObj[ord($end)]; $offset = $eNum-$sNum; if ($offset<0) { $offset = count($chars_array)+($offset); } return $offset; } /* Function to invoke install player plugin */ function asgall_macGallery_installFile() { require_once(dirname(__FILE__) . '/asgallInstall.php'); asgallGallery_install(); } /* Function to uninstall player plugin */ function appslider_deinstall() { global $wpdb, $wp_version; $table_appgallSettings = $wpdb->prefix . 'asgall_settings_menu'; $table_appgallAlbum = $wpdb->prefix . 'asgallalbum'; $table_appgallPhotos = $wpdb->prefix . 'asgallphotos'; $table_appgallGallery = $wpdb->prefix . 'asgallgallery'; $wpdb->query("DROP TABLE IF EXISTS `" . $table_appgallSettings . "`"); $wpdb->query("DROP TABLE IF EXISTS `" . $table_appgallAlbum . "`"); $wpdb->query("DROP TABLE IF EXISTS `" . $table_appgallPhotos . "`"); $wpdb->query("DROP TABLE IF EXISTS `" . $table_appgallGallery . "`"); $uploadDir = wp_upload_dir(); $path = $uploadDir['basedir'].'/apptha-slider-gallery/'; if(is_dir($path)){ chmod($path , 0777); $photos = opendir($path); while($content = readdir($photos) ) { if($content != '.' && $content != '..') { $deleteis = $path.$content; unlink($deleteis); } } } } /* Function to activate player plugin */ function appslider_activate() { asgall_loadsettings_values(); create_asgall_folder(); } register_activation_hook(plugin_basename(dirname(__FILE__)) . '/asgallSlider.php', 'asgall_macGallery_installFile'); register_activation_hook(__FILE__, 'appslider_activate'); register_uninstall_hook(__FILE__, 'appslider_deinstall'); /* Function to deactivate player plugin */ function appslider_deactivate() { global $wpdb; $wpdb->query("DELETE FROM " . $wpdb->prefix . "posts WHERE post_content='[asgall]'"); } register_deactivation_hook(__FILE__, 'appslider_deactivate'); add_shortcode('asgall', 'appslider_Render'); //gallery group functionality //add_shortcode('macGroup', 'CONTUS_macGalleryRender'); // CONTENT FILTER add_filter('the_content', 'asgall_Slidergallery'); //gallery group functionality //add_filter('the_content', 'Macgallerygroup'); // OPTIONS MENU add_action('admin_menu', 'appsliderPage'); function asgall_setplayerscripts() { $site_url = get_bloginfo('url'); $folder = dirname(plugin_basename(__FILE__)); ?>