If that’s the whole class then you don’t have a method called get_instance
By the way, even if you had a get_instance
method, you are calling get_instance
as a static method, __construct
gets called only when creating a new instance from the class using the new
keyword, like this
$obj = new WCS_THEME();
That’s basically it, Going the your class in it’s current state, all you need to do is a new instance, as shown in the code above.
Don’t forget about the namespace we creating the instance
Related Posts:
- How Do I Protect My Premium WordPress App Theme from Copying?
- When to use _e and __ for the translation?
- Get entered value of customiser field for live preview
- With WordPress themes, where do I store the images and files relatively?
- How to Include SVG sprites icons into the body tag? [closed]
- Why doesn’t /2013/01/ properly return January’s archives in archive.php?
- Excess White Space Above Admin Bar on Frontend Using Twitter Bootstrap
- Child Theme not loading parent CSS
- Use of undefined constant FS_CHMOD_DIR – assumed ‘FS_CHMOD_DIR’
- WordPress settings API error when checkbox unchecked
- How the WordPress sidebar works
- two tinyMCE editors in the same page
- How to remove header images from all pages except the home page? skeleton theme
- Replace Home with image link inside custom header menu
- Separated Comment from Post
- WordPress website loads but is not displayed until page scrolled
- wp_head() not inserting the default stylesheet style.css
- Theme Customizer not loading
- WordPress Customizer Control with React
- Theme Options page not showing up in admin menu
- File Security Check in wordpress in index.php of theme
- how to implement wp_is_mobile on themes?
- Force index.php have_posts() loop to exit if no sticky posts found
- Is my approach to enqueue styles inefficient?
- Part of Menu Item Hidden on Header Menu
- How do the default themes reference style.css?
- Input ordering in wordpress theme customizer
- Customize the previous_post_link output
- How to use get_template_part instead of include_once?
- How to add field customizable by the theme editor to your theme?
- Translation Issue with WordPress Theme Check in comment_form function
- Using esc_url with a hard coded url
- How to Add Custom Button to Text(HTML) Editor and NOT Visual Editor
- Custom Nav Walker Trouble
- How to get javascript slider to work! [closed]
- Dropdown filter by custom field
- Reactor Theme: Prevent Post Thumb on Post
- How to make permalinks update from code?
- How to properly create a child theme
- How can I tell what category I’m in?
- Syntax error potentially causing CSS catastrophic failure
- Custom WordPress File Inclusion
- WordPress 3.8 Backend Admin Color Scheme add more scheme how to do?
- How to change the theme directory uri for localhost?
- How To Pick Custom Size Of Uploaded Image In Theme Via the_post_thumbnail();?
- Take control of WordPress before functions.php
- Why in the static pages of my theme are showing these information?
- featured content: which area does this cover [closed]
- How to count posts of a category and of a category limited by a tag
- add_theme_support( ‘admin-bar’ ) causes fatal error
- Which cache is kicking
- How do I merge 2 WordPress Themes?
- Customizer: get_preview_url() inside customize_save_after hook
- Fastest way to update a theme
- Load different single.php templates according to post layout selection
- Full width featured thumbnail
- Is there a way to switch to another theme?
- Right procedure when you develop a WP Website for a client
- Different themes on one site
- // File Security Check from WooCommerce [duplicate]
- Allow different tags in widget titles
- When trying to set title, not sure how to edit it for different pages
- Site returns a 500 Internal server error
- Switch theme if ie compatibility/quirks mode?
- Pagination and multiple loops
- Does wordpress add their own classes into nav menus?
- Changing background color depending on parent page?
- Any way to change/add to the theme name dynamically?
- Available widgets is not showing up?
- Getting white screen of death on category pages because of body_class() function
- Alter shop page lay-out in OceanWP theme
- WordPress link to another page in site does not render a
- Developing WordPress site behind a static site
- Problem with Displaying Custom Theme Page’s Content
- Code showing in wordpress post titles around website
- register_theme_directory() sees custom themes directory, but blank frontend
- Change site title color on individual pages
- Git ignore everything except custom theme directory
- HTML to → WP Conversion
- Add multiple sections, settings and controls at once to the Customizer
- Font not loading [closed]
- How to change parent permalink?
- how to call options on front end and add logo
- Jetpack Infinite Scroll Not Working
- Adding a Class to an Getting From Post Content
- Editable screenshot.png in a custom theme developed
- How to create multiple pages in a client theme?
- How to share posts (and plugins) between existing site and new, separate dev/test installation?
- get_theme_mod not pulling css colors into header using wp_head
- Duplicate WordPress site to subdirectory but use same db?
- Menu order of parent menu from perspective of child menu
- Conditional loop based on current page
- Theme customizer live preview JS- Trying to bind to an html image url without luck
- wp_deregister_script was called incorrectly
- Undefined index: debuging error for theme option template snippet
- custom theme’s search not working
- Permalinks problem with custom theme
- Purchased Theme to Custom Made Theme? [closed]
- How to make website with many template that active [closed]
- What is the point of using archive.php instead of index.php?