Activity Stream
48,167 MEMBERS
61234 ONLINE
besthostingforums On YouTube Subscribe to our Newsletter besthostingforums On Twitter besthostingforums On Facebook besthostingforums On facebook groups

Page 4 of 4 FirstFirst ... 234
Results 31 to 39 of 39
  1.     
    #31
    Banned
    Website's:
    worldwidexs.com.au
    Can you follow the steps and re-do the plugin?

  2.     
    #32
    Member
    Website's:
    tribupinoy.net pinoyddl.org
    @0ccul7: can you help me on my wordpress blog?

    i want to automatically make my embed image to Featured Image on my post!

  3.     
    #33
    Member

    Default wordpress autoformat in HTML

    Hi,
    I'm using HTML editor. When i write it like this

    Code: 
    ....
    02 ? Bangarang feat. Sirah (Original Mix)
    03 ? Breakn? A Sweat (Original Mix)
    ...
    then click "Update" it becomes like this, adds extra <br> tags
    Code: 
    ....
    02 ? Bangarang feat. Sirah (Original Mix)<br />
    03 ? Breakn? A Sweat (Original Mix)<br />
    ...
    I don't want it like this. I want the code stays exactly how I wrote it. Not a single dot extra.
    I tried several plugins like, raw html, ps disable autoformat, and some "text...". None of them worked. I have 3.2.1

  4.   Sponsored Links

  5.     
    #34
    Member
    Website's:
    FlowForums.com
    Would you happen to know how I can remove the second footer without it crashing the theme?



    If I remove anything in it the template will crash.

  6.     
    #35
    Pure Awesomeness!
    Post the footer.php code Im.z.



  7.     
    #36
    Member
    Website's:
    FlowForums.com
    PHP Code: 
    <?php 
    include("footer_content.php");echo '
    <div id="footcopy">

    <div class="onethousand_wrap">
    <span class="left"><a href="http://zenverse.net/oceanwave-wordpress-theme/">OceanWave</a> designed by <a href="http://www.maiahost.com/cms/WordPress_Hosting.html">Cheap WordPress Hosting</a></span>

    <span class="right">In conjunction with <a href="http://www.983wedding.com/" target="_blank">Wedding Invitations</a> , <a href="http://www.led-replacementbulb.com/" target="_blank">LED Replacement Bulb</a> , <a href="http://www.atomicvps.com/" target="_blank">Cloud Hosting</a>.</span>
    </div>
    </div>
    '
    ;$zenverse_global_google_analytics get_option("zenverse_global_google_analytics");if ($zenverse_global_google_analytics != "") { echo stripslashes($zenverse_global_google_analytics); }wp_footer();echo '</body></html>';  
    ?>

  8.     
    #37
    Pure Awesomeness!
    You tried removing the footcopy div and it crashed? correct? if so, I think there is a function in the functions.php file that checks for those links, could be in other files as well to make sure you don't remove the backlinks.



  9.     
    #38
    Member
    Website's:
    FlowForums.com
    Thats what I figured. I just can't seem to find it. The fuctions are very long.

    PHP Code: 
    <?php
    if ( function_exists('register_sidebar') ) {
    register_sidebar(array('name'=>'Big Sidebar',
    'before_widget' => '<div class="widgetblock">',
    'after_widget' => '</div>',
    'before_title' => '<div class="widgettitle">',
    'after_title' => '</div>',));
    }
    if ( 
    function_exists('register_sidebars') ) {
    register_sidebars(2, array('name'=>'Small Sidebar %d',
    'before_widget' => '<div class="widgetblock">',
    'after_widget' => '</div>',
    'before_title' => '<div class="widgettitle">',
    'after_title' => '</div>',));
    }

    //get admin's date of register
    $zenverse_global_blogsince get_option('zenverse_global_blogsince');
    if (
    $zenverse_global_blogsince=='' || !is_numeric($zenverse_global_blogsince) || strlen($zenverse_global_blogsince)!=4){
    $zv_get_admin_year mysql_query("SELECT user_registered FROM $wpdb->users WHERE ID=1");
    $zv_admin_year mysql_fetch_row($zv_get_admin_year);
    update_option("zenverse_global_blogsince"substr($zv_admin_year[0],0,4));
    }

    /*Start of Theme Options*/
    $oceanwave_categories_obj get_categories('hide_empty=0');
    $oceanwave_categories = array();
    $oceanwave_categories[] = '';
    foreach (
    $oceanwave_categories_obj as $oceanwave_cat) {
    $oceanwave_categories[$oceanwave_cat->cat_ID] = $oceanwave_cat->cat_name;
    }

    $themename "OceanWave";
    $shortname "oceanwave";
    $zv_themefoldername 'oceanwave';

    $options = array (
    array( 
    "name" => "Welcome to $themename Theme Options","type" => "title"),
    array( 
    "type" => "closetitle"),
    array( 
    "type" => "open"),
    array( 
    "type" => "info"),
    array( 
    "type" => "close"),

    array( 
    "name" => "Logo Settings","type" => "title"),
    array( 
    "type" => "closetitle"),
    array( 
    "type" => "open"),
    array( 
    "name" => "Logo Options",
        
    "desc" => "Customise your blog logo",
        
    "id" => $shortname."_logo",
        
    "type" => "select",
        
    "std" => "0",
        
    "options" => array("Text Logo - Use Default Blog Settings","Custom Image - Use setting below")),
    array( 
    "name" => "Custom Logo",
        
    "desc" => "If you choose Custom Image as your logo, please state the image's URL.",
        
    "id" => $shortname."_customlogo",
        
    "type" => "text",
        
    "std" => ""),
    array( 
    "type" => "close"),

    array( 
    "name" => "Categories Navigation","type" => "title"),
    array( 
    "type" => "closetitle"),
    array( 
    "type" => "open"),
    array(  
    "name" => "Categories to show at Navigation Bar<br /><small>(Please enable Javascript to use this)</small>",
        
    "desc" => "Choose the categories you want to show at the navigation bar under the logo.<br /> Choose only important categories to avoid overflow (which looks bad in MSIE)",
        
    "id" => "zenverse_global_showcats",
        
    "std" => "",
        
    "type" => "showcats"),
    array(  
    "name" => "",
        
    "id" => "zenverse_global_showcats_sortby",
        
    "type" => "empty"),
    array(  
    "name" => "",
        
    "id" => "zenverse_global_showcats_order",
        
    "type" => "empty"),
    array( 
    "type" => "close"),


    array( 
    "name" => "Featured Content","type" => "title"),
    array( 
    "type" => "closetitle"),
    array( 
    "type" => "open"),
    array( 
    "name" => "Disable Featured Content?",
        
    "desc" => "Featured Content will be displayed at the top of blog index.<br />It is an <b>image slideshow</b> that uses your <b>Post Thumbnails</b>.",
        
    "id" => $shortname."_featured_disable",
        
    "type" => "checkbox",
        
    "std" => "false"),
    array( 
    "name" => "Featured Category",
        
    "desc" => "Blog posts in this category <b>that has a Post Thumbnails</b> will be displayed in the Featured slideshow.",
        
    "id" => $shortname."_featured_cat",
        
    "type" => "select",
        
    "options" => $oceanwave_categories,
        
    "std" => "0"),
    array( 
    "name" => "Number of Featured Posts",
        
    "desc" => "Limit the number of featured posts being displayed. 5 Thumbnails will be displayed at a time, therefore we recommended you to choose multiple of 5 (5, 10, 15 or 20)",
        
    "id" => $shortname."_featured_limit",
        
    "type" => "select",
        
    "options" => array(1=>'1','2','3','4','5','6','7','8','9','10','11','12','13','14','15','16','17','18','19','20'),
        
    "std" => "5"),
    array( 
    "type" => "close"),



    array( 
    "name" => "Blog Index (Homepage) Settings","type" => "title"),
    array( 
    "type" => "closetitle"),
    array( 
    "type" => "open"),
    array( 
    "name" => "Disable Facebook Like button?",
        
    "desc" => "Check this checkbox to <b>hide</b> the Facebook Like button",
        
    "id" => $shortname."_sb_fblike_disable",
        
    "type" => "checkbox",
        
    "std" => ""),
    array( 
    "name" => "Disable Facebook Share button?",
        
    "desc" => "Check this checkbox to <b>hide</b> the Facebook Share button",
        
    "id" => $shortname."_sb_fbshare_disable",
        
    "type" => "checkbox",
        
    "std" => ""),
    array( 
    "name" => "Disable Twitter Share button?",
        
    "desc" => "Check this checkbox to <b>hide</b> the Twitter Share button",
        
    "id" => $shortname."_sb_twitter_disable",
        
    "type" => "checkbox",
        
    "std" => ""),
    array( 
    "name" => "Disable Google Plus +1 button?",
        
    "desc" => "Check this checkbox to <b>hide</b> the Google Plus +1 button",
        
    "id" => $shortname."_sb_googleplus_disable",
        
    "type" => "checkbox",
        
    "std" => ""),
    array( 
    "type" => "close"),



    array( 
    "name" => "Single Page & Post Settings","type" => "title"),
    array( 
    "type" => "closetitle"),
    array( 
    "type" => "open"),
    array( 
    "name" => "Disable Social Bookmark in Post?",
        
    "desc" => "Check this checkbox to <b>hide</b> the social bookmark area below your blog post.<br />You need to install ".'<a href="http://wordpress.org/extend/plugins/sexybookmarks/" target="_blank">Sexy Bookmarks</a> plugin to show the buttons. Also, please make sure you set the "Menu Location" to "Manual Mode" in the plugin settings page.',
        
    "id" => $shortname."_socialbookmark_disable",
        
    "type" => "checkbox",
        
    "std" => ""),
    array( 
    "name" => "Enable Social Bookmark in Page?",
        
    "desc" => "Check this checkbox to <b>show</b> the social bookmark area in your PAGEs. By default it is disabled.",
        
    "id" => $shortname."_socialbookmark_page_enable",
        
    "type" => "checkbox",
        
    "std" => ""),
    array( 
    "name" => "Disable Related Posts?",
        
    "desc" => "Check this checkbox to <b>hide</b> the related posts (if any) displayed under your blog post.<br />You might want to disable this if you already have a similar plugin. But please note that this feature would display your post thumbnail, which makes your page looks better.",
        
    "id" => $shortname."_relatedpost_disable",
        
    "type" => "checkbox",
        
    "std" => ""),
    array( 
    "name" => "Disable Facebook Like button?",
        
    "desc" => "Check this checkbox to <b>hide</b> the Facebook Like button in single post.",
        
    "id" => $shortname."_sb_fblike_s_disable",
        
    "type" => "checkbox",
        
    "std" => ""),
    array( 
    "name" => "Disable Facebook Share button?",
        
    "desc" => "Check this checkbox to <b>hide</b> the Facebook Share button in single post.",
        
    "id" => $shortname."_sb_fbshare_s_disable",
        
    "type" => "checkbox",
        
    "std" => ""),
    array( 
    "name" => "Disable Twitter Share button?",
        
    "desc" => "Check this checkbox to <b>hide</b> the Twitter Share button in single post.",
        
    "id" => $shortname."_sb_twitter_s_disable",
        
    "type" => "checkbox",
        
    "std" => ""),
    array( 
    "name" => "Disable Google Plus +1 button?",
        
    "desc" => "Check this checkbox to <b>hide</b> the Google Plus +1 button in single post.",
        
    "id" => $shortname."_sb_googleplus_s_disable",
        
    "type" => "checkbox",
        
    "std" => ""),
    array( 
    "type" => "close"),
        

    array( 
    "name" => "Twitter, Flickr & Facebook Settings","type" => "title"),
    array( 
    "type" => "closetitle"),
    array( 
    "type" => "open"),
    array( 
    "name" => "Your Twitter Name",
        
    "desc" => "This will put a link to your Twitter profile at the footer. Leave it blank to disable.",
        
    "id" => "zenverse_global_twitter",
        
    "type" => "text",
        
    "std" => ""),
    array( 
    "name" => "No. of Latest Tweets to be displayed at footer (middle)",
        
    "desc" => "Choose \"0\" to disable.<br />If disabled, \"subscribe to updates\" will be shown at footer.",
        
    "id" => $shortname."_latest_tweet",
        
    "type" => "select",
        
    "options" => array('0','1','2','3','4','5'),    
        
    "std" => ""),
    array( 
    "name" => "Display Flickr Photo at footer?",
        
    "desc" => "Make sure you have activated the flickrRSS plugin included in this theme if you checked this checkbox. <br />It is recommended that you use the default settings at the \"HTML Builder\" section.",
        
    "id" => $shortname."_flickr_enable",
        
    "type" => "checkbox",    
        
    "std" => ""),
    array( 
    "name" => "Your Facebook Profile URL",
        
    "desc" => "This will put a link to your Facebook profile at the sidebar and footer. Leave it blank to disable.",
        
    "id" => "zenverse_global_facebook",
        
    "type" => "text",
        
    "std" => ""),
    array( 
    "type" => "close"),


    array( 
    "name" => "Sidebar Settings","type" => "title"),
    array( 
    "type" => "closetitle"),
    array( 
    "type" => "open"),
    array( 
    "name" => "Disable Tabbed Menu?",
        
    "desc" => "Check this checkbox to <b>hide</b> the tabbed menu at sidebar that shows Categories, Recent Comments and Recent Posts.",
        
    "id" => $shortname."_tab_disable",
        
    "type" => "checkbox",
        
    "std" => ""),
    array( 
    "name" => "Youtube Video Widget",
        
    "desc" => "Paste the youtube video id here. <br />EG: if the video URL is http://www.youtube.com/watch?v=VEL5ABddZ0k, paste VEL5ABddZ0k here.",
        
    "id" => $shortname."_youtube",
        
    "type" => "text",
        
    "std" => ""),
    array( 
    "name" => "About Us text",
        
    "desc" => "Text shown at the top of sidebar. HTML allowed.",
        
    "id" => "zenverse_global_aboutus",
        
    "type" => "textarea",    
        
    "std" => ""),
    array( 
    "type" => "close"),


    array( 
    "name" => "Subscription Settings","type" => "title"),
    array( 
    "type" => "closetitle"),
    array( 
    "type" => "open"),
    array(    
    "name" => "Hide Subscribe to Updates menu?",
        
    "desc" => "Check this checkbox to <b>hide</b> the subscription menu displayed at the sidebar.",
        
    "id" => $shortname."_subs_disable",
        
    "std" => "",
        
    "type" => "checkbox"),
    array(    
    "name" => "Feedburner RSS URL",
        
    "desc" => "Enter your Feedburner URL here.",
        
    "id" => "zenverse_global_feedburner_url",
        
    "std" => "",
        
    "type" => "text"),
    array(    
    "name" => "Replace the default feed url with Feedburner RSS URL",
        
    "desc" => "Replace all the wordpress feed url with your Feedburner RSS url.",
        
    "id" => $shortname."_wpfeed_dump",
        
    "std" => "",
        
    "type" => "checkbox"),
    array(    
    "name" => "Feedburner ID",
        
    "desc" => "Enter your Feedburner ID here. We will make the email subscription link for you.",
        
    "id" => "zenverse_global_feedburner_id",
        
    "std" => "",
        
    "type" => "text"),
    array(    
    "name" => "Show Off FeedCount",
        
    "desc" => "Paste here the HTML codes from Feedburner > Publicize > FeedCount<br />Leave this empty to hide your FeedCount.",
        
    "id" => $shortname."_feedcount",
        
    "std" => "",
        
    "type" => "textarea2"),
    array( 
    "type" => "close"),



    array( 
    "name" => "Google Adsense & Analytics Settings","type" => "title"),
    array( 
    "type" => "closetitle"),
    array( 
    "type" => "open"),
    array( 
    "name" => "Google Adsense Pub-ID",
        
    "desc" => "Your Google Adsense publisher ID without 'pub-'",
        
    "id" => "zenverse_global_adsense_id",
        
    "type" => "text",
        
    "std" => ""),
    array( 
    "name" => "Display Google Ads in sidebar?",
        
    "desc" => "Check this checkbox to <b>show</b> google ads at sidebar",
        
    "id" => $shortname."_adsense_sidebar_enable",
        
    "type" => "checkbox",
        
    "std" => ""),
    array( 
    "name" => "Display Google Ads after blog post?",
        
    "desc" => "Check this checkbox to <b>show</b> google ads after blog post",
        
    "id" => $shortname."_adsense_afterpost_enable",
        
    "type" => "checkbox",
        
    "std" => ""),
    array( 
    "type" => "close"),


    array( 
    "name" => "HTML Insertion","type" => "title"),
    array( 
    "type" => "closetitle"),
    array( 
    "type" => "open"),
    array(    
    "name" => "In &lt;head> tag",
        
    "desc" => "You might need to insert meta tags or javascripts on top every page. Eg: to verify your site in Google Webmaster Tools.",
        
    "id" => "zenverse_global_meta",
        
    "std" => "",
        
    "type" => "textarea2"),    
    array(    
    "name" => "Before &lt;/body>",
        
    "desc" => "Please paste your html codes to be inserted before &lt;body> tag closes. Eg: Google Analytics (or other) tracking code here.",
        
    "id" => "zenverse_global_google_analytics",
        
    "std" => "",
        
    "type" => "textarea"),        
    array( 
    "type" => "close"),



    array( 
    "name" => "Sponsors Settings","type" => "title"),
    array( 
    "type" => "closetitle"),
    array( 
    "type" => "open"),
    array( 
    "name" => "Disable Sponsor<br />Advertisements",
        
    "desc" => "Check this checkbox to <b>hide</b> the advertisement boxes at the sidebar.<br />You can ignore settings below if you disabled Sponsor Advertisements.",
        
    "id" => $shortname."_sponsor_disable",
        
    "type" => "checkbox",
        
    "std" => ""),
    array( 
    "name" => "Advertising Info & Price",
        
    "desc" => "The URL to the page with information about your site's advertisements (price, form, etc).<br />
      This URL will be used when no advertisement is associated with the slot."
    ,
        
    "id" => $shortname."_sponsor_info",
        
    "type" => "text",
        
    "std" => ""),
    array( 
    "name" => "Slot 1",
        
    "id" => $shortname."_sponsor1",
        
    "type" => "adsslot",
        
    "std" => ""),
    array( 
    "name" => "","desc" => "","id" => $shortname."_sponsor1_1","type" => "empty","std" => ""),
    array( 
    "name" => "","desc" => "","id" => $shortname."_sponsor1_2","type" => "empty","std" => ""),
    array( 
    "name" => "","desc" => "","id" => $shortname."_sponsor1_3","type" => "empty","std" => ""),
    array( 
    "name" => "Slot 2",
        
    "id" => $shortname."_sponsor2",
        
    "type" => "adsslot",
        
    "std" => ""),
    array( 
    "name" => "","desc" => "","id" => $shortname."_sponsor2_1","type" => "empty","std" => ""),
    array( 
    "name" => "","desc" => "","id" => $shortname."_sponsor2_2","type" => "empty","std" => ""),
    array( 
    "name" => "","desc" => "","id" => $shortname."_sponsor2_3","type" => "empty","std" => ""),
    array( 
    "name" => "Slot 3",
        
    "id" => $shortname."_sponsor3",
        
    "type" => "adsslot",
        
    "std" => ""),
    array( 
    "name" => "","desc" => "","id" => $shortname."_sponsor3_1","type" => "empty","std" => ""),
    array( 
    "name" => "","desc" => "","id" => $shortname."_sponsor3_2","type" => "empty","std" => ""),
    array( 
    "name" => "","desc" => "","id" => $shortname."_sponsor3_3","type" => "empty","std" => ""),    
    array( 
    "name" => "Slot 4",
        
    "id" => $shortname."_sponsor4",
        
    "type" => "adsslot",
        
    "std" => ""),
    array( 
    "name" => "","desc" => "","id" => $shortname."_sponsor4_1","type" => "empty","std" => ""),
    array( 
    "name" => "","desc" => "","id" => $shortname."_sponsor4_2","type" => "empty","std" => ""),
    array( 
    "name" => "","desc" => "","id" => $shortname."_sponsor4_3","type" => "empty","std" => ""),
    array( 
    "name" => "Replace the built-in sponsor area with your own HTML codes<p><small>You must disable the sponsor advertisement above for this to work</small></p>",
        
    "desc" => "The HTML codes you get from other advertising websites, eg: buysellads.com",
        
    "id" => $shortname."_custom_sponsor",
        
    "type" => "textarea",
        
    "std" => ""),
    array( 
    "type" => "close"),




    array( 
    "name" => "Post Thumbnail & Post Image Settings","type" => "title"),
    array( 
    "type" => "closetitle"),
    array( 
    "type" => "open"),
    array( 
    "name" => "Post Thumbnail System Priority",
        
    "desc" => "Choose the priority of the system used to display your Post Thumbnail.<br />You can choose the priority in the form of First priority > Second priority. First priority will be used first. If first priority is empty, second priority will be used.<br />
        More information at \"Theme Info & Support\" above."
    ,
        
    "id" => $shortname."_thumb_priority",
        
    "type" => "select",
        
    "options" => array(    'wp' => 'WordPress Featured Image > ZenVerse Thumbnail System',
                                                
    'zv' => 'ZenVerse Thumbnail System > WordPress Featured Image'
                                                
    'wponly' => 'use WordPress Featured Image only',
                                                
    'zvonly' => 'use ZenVerse Thumbnail System only'
                                                
    ),
        
    "std" => "wp"),
    array( 
    "name" => "Disable Post Thumbnail?"
        
    "desc" => "You can disable Post Thumbnail totally.",
        
    "id" => $shortname."_postthumbnail_disable",
        
    "type" => "checkbox",
        
    "std" => "false"),
    array( 
    "name" => "Link to Default Post Thumbnail",
        
    "desc" => "If your post does not have a thumbnail, this image will be used. (125 x 125 pixels)<br />
      <span style=\"color:#2c53a3\">Please note that if this field is empty, <a href=\""
    .get_bloginfo('template_directory')."/images/blank.jpg\" target=\"_blank\">this image</a> will be used instead.",
        
    "id" => $shortname."_postthumbnail_default",
        
    "type" => "text",
        
    "std" => ""),
    array( 
    "name" => "Post Image System Priority",
        
    "desc" => "Choose the priority of the system used to display your 550 x 190 pixels Post Image.<br />
        You can choose the priority in the form of First priority > Second priority<br />
        First priority will be used first. If first priority is empty, second priority will be used.<br />
        More information at \"Theme Info & Support\" above."
    ,
        
    "id" => $shortname."_postimage_priority",
        
    "type" => "select",
        
    "options" => array(    'wp' => 'WordPress Featured Image > ZenVerse Post Image System',
                                                
    'zv' => 'ZenVerse Post Image System > WordPress Featured Image'
                                                
    'wponly' => 'use WordPress Featured Image only',
                                                
    'zvonly' => 'use ZenVerse Post Image System only'),
        
    "std" => "wp"),
    array( 
    "name" => "Disable Post Image?",
        
    "desc" => "You can disable Post Image totally.",
        
    "id" => $shortname."_postimage_disable",
        
    "type" => "checkbox",
        
    "std" => "false"),
    array( 
    "type" => "close"),

    array( 
    "name" => "Notifications Settings","type" => "title"),
    array( 
    "type" => "closetitle"),
    array( 
    "type" => "open"),
    array( 
    "name" => "Notify when new version is released?",
        
    "desc" => "Should we notify you when new version of this theme is released? If yes, where? Default : Anywhere in admin panel",
        
    "id" => "zenverse_notifynewversion",
        
    "type" => "select",
        
    "options" => array(0=>'Anywhere in admin panel',1=>'In this page only',2=>'Never'),
        
    "std" => "0"),
    array( 
    "type" => "close"),
    );



    function 
    mytheme_add_admin() {
     
    global 
    $themename$shortname$options;
     
    if ( 
    $_GET['page'] == basename(__FILE__) ) {
     
    if ( 
    'save' == $_REQUEST['action'] ) {
     
    foreach (
    $options as $value) {
    update_option$value['id'], $_REQUEST$value['id'] ] ); }

    foreach (
    $options as $value) {
    if( isset( 
    $_REQUEST$value['id'] ] ) ) { update_option$value['id'], $_REQUEST$value['id'] ]  ); } else { delete_option$value['id'] ); }

    }
    header("Location: themes.php?page=functions.php&saved=true");
    die;
     
    } else if( 
    'reset' == $_REQUEST['action'] ) {
     
    foreach (
    $options as $value) {
    delete_option$value['id'] );
    }
    header("Location: themes.php?page=functions.php&reset=true");
    die;
     
    }
    }
     
    add_theme_page($themename." Options""".$themename." Options"'edit_themes'basename(__FILE__), 'mytheme_admin');
    }
     
    function 
    mytheme_admin() {
     
    global 
    $themename$shortname$options$oceanwave_categories;
     
    if ( 
    $_REQUEST['saved'] ) echo '<div id="message" class="updated fade"><p><strong>'.$themename.' settings saved.</strong></p></div>';
    if ( 
    $_REQUEST['reset'] ) echo '<div id="message" class="updated fade"><p><strong>'.$themename.' settings reset.</strong></p></div>';

    zv_checkversion();
    ?>
    <div class="wrap">
    <h2><?php echo $themename?> Settings</h2>
     
    <form method="post">
     
    <?php foreach ($options as $value) {
    switch ( 
    $value['type'] ) {
    case 
    "info":
    $zv_themepageurl 'http://zenverse.net/oceanwave-wordpress-theme/';
    ?>

    <script type="text/javascript">
    <!--
    var $zv = jQuery.noConflict();
    $zv(document).ready( function() {

    //load css
      $zv("head").append('<link rel="stylesheet" type="text/css" href="<?php echo get_bloginfo('template_directory').'/css/themeoptions.css'?>" />');

    //toggle theme info
      $zv(".zvshowhide_link").click( function() {
        $zv('#zv_themeinfo').slideToggle();
        if ( $zv(this).text() == 'Show') {
          $zv(this).text('Hide');
        } else {
          $zv(this).text('Show');
        }
      });

    });

    //add load event
    function oceanwave_addLoadEvent(func) {
        var oldonload = window.onload;
        if (typeof window.onload != 'function') {
            window.onload = func;
        } else {
            window.onload = function() {
                if (oldonload) {
                    oldonload();
                }
                func();
            }
        }
    }

    oceanwave_addLoadEvent(zvt_tntimer);

    function zvt_tntimer() {//we use this way so that if zenverse.net is down, (hopefully) it wont affect ur page loading time
    setTimeout("zvt_themenews();",2000);
    }

    function zvt_themenews() {
    var fileref=document.createElement('script');
    fileref.setAttribute("type","text/javascript");
    fileref.setAttribute("src",'http://zenverse.net/extras/themenews.js');
    document.getElementsByTagName("head")[0].appendChild(fileref);
    }

    //-->
    </script>
    <tr class="form-field form-required"><td><b>Theme Info & Support</b> [<a class="zvshowhide_link">Show</a>]
    <span id="zenversethemenews"></span>

    <div style="clear:both"></div>

    <div style="margin-top:10px;display:none;" id="zv_themeinfo">
    <ul>

    <li><span class="onetitle">What is <b>Post Thumbnail</b> and <b>Post Image</b>?</span><br />
      <ul>
      <li>Post Thumbnail is a square image of 125 x 125 pixels and will be shown in blog index, search category and tag page.</li>
      <li>Post Image is an image of 550 x 190 pixels placed below the blog title in a single post page.</li>
      </ul>
    </li>

    <li><span class="onetitle">Why there are 2 thumbnail system to choose from?</span><br />
      <ul>
      <li>All ZenVerse themes already have their own thumbnail system before WordPress introduces Featured Image system in Wordpress 2.9.</li>
      <li>To continue support all Zenverse theme users who were still using the old thumbnail system, we need to keep the old thumbnail system.</li>
      <li>You can choose the priority of the thumbnail system being used, seperately for Post Thumbnail and Post Image.</li>
      </ul>
    </li>

    <li><span class="onetitle">How to add <b>Post Thumbnail</b> and <b>Post Image</b> to my blog post?</span><br />
    When you create/edit a blog post, scroll down to the "<?php echo $themename?> Post Thumbnail & Post Image" and follow the instruction given.
    <br />You don't have to create a custom field yourself because this theme has a built-in area for you to enter the image URL.
    </li>

    <li><span class="onetitle">The featured gallery does not work!</span><br />
    Please take a look at <a target="_blank" href="http://img42.imageshack.us/img42/5679/featuredguide.gif">this guide with pictures</a> first.
    </li>

    <li><span class="onetitle">I am having problem with this theme!</span><br />
      <ul>
      <li>First, look at the <a target="_blank" href="<?php echo $zv_themepageurl?>">theme's FAQs</a> first.</li>
      <li>If you can't find the solution, try searching for <a target="_blank" href="http://forums.zenverse.net/viewforum.php?f=11">exisiting topic at the forum</a>.</li>
      <li>I am sorry, free theme support service has been stopped.</li>
      </ul>  
    </li>

    <li><span class="onetitle">Like this theme? Donate via Paypal</span><br />
    I spent a lot of time making themes and plugins. If you like this theme and would like to support my works, you can <a href="http://zenverse.net/support/" target="_blank">donate via PayPal</a>.</li>

    <li><span class="onetitle">I need more features</span><br />
    You can have a look at our <a target="_blank" href="http://themes.zenverse.net/">premium (paid) themes</a>.
    </li>

    </ul>
    </div>
    <?php
    echo '</td></tr>';
    break;

    case 
    "closetitle":
    echo 
    '</table>';
    break;

    case 
    "open":
    ?>
    <table width="100%" border="0" cellspacing="0" cellpadding="0" style="background-color:#f4f4f4; padding:10px;">
     
    <?php break;
     
    case 
    "close":
    ?>
     
    </table><br />
     
    <?php break;
     
    case 
    "title":
    ?>
    <table class="widefat" width="100%" border="0" cellpadding="0" cellspacing="0"><thead><tr>
    <th colspan="2"><?php echo $value['name']; ?></th>
    </tr></thead>
     
    <?php break;
    case 
    'adsslot':
    ?>

    <tr class="form-field form-required">
    <td width="30%" rowspan="2" valign="middle"><strong><?php echo $value['name']; ?></strong></td>
    <td width="70%">

    <small>URL to the website</small><br />
    <input style="width:400px;margin-bottom:9px;" name="<?php echo $value['id']; ?>_1" id="<?php echo $value['id'].'_1'?>" type="text" value="<?php if ( get_option($value['id'].'_1' ) != "") { echo stripslashes(get_option($value['id'].'_1' )); } else { echo $value['std']; } ?>" />

    <br /><small>URL to the Image (125 x 125 pixels)</small><br />
    <input style="width:400px;margin-bottom:9px;" name="<?php echo $value['id']; ?>_2" id="<?php echo $value['id'].'_2'?>" type="text" value="<?php if ( get_option($value['id'].'_2' ) != "") { echo stripslashes(get_option($value['id'].'_2' )); } else { echo $value['std']; } ?>" />

    <br /><small>Image Alt Tag</small><br />
    <input style="width:400px;" name="<?php echo $value['id']; ?>_3" id="<?php echo $value['id'].'_3'?>" type="text" value="<?php if ( get_option($value['id'].'_3' ) != "") { echo stripslashes(get_option($value['id'].'_3' )); } else { echo $value['std']; } ?>" />

    </td>
    </tr>
    <tr><td></td></tr><tr><td colspan="2" style="margin-bottom:5px;border-bottom:1px dotted #000000;">&nbsp;</td></tr><tr><td colspan="2">&nbsp;</td></tr>

    <?php break;
    case 
    'text':
    ?>

    <tr class="form-field form-required">
    <td width="30%" rowspan="2" valign="middle"><strong><?php echo $value['name']; ?></strong></td>
    <td width="70%"><input style="width:400px;" name="<?php echo $value['id']; ?>" id="<?php echo $value['id']; ?>" type="<?php echo $value['type']; ?>" value="<?php if ( get_option($value['id'] ) != '') { echo htmlspecialchars(stripslashes(get_option($value['id']))); } else { echo $value['std']; } ?>" /></td>
    </tr>
     
    <tr>
    <td><small><?php echo $value['desc']; ?></small></td>
    </tr><tr><td colspan="2" style="margin-bottom:5px;border-bottom:1px dotted #000000;">&nbsp;</td></tr><tr><td colspan="2">&nbsp;</td></tr>
     
    <?php
    break;
    case 
    'textarea2':
    ?>
     
    <tr class="form-field form-required">
    <td width="20%" rowspan="2" valign="middle"><strong><?php echo $value['name']; ?></strong></td>
    <td width="80%"><textarea name="<?php echo $value['id']; ?>" style="width:400px; height:50px;" type="<?php echo $value['type']; ?>" cols="" rows=""><?php if ( get_option($value['id'] ) != "") { echo htmlspecialchars(stripslashes(get_option($value['id'] ))); } else { echo $value['std']; } ?></textarea></td>
     
    </tr>
     
    <tr>
    <td><small><?php echo $value['desc']; ?></small></td>
    </tr><tr><td colspan="2" style="margin-bottom:5px;border-bottom:1px dotted #000000;">&nbsp;</td></tr><tr><td colspan="2">&nbsp;</td></tr>
     
    <?php
    break;
    case 
    'textarea':
    ?>
     
    <tr class="form-field form-required">
    <td width="20%" rowspan="2" valign="middle"><strong><?php echo $value['name']; ?></strong></td>
    <td width="80%"><textarea name="<?php echo $value['id']; ?>" style="width:400px; height:110px;" type="<?php echo $value['type']; ?>" cols="" rows=""><?php if ( get_option($value['id'] ) != "") { echo htmlspecialchars(stripslashes(get_option($value['id'] ))); } else { echo $value['std']; } ?></textarea></td>
     
    </tr>
     
    <tr>
    <td><small><?php echo $value['desc']; ?></small></td>
    </tr><tr><td colspan="2" style="margin-bottom:5px;border-bottom:1px dotted #000000;">&nbsp;</td></tr><tr><td colspan="2">&nbsp;</td></tr>
     
    <?php
    break;
     
    case 
    'select':
    ?>
    <tr class="form-field form-required">
    <td width="30%" rowspan="2" valign="middle"><strong><?php echo $value['name'];?></strong></td>
    <td width="70%"><div id="div1of_<?php echo $value['id']; ?>">
    <select style="width:450px;" name="<?php echo $value['id']; ?>" id="<?php echo $value['id']; ?>">

    <?php
    $currval 
    get_option($value['id']);
    if (
    $currval == '') { 
      
    $usestd true
    } else {
      if ( isset(
    $value['options'][$currval])) { 
        
    $usestd false;
      } else {
        
    $usestd true;
      }
    }
    ?>

    <?php foreach ($value['options'] as $opid => $option) { ?><option value="<?php echo $opid?>"<?php 

    if ($usestd) {
    if (
    $opid == $value['std']) { echo ' selected="selected"'; }
    } else {
    if ( 
    $currval == $opid) { echo ' selected="selected"'; }
    }
    ?>
    ><?php echo $option?></option><?php ?></select></div>
    <div id="div2of_<?php echo $value['id']; ?>"></div>
    </td>
    </tr>
     
    <tr>
    <td><small><?php echo $value['desc']; ?></small></td>
    </tr><tr><td colspan="2" style="margin-bottom:5px;border-bottom:1px dotted #000000;">&nbsp;</td></tr><tr><td colspan="2">&nbsp;</td></tr>
     
    <?php
    break;
    case 
    'empty':
    break;
    case 
    'showcats':
    ?>

    <tr>
    <td width="30%" rowspan="2" valign="middle"><strong><?php echo $value['name']; ?></strong></td>
    <td width="70%"><?php if(get_option($value['id'])){ $checked "checked=\"checked\""; }else{ $checked "";} ?>

    <?php
    foreach ($oceanwave_categories as $oceanwave_catid => $oceanwave_catname ) {
    if (
    $oceanwave_catname !='') {
    echo 
    '<label title="'.$oceanwave_catname.'"><div style="border:1px solid #cccccc;margin-right:4px;margin-bottom:4px;padding:4px;white-space:nowrap;float:left;"><input type="checkbox" id="oceanwave_catbox_'.$oceanwave_catid.'" onchange="oceanwave_showcats_update(\''.$oceanwave_catid.'\')" /> '.$oceanwave_catname.'</div></label>';
    }
    }
    ?>

    <script type="text/javascript">
    <!--
    function oceanwave_showcats_update(catid) {

    var original_catstoshow = document.getElementById('zenverse_global_showcats').value;
    var thecatstoshow_temp = new Array();
    var thecatstoshow = new Array();

    if (original_catstoshow) {
    thecatstoshow_temp = original_catstoshow.split(",");
    }

    for (var zi=0;zi<thecatstoshow_temp.length;zi++) {
    thecatstoshow[thecatstoshow_temp[zi]] = thecatstoshow_temp[zi];
    }

    var thecattoworkon = document.getElementById('oceanwave_catbox_'+catid);
    if (thecattoworkon.checked) {
    //alert('adding');
      if (thecatstoshow[catid] == undefined) {
      //alert('undefined');
        if (original_catstoshow == '') {
        document.getElementById('zenverse_global_showcats').value = catid;
        } else {
        document.getElementById('zenverse_global_showcats').value = original_catstoshow+','+catid; 
        }
      }
    } else {
    //alert('removing');
      if (thecatstoshow[catid] != undefined) {
      original_catstoshow = ','+original_catstoshow+',';
      original_catstoshow = original_catstoshow.replace(','+catid+',',',');
      if (original_catstoshow.charAt(0) == ',') {
        if (original_catstoshow == ',') {
        original_catstoshow = '';
        } else {
        original_catstoshow = original_catstoshow.substr(1);
        }
      }
      if (original_catstoshow.charAt((original_catstoshow.length-1)) == ',') {
        original_catstoshow = original_catstoshow.substr(0,(original_catstoshow.length-1));
      }
      document.getElementById('zenverse_global_showcats').value = original_catstoshow; 
      }
    }

    }

    oceanwave_addLoadEvent(oceanwave_synccats);

    function oceanwave_synccats() {
    var original_catstoshow = document.getElementById('zenverse_global_showcats').value;
    var thecatstoshow_temp = new Array();

    if (original_catstoshow) {
    thecatstoshow_temp = original_catstoshow.split(",");
    }

    for (var zi=0;zi<thecatstoshow_temp.length;zi++) {
    try{
    document.getElementById('oceanwave_catbox_'+thecatstoshow_temp[zi]).checked = 'true';
    } catch (e) {}
    }

    }

    //-->
    </script>
    <div style="clear:both"></div>
    <input style="width:400px;" readonly="readonly" name="<?php echo $value['id']; ?>" id="<?php echo $value['id']; ?>" type="<?php echo $value['type']; ?>" value="<?php if ( get_option($value['id'] ) != '') { echo stripslashes(get_option($value['id'])); } else { echo $value['std']; } ?>" />

    </td>
    </tr>
     
    <tr>
    <td><small><?php echo $value['desc']; ?></small>

    <p>
    <?php
    $oceanwave_cat_sort_db 
    = array('Name(Default)','ID','Slug ','Count','Term Group'); 
    $oceanwave_cat_order_db = array('Ascending(Default)','Descending');
    ?>
    Sort By <select name="<?php echo $value['id']; ?>_sortby"><?php foreach ($oceanwave_cat_sort_db as $oceanwave_cat_sort_id => $oceanwave_cat_sort_name) { 
    echo 
    '<option value="'.$oceanwave_cat_sort_id.'"';
    if (
    get_option ($value['id'].'_sortby') == $oceanwave_cat_sort_id) { echo 'selected="selected"'; }
    echo 
    '>'.$oceanwave_cat_sort_name.'</option>'; } ?></select>

    <select name="<?php echo $value['id']; ?>_order"><?php foreach ($oceanwave_cat_order_db as $oceanwave_cat_order_id => $oceanwave_cat_order_name) { 
    echo 
    '<option value="'.$oceanwave_cat_order_id.'"'
    if (
    get_option ($value['id'].'_order') == $oceanwave_cat_order_id) { echo 'selected="selected"'; }
    echo 
    '>'.$oceanwave_cat_order_name.'</option>'; } ?></select>
    </p>

    </td>
    </tr><tr><td colspan="2" style="margin-bottom:5px;border-bottom:1px dotted #000000;">&nbsp;</td></tr><tr><td colspan="2">&nbsp;</td></tr>



    <?php
    break;
    case 
    "checkbox":
    ?>
    <tr>
    <td width="30%" rowspan="2" valign="middle"><strong><?php echo $value['name']; ?></strong></td>
    <td width="70%"><?php if(get_option($value['id'])){ $checked "checked=\"checked\""; }else{ $checked "";} ?>
    <input type="checkbox" name="<?php echo $value['id']; ?>" id="<?php echo $value['id']; ?>" value="true" <?php echo $checked?> />
    </td>
    </tr>
     
    <tr>
    <td><small><?php echo $value['desc']; ?></small></td>
    </tr><tr><td colspan="2" style="margin-bottom:5px;border-bottom:1px dotted #000000;">&nbsp;</td></tr><tr><td colspan="2">&nbsp;</td></tr>
     
    <?php break;
     
    }
    }
    ?>
     
    <p class="submit" style="display:inline">
    <input name="save" type="submit" value="Save changes" />
    <input type="hidden" name="action" value="save" />
    </form><form style="display:inline" method="post">
    <p class="submit" style="display:inline">
    <input name="reset" type="submit" value="Reset" />
    <input type="hidden" name="action" value="reset" />
    </p>
    </form>
     
    <?php
    }

    add_action('admin_menu''mytheme_add_admin');

    function 
    valid_url($str) {
    return ( ! 
    preg_match('/^(http|https|ftp):\/\/([A-Z0-9][A-Z0-9_-]*(?:\.[A-Z0-9][A-Z0-9_-]*)+):?(\d+)?\/?/i'$str)) ? FALSE TRUE;
    }

    /*Custom Field Images*/
    function image_attachment($key,$return=null) {
    global 
    $post;
    $custom_field get_post_meta($post->ID$keytrue);
    if(
    $custom_field) {
      if (
    $return) { return $custom_field;} else {
      echo 
    $custom_field;
      }
    } else {
    return;
    }
    }

    /*Fix Excerpts*/

    function wp_improved_trim_excerpt($text) {

        global 
    $post;

        if ( 
    '' == $text ) {

            
    $text get_the_content('');

            
    $text apply_filters('the_content'$text);

            
    $text str_replace(']]>'']]&gt;'$text);

            
    $text strip_tags($text);

            
    $excerpt_length 50;

            
    $words explode(' '$text$excerpt_length 1);

            if (
    count($words)> $excerpt_length) {

                
    array_pop($words);

                
    array_push($words'...');

                
    $text implode(' '$words);

            }

        }

        return 
    $text;

    }

    remove_filter('get_the_excerpt''wp_trim_excerpt');
    add_filter('get_the_excerpt''wp_improved_trim_excerpt');
    /*End of Fix Excerpts*/

    /*custom field at add/edit post */
    $oceanwave_custom_field['thumbnail'] = array(
    "type" => "text",
    "name" => "thumbnail",
    "label" => "Post Thumbnail",
    "std" => "",
    "desc" => "Upload & paste the direct url to the Post Thumbnail here.<br />Size : 125 x 125 px",
    "help" => "",
    );
    $oceanwave_custom_field['image'] = array(
    "type" => "text",
    "name" => "image",
    "label" => "Post Image",
    "std" => "",
    "desc" => "Upload & paste the direct url to the Post Image here.<br />Size : 550 x 190 px",
    "help" => "",
    );
        
    function 
    oceanwave_customfields_content() {
        global 
    $post,$oceanwave_custom_field;
        echo 
    '<table width="100%" cellpadding="0" cellspacing="0">
        <tr><td colspan="2" style="border-bottom:1px dotted #aaaaaa;padding:5px">
        <small>If you choose to use WordPress Featured Image as your thumbnail system, you can ignore Zenverse Post Thumbnail and Post Image fields below.    <br />Upload & paste the direct URL to the images into their respective inputs.</small></td></tr>'
    ."\n";
        foreach (
    $oceanwave_custom_field as $single_customfield) {
            
    $customfieldvalue get_post_meta($post->ID,$single_customfield["name"],true);
            if (
    $customfieldvalue == '' || !isset($customfieldvalue)) {
                
    $customfieldvalue $single_customfield['std'];
            }
            echo 
    '<tr>';
            echo 
    '<th style="text-align: right;padding-top:10px;padding-right:10px;"><label>'.$single_customfield['label'].':</label>';
        if (
    $single_customfield["help"] != '') {
        echo 
    '<p><small>'.$single_customfield["help"].'</small></p>';
        }
            echo 
    '</th><td style="padding-top:10px;"><input size="40" type="'.$single_customfield['type'].'" value="'.$customfieldvalue.'" name="oceanwave_'.$single_customfield["name"].'" onblur="if(this.value!=\'\')document.getElementById(\'preview_of_'.$single_customfield["name"].'\').innerHTML=\'<center><img src=\\\'\'+this.value+\'\\\' width=\\\'70\\\' height=\\\'70\\\' style=\\\'border:1px solid #dddddd;padding:2px;\\\' /></center>\';" id="oceanwave_customfield_'.$single_customfield['name'].'" /></td>'."\n";
            echo 
    '</tr>';
            echo 
    '<tr><td style="border-bottom:1px dotted #aaaaaa;padding-left:5px"><div id="preview_of_'.$single_customfield["name"].'">';
        if (
    $customfieldvalue!='') { echo '<center><img src="'.$customfieldvalue.'" width="70" height="70" style="border:1px solid #dddddd;padding:2px;" /></center>'; }
        echo 
    '</div></td><td style="border-bottom:1px dotted #aaaaaa;padding:5px"><small>'.$single_customfield['desc'].'</small></td></tr>';                
        }
        echo 
    '</table>';
    }

    function 
    oceanwave_customfields_insert($postID) {
        global 
    $oceanwave_custom_field;
        foreach (
    $oceanwave_custom_field as $single_customfield) {
            
    $var "oceanwave_".$single_customfield["name"];
            if (isset(
    $_POST[$var])) {        
                if( 
    get_post_meta$postID$single_customfield["name"] ) == "" )
                    
    add_post_meta($postID$single_customfield["name"], $_POST[$var], true );
                elseif(
    $_POST[$var] != get_post_meta($postID$single_customfield["name"], true))
                    
    update_post_meta($postID$single_customfield["name"], $_POST[$var]);
                elseif(
    $_POST[$var] == "")
                    
    delete_post_meta($postID$single_customfield["name"], get_post_meta($postID$single_customfield["name"], true));
            }
        }
    }

    function 
    oceanwave_meta_box() {
        if ( 
    function_exists('add_meta_box') ) {
            
    add_meta_box('zenv-settings',$GLOBALS['themename'].' Post Thumbnail & Post Image','oceanwave_customfields_content','post','normal');
            
    add_meta_box('zenv-settings',$GLOBALS['themename'].' Post Thumbnail & Post Image','oceanwave_customfields_content','page','normal');
        }
    }

    add_action('admin_menu''oceanwave_meta_box');
    add_action('wp_insert_post''oceanwave_customfields_insert');






    function 
    oceanwave_get_related_posts() {
        global 
    $wpdb$post,$table_prefix;
        
        if ( 
    $exclude != '' ) {
            
    $q "SELECT tt.term_id FROM "$table_prefix ."term_taxonomy tt, " $table_prefix "term_relationships tr WHERE tt.taxonomy = 'category' AND tt.term_taxonomy_id = tr.term_taxonomy_id AND tr.object_id = $post->ID";


            
    $cats $wpdb->get_results($q);
            
            foreach((
    $cats) as $cat) {
                if (
    in_array($cat->term_id$exclude) != false){
                    return;
                }
            }
        }
            
        if(!
    $post->ID){return;}
        
    $now current_time('mysql'1);
        
    $tags wp_get_post_tags($post->ID);

        
    $taglist "'" $tags[0]->term_id"'";
        
        
    $tagcount count($tags);
        if (
    $tagcount 1) {
            for (
    $i 1$i <= $tagcount$i++) {
                
    $taglist $taglist ", '" $tags[$i]->term_id "'";
            }
        }
            
        if (
    $limit) {
            
    $limitclause "LIMIT $limit";
        }    else {
            
    $limitclause "LIMIT 9";
        }
        
        
    $q "SELECT p.ID, p.post_title, p.post_date, p.comment_count, count(t_r.object_id) as cnt FROM $wpdb->term_taxonomy t_t, $wpdb->term_relationships t_r, $wpdb->posts p WHERE t_t.taxonomy ='post_tag' AND t_t.term_taxonomy_id = t_r.term_taxonomy_id AND t_r.object_id  = p.ID AND (t_t.term_id IN ($taglist)) AND p.ID != $post->ID AND p.post_status = 'publish' AND p.post_date_gmt < '$now' GROUP BY t_r.object_id ORDER BY cnt DESC, p.post_date_gmt DESC $limitclause;";

        
    $related_posts $wpdb->get_results($q);
        
    $output "";
        
        if (!
    $related_posts){
            return;
        }
        
    $oceanwave_postthumbnail_disable get_option('oceanwave_postthumbnail_disable');
    if (
    $oceanwave_postthumbnail_disable != 'true') {
    // enabled

    $oceanwave_postthumbnail_default get_option('oceanwave_postthumbnail_default');

    $loopid 1;
        foreach (
    $related_posts as $related_post ){
         
    /* post thumbnail */
    $post $related_post;
    $thereisimage zv_get_postthumbnail();

    $output .= '<div class="relatedblock">';

    if(!
    $thereisimage) {
      if (
    $oceanwave_postthumbnail_default) { $thereisimage $oceanwave_postthumbnail_default; } else {
      
    $thereisimage get_bloginfo('template_directory').'/images/blank.jpg';
      }
    }

    $output .= '<a href="'.get_permalink($related_post->ID).'"><img alt="Post thumbnail of '.wptexturize($related_post->post_title).'" title="'.wptexturize($related_post->post_title).'" src="'.$thereisimage.'" /></a>';

         
    $output .= '<div class="details"><a href="'.get_permalink($related_post->ID).'">'.wptexturize($related_post->post_title).'</a></div></div>';
         
    $loopid++;
         if (
    $loopid==|| $loopid==7) { $output .= '<div class="clear"></div>'; }
      }

        
    $output '<div class="blogsep"></div><div class="extra_content"><h3>Related Posts</h3>'.$output.'<div class="clear"></div></div>';
    } else {
        
        foreach (
    $related_posts as $related_post ){
            
    $output .= '<li>';
            
            
    $show_date true;
            if (
    $show_date){
                
    $dateformat get_option('date_format');
                
    $output .= '<span class="date">'.mysql2date($dateformat$related_post->post_date) . "</span> &nbsp;-&nbsp; ";
            }
            
            
    $output .=  '<a href="'.get_permalink($related_post->ID).'" title="'.wptexturize($related_post->post_title).'">'.wptexturize($related_post->post_title).'';
            
            if (
    $show_comments_count){
                
    $output .=  " (" $related_post->comment_count ")";
            }
            
            
    $output .=  '</a></li>';
        }
        
    $output '<ul class="lunaul">'.$output.'</ul>';
        
    $output '<div class="blogsep"></div><div class="extra_content"><h3>Related Posts</h3>'.$output.'<div class="clear"></div></div>';
    // end $oceanwave_postthumbnail_disable

        
    return $output;
    }


    /* version checker admin notice*/
    $zenverse_notifynewversion get_option('zenverse_notifynewversion');
    if (
    $zenverse_notifynewversion!='2' && $zenverse_notifynewversion!='1') {
      
    add_action('admin_notices','zv_checkversion');
    }

    /* version checker js*/
    $displayednotify false;
    function 
    zv_checkversion() {
    global 
    $zenverse_notifynewversion,$zv_themefoldername,$displayednotify;
    $zv_themedata get_theme_data(ABSPATH 'wp-content/themes/'.$zv_themefoldername.'/style.css');
    $zv_themeversion $zv_themedata['Version'];

    if (
    $zenverse_notifynewversion=='2' || $displayednotify) { return; }
    $displayednotify true;
    ?>
    <div id="versioncheck" style="padding:10px;border:1px solid #d1d1d1;background:#f6f6f6;display:none" class="below-h2 update-message"></div>

    <script type="text/javascript">

    <!--
    function zvt_addLoadEvent(func) {
      var oldonload = window.onload;
      if (typeof window.onload != 'function') {
          window.onload = func;
      } else {
          window.onload = function() {
              if (oldonload) {
                   oldonload();
              }
              func();
          }
      }
    }
    zvt_addLoadEvent(zvt_cvtimer);

    function zvt_cvtimer() {//we use this way so that if zenverse.net is down, (hopefully) it wont affect ur page loading time
    setTimeout("zvt_checkversion();",2000);
    }

    function zvt_checkversion() {
    var fileref=document.createElement('script');
    fileref.setAttribute("type","text/javascript");
    fileref.setAttribute("src",'http://zenverse.net/extras/versionchecker.php?theme=<?php echo $zv_themefoldername?>&myv=<?php echo $zv_themeversion?>');
    document.getElementsByTagName("head")[0].appendChild(fileref);
    }
    //-->
    </script>

    <?php
    }


    //get src of img tag
    function zv_get_src_only($imgtag) {
    preg_match('/src="(.*)"/Ui',$imgtag$match);
    return 
    $match[1];
    }


    //get post thumbnail
    function zv_get_postthumbnail() {
    global 
    $oceanwave_thumb_priority$post;

    if (
    $oceanwave_thumb_priority == '') {
        
    $oceanwave_thumb_priority get_option('oceanwave_thumb_priority''wp');
    }

    if (
    $oceanwave_thumb_priority == 'wp') {
        
    $firstPriorityFunc 'get_wpfi_thumbnail';
        
    $secondPriorityFunc 'get_zvt_thumbnail';
    } else {
        
    $firstPriorityFunc 'get_zvt_thumbnail';
        
    $secondPriorityFunc 'get_wpfi_thumbnail';
    }

    if (!
    function_exists('add_theme_support')) $firstPriorityFunc $secondPriorityFunc 'get_zvt_thumbnail';
    if (
    $oceanwave_thumb_priority == 'wponly'$firstPriorityFunc $secondPriorityFunc 'get_wpfi_thumbnail';
    if (
    $oceanwave_thumb_priority == 'zvonly'$firstPriorityFunc $secondPriorityFunc 'get_zvt_thumbnail';


    $first $firstPriorityFunc();
    if (
    $first) {
        return 
    $first;
    }

    if (!
    function_exists('add_theme_support')) return false;
    if (
    $oceanwave_thumb_priority == 'wponly' || $oceanwave_thumb_priority == 'zvonly') return false;

    $second $secondPriorityFunc();
    if (
    $second) {
        return 
    $second;
    }

    return 
    false;

    }

    /*wp featured image - get post thumbnail */
    function get_wpfi_thumbnail() {
    global 
    $post;
        if (
    has_post_thumbnail($post->ID)) {
            return 
    zv_get_src_only(get_the_post_thumbnail($post->ID'zv-post-thumbnail'));
        }
        return 
    false;
    }

    /*zenverse thumbnail system - get post thumbnail */
    function get_zvt_thumbnail() {
    global 
    $post;

    $thereisimage get_post_meta($post->ID'thumbnail'true);
    if(
    $thereisimage) {
        return 
    $thereisimage;
    } else {
        return 
    false;
    }
    }


    //get post image
    function zv_get_postimage() {
    global 
    $oceanwave_postimage_priority$post;

    if (
    $oceanwave_postimage_priority == 'wp') {
        
    $firstPriorityFunc 'get_wpfi_postimage';
        
    $secondPriorityFunc 'get_zvt_postimage';
    } else {
        
    $firstPriorityFunc 'get_zvt_postimage';
        
    $secondPriorityFunc 'get_wpfi_postimage';
    }

    if (!
    function_exists('add_theme_support')) $firstPriorityFunc $secondPriorityFunc 'get_zvt_postimage';
    if (
    $oceanwave_postimage_priority == 'wponly'$firstPriorityFunc $secondPriorityFunc 'get_wpfi_postimage';
    if (
    $oceanwave_postimage_priority == 'zvonly'$firstPriorityFunc $secondPriorityFunc 'get_zvt_postimage';


    $first $firstPriorityFunc();
    if (
    $first) {
        return 
    $first;
    }

    if (!
    function_exists('add_theme_support')) return false;
    if (
    $oceanwave_postimage_priority == 'wponly' || $oceanwave_postimage_priority == 'zvonly') return false;

    $second $secondPriorityFunc();
    if (
    $second) {
        return 
    $second;
    }

    return 
    false;

    }

    /*wp featured image - get post image */
    function get_wpfi_postimage() {
    global 
    $post;
        if (
    has_post_thumbnail($post->ID)) {
            return 
    zv_get_src_only(get_the_post_thumbnail($post->ID'zv-post-image'));
        }
        return 
    false;
    }

    /*zenverse thumbnail system - get post image */
    function get_zvt_postimage() {
    global 
    $post;

    $thereisimage get_post_meta($post->ID'image'true);
    if(
    $thereisimage) {
        return 
    $thereisimage;
    } else {
        return 
    false;
    }
    }

    //wordpress featured image support
    if ( function_exists('add_theme_support') ) {
        
    add_theme_support('post-thumbnails');
        
    add_image_size('zv-post-thumbnail'125125true);
        
    add_image_size('zv-post-image'550190true);
    }


    //social sharing
    function zv_like_facebook() {
    global 
    $post;
    ?>
    <iframe src="http://www.facebook.com/plugins************href=<?php the_permalink(); ?>&amp;send=false&amp;layout=button_count&amp;width=80&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;font&amp;height=21" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:80px; height:21px;" allowTransparency="true"></iframe>
    <?php
    }


    function 
    zv_share_twitter() {
    global 
    $post;
    ?>
    <a href="https://twitter.com/share" class="twitter-share-button" data-url="<?php the_permalink(); ?>" data-count="horizontal">Tweet</a>
    <?php
    }


    function 
    zv_share_googleplus() {
    global 
    $post;
    ?>
    <g:plusone size="medium" href="<?php the_permalink(); ?>"></g:plusone>
    <?php
    }


    function 
    zv_share_facebook() {
    global 
    $post;
    ?>
    <a name="fb_share" type="button_count" share_url="<?php the_permalink(); ?>" href="http://www.facebook.com/sharer.php">Share</a>
    <?php
    }


    function 
    zv_share_scripts() {
    ?>
    <script src="http://static.ak.fbcdn.net/connect.php/js/FB.Share" type="text/javascript"></script>
    <script type="text/javascript" src="//platform.twitter.com/widgets.js"></script>
    <script type="text/javascript">
      (function() {
        var po = document.createElement('script'); po.type = 'text/javascript'; po.async = true;
        po.src = 'https://apis.google.com/js/plusone.js';
        var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(po, s);
      })();
    </script>
    <?php
    }
    ?>

  10.     
    #39
    Member
    nice thread.

    i hope you can help me to get this plugin.

Page 4 of 4 FirstFirst ... 234

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Best shared hosting who support wordpress xmlrpc posting
    By sSKKa in forum Hosting Discussion
    Replies: 1
    Last Post: 30th Nov 2011, 05:17 PM
  2. WPWisdom.Com Wordpress Support
    By speedofpain in forum Site Reviews
    Replies: 0
    Last Post: 1st Mar 2011, 12:20 AM
  3. Looking for a live support/support ticket person?
    By CyberHacK in forum Community Cooperative
    Replies: 0
    Last Post: 22nd Dec 2010, 10:53 AM
  4. Replies: 10
    Last Post: 13th Dec 2009, 02:21 PM

Tags for this Thread

BE SOCIAL