Advertisement
Digitalraindrops

defaults.php

Aug 12th, 2011
138
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 9.66 KB | None | 0 0
  1. <?php
  2. /* Default Options */
  3. if ( !get_option('elevenfourty_theme_options') ) {
  4.     $options = array(
  5.         "css" => '',
  6.         "show_vertical_icons" => true,
  7.         "show_footer_icons" => true,
  8.         "home_type" => 'none',
  9.         "home_text" => '',
  10.         "single_type" => 'none',
  11.         "single_text" => '',
  12.         "header_logo_url" => '',
  13.         "cat_title" => '',
  14.         "footer_text" => '',
  15.         "css" => '',
  16.         "css_post" => '',
  17.         "css_page" => '',
  18.         "block_type_1" => 'none',
  19.         "block_name_1" => '',
  20.         "block_text_1" => '',
  21.         "block_type_2" => 'none',
  22.         "block_name_2" => '',
  23.         "block_text_2" => '',
  24.         "block_type_3" => 'none',
  25.         "block_text_3" => '',
  26.         "block_name_3" => '',
  27.         "block_type_4" => 'none',
  28.         "block_name_4" => '',
  29.         "block_text_4" => '',
  30.         "block_type_5" => 'none',
  31.         "block_name_5" => '',
  32.         "block_text_5" => '',
  33.         'google_font' => true,
  34.         'font_name' => 'Limelight',
  35.         'font_style' => 'regular',
  36.         'font_size' => 48,
  37.         'font_spacing' => 0.1,     
  38.         'font_bold' => false,
  39.         'font_italic' => false,
  40.         'page_titles' => true,
  41.         'widget_titles' => true,
  42.     );
  43.     update_option('elevenfourty_theme_options', $options );
  44. }
  45.  
  46. /* Default Cat_Meta */
  47. if ( !get_option('elevenforty_cat_meta') ) {
  48.     $options = array();
  49.     update_option('elevenforty_cat_meta', $options );
  50. }
  51.  
  52. /* Color List array */
  53. function elevenforty_color_styles () {
  54.     $options=array();
  55.     $options['aqua'] = array(
  56.         'primary' => '#027061',
  57.         'secondary' => '#217C6C',
  58.         'tertiary' => '#3BBCAA'
  59.     );
  60.     $options['blue'] = array(
  61.         'primary' => '#00609A',
  62.         'secondary' => '#3479B5',
  63.         'tertiary' => '#1982D1'
  64.     );
  65.     $options['dove'] = array(
  66.         'primary' => '#4B5676',
  67.         'secondary' => '#646E97',
  68.         'tertiary' => '#7C8EC1'
  69.     );
  70.     $options['green'] = array(
  71.         'primary' => '#4C7016',
  72.         'secondary' => '#5F8A1E',
  73.         'tertiary' => '#80BC24'
  74.     );
  75.     $options['olive'] = array(
  76.         'primary' => '#625D34',
  77.         'secondary' => '#58664B',
  78.         'tertiary' => '#AFAC91'
  79.     );
  80.     $options['orange'] = array(
  81.         'primary' => '#A72608',
  82.         'secondary' => '#BB430B',
  83.         'tertiary' => '#DB7C2A'
  84.     );
  85.     $options['pink'] = array(
  86.         'primary' => '#840259',
  87.         'secondary' => '#A11A6E',
  88.         'tertiary' => '#CF4283'
  89.     );
  90.     $options['purple'] = array(
  91.         'primary' => '#691E79',
  92.         'secondary' => '#893F9C',
  93.         'tertiary' => '#B56BC4'
  94.     );
  95.     $options['red'] = array(
  96.         'primary' => '#851607',
  97.         'secondary' => '#A3362D',
  98.         'tertiary' => '#D15949'
  99.     );
  100.     $options['suede'] = array(
  101.         'primary' => '#504638',
  102.         'secondary' => '#726E52',
  103.         'tertiary' => '#9C896E'
  104.     );
  105.     $options['teal'] = array(
  106.         'primary' => '#0C6989',
  107.         'secondary' => '#2D7595',
  108.         'tertiary' => '#52B5D6'
  109.     );
  110.     return $options;   
  111. }  
  112.  
  113. /* Color List */
  114. function elevenforty_color_list () {
  115.     $options=array();
  116.     $options[]='';
  117.     $options[]='aqua';
  118.     $options[]='blue';
  119.     $options[]='dove';
  120.     $options[]='green';
  121.     $options[]='olive';
  122.     $options[]='orange';
  123.     $options[]='pink';
  124.     $options[]='purple';
  125.     $options[]='red';
  126.     $options[]='suede';
  127.     $options[]='teal';
  128. }
  129.  
  130. /* Options for the Theme Setup page */
  131. function get_theme_admin_options() {
  132.    
  133.     $types = array(
  134.         'none' => array(
  135.             'value' => 'none',
  136.             'label' => 'None'
  137.         ),
  138.         'text' => array(
  139.             'value' => 'ad',
  140.             'label' => 'Advertisement'
  141.         ),
  142.  
  143.         'image' => array(
  144.             'value' => 'image',
  145.             'label' => 'Image'
  146.         ),
  147.         'text' => array(
  148.             'value' => 'text',
  149.             'label' => 'HTML Text'
  150.         )
  151.     );
  152.    
  153.     /* Google Font Style Options */
  154.     $google_font_style_options = array(
  155.         'regular' => array(
  156.         'value' => 'regular',
  157.         'label' => 'Regular'
  158.         ),
  159.         'bold' => array(
  160.             'value' => 'bold',
  161.             'label' => 'Bold'
  162.         ),
  163.     );
  164.    
  165.     global $theme_css;
  166.    
  167.     $general_options = array (
  168.         /* General Section */
  169.         array(
  170.             "name"  => "General Settings",
  171.             "type"  => "title"),
  172.        
  173.         array(
  174.             "name"  => __( "General Settings", THEME_NS ),
  175.             "type"  => "section"),
  176.            
  177.         array( "type"   => "open"),
  178.        
  179.         array( 
  180.             "id"    =>  "css",
  181.             "name"  =>  __('Default Color Stylesheet', THEME_NS),
  182.             "desc"  =>  __('You may change the default color scheme here', THEME_NS),
  183.             "type"  =>  'select',
  184.             "sub-type" => 'small',
  185.             'options'   =>  $theme_css,
  186.             "default"   => '',
  187.         ),
  188.        
  189.         array( 
  190.             "id"    =>  "css_page",
  191.             "name"  =>  __('Default Page Color Stylesheet', THEME_NS),
  192.             "desc"  =>  __('You may change the default page color scheme here', THEME_NS),
  193.             "type"  =>  'select',
  194.             "sub-type" => 'small',
  195.             'options'   =>  $theme_css,
  196.             "default"   => '',
  197.         ),
  198.  
  199.         array(
  200.             "name"  => __( "Side Social Media Icons", THEME_NS ),
  201.             "desc"  => __( "Show the right screen vertical social media icons", THEME_NS ),
  202.             "id"    => "show_vertical_icons",
  203.             "type"  => "checkbox",
  204.             "default"   => true),
  205.  
  206.         array(
  207.             "name"  => __( "Footer Social Media Icons", THEME_NS ),
  208.             "desc"  => __( "Show the horizontal footer social media icons", THEME_NS ),
  209.             "id"    => "show_footer_icons",
  210.             "type"  => "checkbox",
  211.             "default"   => true),
  212.  
  213.         array( "type" => "close"),
  214.        
  215.         array( 
  216.             "name"  =>  __('Header', THEME_NS),
  217.             "type"  =>  "section"),
  218.        
  219.         array( "type"   => "open"),
  220.        
  221.         array( 
  222.             "id"    =>  "header_logo_url",
  223.             "name"  =>  __('Custom Logo URL', THEME_NS),
  224.             "desc"  =>  __('Logo Image Width: 150px Height: 150px', THEME_NS),
  225.             "type"  =>  'text',
  226.             "default"   => '',
  227.         ),
  228.  
  229.         array( 
  230.             "id"    =>  "cat_title",
  231.             "name"  =>  __('Category Page Title', THEME_NS),
  232.             "desc"  =>  __('Sub title for category pages like Digital for Digital News', THEME_NS),
  233.             "type"  =>  'text',
  234.             "default"   => '',
  235.         ),
  236.        
  237.         array( 
  238.             "id"    =>  "home_type",
  239.             "name"  =>  __('Block (468px * 60px )', THEME_NS),
  240.             "desc"  =>  __('Select the content type for the default 468px * 60px header block', THEME_NS),
  241.             "type"  =>  'select',
  242.             "sub-type" => 'small',
  243.             'options'   =>  $types,
  244.             "default"   => 'none',
  245.         ),
  246.        
  247.         array( 
  248.             "id"    =>  "home_text",
  249.             "name"  =>  __('Display in Block', THEME_NS),
  250.             "desc"  =>  __('Enter the image url, html text, or adtext for the default header block', THEME_NS),
  251.             "type"  =>  'textarea',
  252.             "default"   => '',
  253.         ),
  254.        
  255.         array( 
  256.             "id"    =>  "single_type",
  257.             "name"  =>  __('Block (468px * 60px )', THEME_NS),
  258.             "desc"  =>  __('Select the content type for the default 468px * 60px page header block', THEME_NS),
  259.             "type"  =>  'select',
  260.             "sub-type" => 'small',
  261.             'options'   =>  $types,
  262.             "default"   => 'none',
  263.         ),
  264.        
  265.         array( 
  266.             "id"    =>  "single_text",
  267.             "name"  =>  __('Display in Block', THEME_NS),
  268.             "desc"  =>  __('Enter the image url, html text, or adtext for the default page header block', THEME_NS),
  269.             "type"  =>  'textarea',
  270.             "default"   => '',
  271.         ),
  272.        
  273.         array( "type"   => "close"),
  274.        
  275.         array(
  276.             "name"  => __( "Footer", THEME_NS ),
  277.             "type"  => "section"),
  278.            
  279.         array( "type" => "open"),
  280.  
  281.         array(
  282.             "name"  => __( "Footer Text", THEME_NS ),
  283.             "desc"  => __( "Company Footer Text", THEME_NS ),
  284.             "id"    => "footer_text",
  285.             "type"  => "textarea",
  286.             "default"   => ""),
  287.  
  288.         array( "type" => "close"),
  289.        
  290.         /* Font */
  291.             array(
  292.         "name"  => "Google Fonts",
  293.         "type"  => "title"),
  294.    
  295.         array( 
  296.             "name"  =>  __('Google Font', THEME_NS),
  297.             "type"  =>  "section"),
  298.        
  299.         array( "type"   => "open"),
  300.      
  301.         array(
  302.             'id' => 'google_font',
  303.             'name' => __('Use Google Font', THEME_NS),
  304.             'desc' => __('Select to use Google Fonts', THEME_NS),
  305.             'type' => 'checkbox',
  306.             "default"   => true,
  307.         ),
  308.      
  309.         array(
  310.             'id' => 'font_name',
  311.             'name' => __('Google Font Name', THEME_NS),
  312.             'desc' => __('Google Font Name from http://www.google.com/webfonts', THEME_NS),
  313.             'type' => 'text',
  314.             "default"   => 'Limelight',
  315.         ),
  316.      
  317.         array(
  318.             'id' => 'font_style',
  319.             'name' => __('Font Type', THEME_NS),
  320.             'type' => 'select',
  321.             'sub-type' => 'small',
  322.             'options' => $google_font_style_options,
  323.             'desc' => __('the text after the colon : from the font preview EG: Limelight:<b>regular</b>', THEME_NS),
  324.             'default' => 'regular'
  325.         ),
  326.      
  327.         array(
  328.             'id' => 'font_size',
  329.             'name' => __('Font Size', THEME_NS),
  330.             'desc' => __('Numeric Value for the Font Size', THEME_NS),
  331.             'type' => 'text',
  332.             'numeric' => 1,
  333.             'size' => 3,
  334.             'maxlength' => 2,
  335.             'min' => 0,
  336.             'max' => 60,
  337.             'default' => 55
  338.         ),
  339.      
  340.         array(
  341.             'id' => 'font_spacing',
  342.             'name' => __('Font Spacing', THEME_NS),
  343.             'desc' => __('Numeric Value for the Font Spacing EG: 0.20em', THEME_NS),
  344.             'type' => 'text',
  345.             'numeric' => 1,
  346.             'size' => 3,
  347.             'maxlength' => 4,
  348.             'min' => 0,
  349.             'max' => 2,
  350.             'default' => 0.1       
  351.         ),
  352.      
  353.         array(
  354.             'id' => 'font_bold',
  355.             'name' => __('Google Font Bold', THEME_NS),
  356.             'desc' => __('Font Bold', THEME_NS),
  357.             'type' => 'checkbox',
  358.             'default' => false
  359.         ),
  360.      
  361.         array(
  362.             'id' => 'font_italic',
  363.             'name' => __('Google Font Italic', THEME_NS),
  364.             'desc' => __('Font Italic', THEME_NS),
  365.             'type' => 'checkbox',
  366.             'default' => false
  367.         ),
  368.      
  369.         array(
  370.             'id' => 'page_titles',
  371.             'name' => __('Post and Page Titles', THEME_NS),
  372.             'desc' => __('Apply to Post and Page Titles', THEME_NS),
  373.             'type' => 'checkbox',
  374.             'default' => true
  375.         ),
  376.      
  377.         array(
  378.             'id' => 'widget_titles',
  379.             'name' => __('Widget Titles', THEME_NS),
  380.             'desc' => __('Apply Font to Widget Titles', THEME_NS),
  381.             'type' => 'checkbox',
  382.             'default' => true
  383.         ),
  384.         /* googleFont Settings */
  385.         array( "type"   => "close"),
  386.     );
  387.     return $general_options;
  388. }
  389.  
  390. function elevenforty_featured () {
  391.     $types = array(
  392.         'list' => array(
  393.             'value' => 'list',
  394.             'label' => 'Simple List'
  395.         ),
  396.         'image' => array(
  397.             'value' => 'image',
  398.             'label' => 'Large Image no Excerpt'
  399.         ),
  400.         'thumb' => array(
  401.             'value' => 'thumb',
  402.             'label' => 'Thumbnail and Excerpt'
  403.         ),
  404.         'excerpt' => array(
  405.             'value' => 'excerpt',
  406.             'label' => 'Excerpt no Thumbnail'
  407.         )
  408.     );
  409.     return $types;
  410. }
  411.  
  412. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement