Categories
CMS Mastering Development Wordpress

Bootstrap slider not working

I have a html bootstrap slider which works fine with captions and everything.I would like to integrate it into my Wp theme (my forst one, so total newbie).I found a code, which seems to helo, but it only shows the three pictures and nothing slides…if I hard code the slider, it works.I understand I can […]

Categories
CMS Mastering Development Wordpress

What is the correct way of getting parent styles from child theme?

I just started customising our company’s theme. Thus i just started learning wordpress development In wordpress original docs about child themes, it says: If the parent theme loads its style using a function starting with get_template, such as get_template_directory() and get_template_directory_uri(), the child theme needs to load just the child styles, using the parent’s handle […]

Categories
CMS Mastering Development Wordpress

Why is my wp_enqueue_style() not working?

I am new to wordpress and am trying to develop a theme on localhost for the first time. I am trying to load style.css using this code in functions.php function load_stylesheets(){ wp_register_style(‘bootstrap’, get_template_directory_uri().’/assets/css/bootstrap.css’, array(), false, ‘all’); wp_enqueue_style( ‘bootstrap’); wp_register_style(‘style’, get_template_directory_uri().’/style.css’, array(), false, ‘all’); wp_enqueue_style(‘style’); } add_action(‘wp_enqueue_scripts’, ‘load_stylesheets’); My style.css file is in my main directory […]

Categories
CMS Mastering Development Wordpress

Links to CSS and JS change based on page you’re visiting

I have a multisite setup. One of the sites is having an issue linking to the stylesheet and JavaScript resources. For some reason, the URL to those resources add the page url to the link. For example, if I’m on the about us page (/about-us), then the url to the CSS changes to mysite.com/about-us/wp-content…….. when […]

Categories
CMS Mastering Development Wordpress

CSS style and app.js not loading

I’m brand new at theme development. My directory is the following: I should see, in the page source (even if I have a blank page) the app.js loaded, but I don’t. This is what I see: what is wrong in the function.php: function load_stylesheets() { wp_register_style(‘stylesheet’, get_template_directory_uri() . ‘/style.css’,”,1,’all’); wp_enqueue_style(‘stylesheet’); wp_register_style(‘custom’, get_template_directory_uri() . ‘/app.css’,”1,’all’); wp_enqueue_style(‘custom’); […]

Categories
Mastering Development

WordPress Navwalker not toggling open on mobile

I have implemented the WP_navwalker in my project but it will not open on mobile. I will post the code below. If I miss something please let me know. I appreciate it if someone can help me find out what I might be missing. Thank you. I am using the latest navwalker from https://github.com/wp-bootstrap/wp-bootstrap-navwalker and […]

Categories
CMS Mastering Development Wordpress

(BAD REQUEST) 400 admin-ajax.php error WordPress

I updated my WordPress to current version as it was very outdated. And now I am getting a bad request browse issue now. /wp-admin/admin-ajax.php:1 Failed to load resource: the server responded with a status of 400 (Bad Request) browser pop up. This only occurs when user is not logged in admin. I checked plugins and […]

Categories
CMS Development Wordpress

why enqueued styles in header.php shows in footer?

I`m using this code in functions.php: add_action(‘wp_head’, ‘addMyStyle’); function addMyStyle() { wp_enqueue_style( ‘bootstrap’, get_template_directory_uri() . ‘/css/bootstrap.css’, false, ‘1.0’, ‘all’, false ); wp_enqueue_style( ‘bootstrap-rtl’, get_template_directory_uri() . ‘/css/bootstrap-rtl.css’, false, ‘1.0’, ‘all’, false ); wp_enqueue_style( ‘style’, get_template_directory_uri() . ‘/style.css’, false, ‘1.0’, ‘all’ ); } and <?php wp_head(); ?> tag is right before </head> tag. but style files load […]

Categories
Development iOS Plugins

Facebook Pixel not working on iOS mobile (WordPress/Woocommerce)

I am using WordPress (v 5.3) with WooCommerce (v 3.8.1). My facebook pixel registers events (ViewContent/InitiateCheckout/AddToCart/Purchase/etc.) on desktop, but doesn’t register events on mobile (iOS). All my plugins and theme are up to date. For my theme, I am using Youplay (v 3.7.4). In searching for an answer, I have noticed some people who have […]

Categories
CMS Development HTML PHP Wordpress

I got big white screen when i attach main style sheet of Html in functions.php

I am new here on @stack Enchange . Here is an issue on my work . I hope you gyies can help me in this When I attach main style sheet in function.php . a white screen occur in front end. after inspecting element all style sheet and java script are attached and html is […]