0

Where can I find the HTML for a Wordpress site? I'm using the "X" child theme. I found a tutorial explaining how to achieve an effect that I want and it says that "All I need is an HTML markup and to call the script". Also, what does "calling the script" mean? The child theme has a PHP file and a CSS file (the tutorial gives me a javascript file and a CSS file, where would the javascript go? In the PHP file?)

closed as too broad by TheDeadMedic, Mayeenul Islam, bueltge, EAMann Jul 6 '16 at 15:35

Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

  • Your question is way too broad to answer. If you're still struggling with basic concepts you're more likely to find satisfying information on tutorial sites like wpbeginner than here. – cjbj Jun 27 '16 at 7:42
0

You got javascript file and CSS file! Then you have to put those files in you child theme folder like themes -> your_child_theme_folder -> js(if you dont have js folder then create one) and place your js file here AND you have to put you css file in css folder inside your child theme.

Now you need to call js file from functions.php

If you dont have functions.php file in you child theme folder then create it first. Here is the code for calling js file

function wpdocs_theme_name_scripts() {
wp_enqueue_script( 'script-name1', get_stylesheet_directory_uri() . '/js/YOUR_JS_FILE_NAME', array('jquery'), true ); //Path of you js file
}
add_action( 'wp_enqueue_scripts', 'wpdocs_theme_name_scripts' );

In the above code script-name1 is the custom name that you will give to every script you call and the name shud be unique. And I hope you are already aware of calling css file..

Not the answer you're looking for? Browse other questions tagged or ask your own question.