Build Form on Dashboard

After did many trials and errors, finally I found the answer. Just in case anyone wondering how this working, I put the full code right here : /* == THEME OPTIONS == */ add_action(“admin_menu”, “setup_theme_admin_menus”); function setup_theme_admin_menus() { add_submenu_page(‘themes.php’, ‘Generate Coupons’, ‘Generate Coupons’, ‘manage_options’, ‘generate-coupons-elements’, ‘theme_generate_coupons_settings’); } function theme_generate_coupons_settings() { ?> <div class=”wrap”> <?php screen_icon(‘themes’); … Read more

How can I include the js and css file of my custom theme dynamically in header.php

I guess you wanted to enqueue all the files in your css and js directory of your theme. Thats the reason you are trying to use the scandir(). get_template_directory_uri() returns URL not the directory path. You need to use get_template_directory() for directory. If you wanted to do that, then do it in functions.php function enqueue_all_front_resources(){ … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)