Jump to content

Search the Community

Showing results for tags 'themeoptions'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Welcome to PHP Freaks
    • Announcements
    • Introductions
  • PHP Coding
    • PHP Coding Help
    • Regex Help
    • Third Party Scripts
    • FAQ/Code Snippet Repository
  • SQL / Database
    • MySQL Help
    • PostgreSQL
    • Microsoft SQL - MSSQL
    • Other RDBMS and SQL dialects
  • Client Side
    • HTML Help
    • CSS Help
    • Javascript Help
    • Other
  • Applications and Frameworks
    • Applications
    • Frameworks
    • Other Libraries
  • Web Server Administration
    • PHP Installation and Configuration
    • Linux
    • Apache HTTP Server
    • Microsoft IIS
    • Other Web Server Software
  • Other
    • Application Design
    • Other Programming Languages
    • Editor Help (PhpStorm, VS Code, etc)
    • Website Critique
    • Beta Test Your Stuff!
  • Freelance, Contracts, Employment, etc.
    • Services Offered
    • Job Offerings
  • General Discussion
    • PHPFreaks.com Website Feedback
    • Miscellaneous

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests


Age


Donation Link

Found 1 result

  1. I want a enable/disable option in my wordpress theme admin panel to enable or diable the main navigation menu. I know how to do this using php, but i need to make a change some javescript code in a .js file. but how to do this with php. i mean i have allready made the option in the theme adminpanel php file availeble, but it needs to do something in a .js file. i hope you understand what i mean. portion of the themoptions file: $dd_options[] = array( "name" => __("nav menu", "dd"), "desc" => __("Enable / Disable navigation menu", "dd"), "id" => "nav_menu", "std" => "1", "type" => "checkbox"); --------------------------------------------------------------- header.php: <?php if(!empty($nav_menu)) { ?> <?php if ( has_nav_menu( 'headermenu' ) ) { ?><?php wp_nav_menu ( array( 'menu_id' => 'nav','container'=> 'ul', 'theme_location' => 'headermenu' )); ?> <?php } else { ?> nothing <?php } ?> --------------------------------------------------------------- theme.js file: ddsmoothmenu.init({ mainmenuid: "menu", //menu DIV id orientation: 'h', //Horizontal or vertical menu: Set to "h" or "v" classname: 'navigation', //class added to menu's outer DIV //customtheme: ["#1c5a80", "#18374a"], contentsource: "markup" //"markup" or ["container_id", "path_to_menu_file"] }) when i disable the menu it must disable the whole ddsmoothmenu in the javascript file. but how to do this? i'm a bit lost.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.