Questions tagged [theme-development]

Themes create the public (front-end) interface for a WordPress site.

Filter by
Sorted by
Tagged with
0
votes
0answers
8 views

What is the best way of inserting information onto a page, that will need to be updated?

I am creating a custom theme. On one page there is a menu with multiple menus you can access via an anchor, without leaving the page. e.g. Breakfast, Lunch and Dinner Currently in order to display ...
0
votes
1answer
8 views

get_next_posts_link() returns no result despite available posts

I am developing a custom theme based on the Genesis framework. I want to display a 'previous post | next post' navigation below any article in the single post view. However, neither ...
0
votes
0answers
12 views

Need Help to make a logic for editing posts in Frontend

I have an issue, I'm creating classified website, so I have a login and a registration form and users can post their own adverts. They have account page where they can see their posted adverts, I'm ...
0
votes
1answer
33 views

What form should the $query media query array have for an Elementor page builder function?

I'm building a theme with the Elementor page builder and I want to add some CSS output to certain elements. I hooked into the parse_css function. I want to use the stylesheet::add_rules() function (...
0
votes
1answer
18 views

Adding the_content() return warning count()

I'm using the_content() function for elementor plugin implement, but warning comes up once I use this function: Warning: count(): Parameter must be an array or an object that implements Countable ...
0
votes
1answer
32 views

Redirection from a specific page for users logged in but not with membership

I am trying to redirect logged in user but not with a membership, from a specific page to product page. But it is showing error if I land on that page. Let's say join is the page with id 1867. Here is ...
0
votes
2answers
21 views

cannot echo the_post_thumbnails

I'm using the following PHP code to echo post thumbnails. <?php $args = array( 'post_type' => 'post' , 'orderby' => 'date' , 'order' => 'DESC' , 'posts_per_page' => 1, '...
0
votes
2answers
24 views

get_header() on new page fatal error

I'm building theme and using this link in navigation bar to about.php page. <li><a href="<?php echo get_template_directory_uri(); ?>/about.php">אודות</a></li> ...
0
votes
1answer
17 views

Is functions.php in themes applied to all templates?

I've been reading the theme developer handbook for a bit and maybe I ended up with one too many questions on wordpress theme development. I haven't done any theme/php development in a very long time ...
0
votes
0answers
12 views

Wordpress Contact form 7 falat error while send an email

Fatal error: Uncaught Error: Call to a member function get_status() on null in /home/mywebsite/public_html/wp-content/plugins/contact-form-7/includes/contact-form.php:732 Stack trace: #0 /home/...
0
votes
1answer
21 views

Rename a folder via HTML POST request

I am trying to rename a folder in the uploads folder if an HTML form is submitted (used to edit entry names). This following code is what I have so far but it isn't working. if(isset($_POST['...
0
votes
0answers
11 views

Sidebar not displaying (theme development)

I'm developing a theme via an online course and I can't get the sidebar to display. I've used the hook widget_init and the function is being called because I can echo text out. Index.php is correctly ...
0
votes
1answer
32 views

Theme support title tag - how to replace the default WP separator (with a filter)?

I'm developing a theme for Themeforest and one of their requirements is about the tag. Themeforest states their requirement as follows: The theme must let WordPress add and manage the title. This is ...
0
votes
0answers
16 views

Next and previous post link shows error in first and last post

I have added the Next and previous post link in a single.php file, I need to show the same categories post in the next and previous button. but it is showing error at first and last point "Notice:...
0
votes
1answer
23 views

Trying to customise 2011 Child Theme Background Colour

I am trying to customise the background colour of my site. It's a 2011 Child Theme. When I go to Appearance -> Customize -> Colors, I get the Light and Dark option under Color Scheme, but can't ...
-1
votes
0answers
16 views

If someone bought a premium WP theme or plugin NOT under GPL, can they freely redistribute it? [closed]

If someone bought a premium WP theme or plugin, can they freely redistribute it Or even resell it? Can they do that even if the theme or plugin is NOT GPL licensed?
0
votes
0answers
27 views

is_user_logged_in returns false when I access certain pages

I'm working on a single page application built with WordPress and Vue.js, I used add_rewrite_rule to redirect all sub-pages of projects/ to index.php. Only logged-in users can access the application. ...
0
votes
1answer
29 views

Custom pages with html in wordpress editor vs. writing it all directly in the php template files?

I am building a custom theme from a previous html site I built. Some pages I have set up using advanced custom fields so the client can change parts of those pages. I set those up using page-{slug}....
0
votes
1answer
20 views

How to dynamically set a background image with the customizer without putting the css as an inline-style

Here is what I am using currently, <div class="home-header" style="background-image:url('<?php echo get_theme_mod( 'home-header-img' ); ?>'); height: 500px; width: 100%; ...
0
votes
1answer
21 views

Override the filter from plugin in child theme

I have a filter below from plugin file: $review_num_fetch = apply_filters('tourmaster_review_num_fetch', 5); I want change the number from 5 to 3, I’ve tried change it like below: // reviews number ...
0
votes
1answer
15 views

Warning: printf(): Too few arguments in helpers.php file

So I'm getting the following error Warning: printf(): Too few arguments in /lib/helpers.php on line 34 So line 34 is 'class' => [] // Define the read more url function read_more_url() { // ...
0
votes
1answer
8 views

Unable to retrieve get_author_posts_url

So I'm running into issues retrieving the get_author_posts_url() - I'm still in the learning process and want to know why this might be happening: Here is the code: <!-- Locate the header.php file ...
1
vote
1answer
12 views

Working with a WP Starter theme

I am building a custom theme and I am starting with a starter theme. When add my CSS, do I modify the CSS in the style.css or add my own CSS on top of what's already there? I don't want to remove ...
1
vote
0answers
25 views

How to get boolean value from register_meta properly?

I registered boolean by register_meta(), to use it in my Gutenberg Plugin Sidebar, I added default value to it true: register_meta( 'post', '_thefuturmeta_post_title_visibility', array( '...
0
votes
2answers
32 views

Conditional Homepage for logged in user

I want to change the home page url of wordpress site to another url when the user is logged in and have a specific role. Is this possible? Thanks in advance.
0
votes
1answer
22 views

Wordpress theme options checkbox default checked state

I am developing a custom theme. I added a checkbox with the settings api. They all work except for the ones that are checked by default (checked="checked"). They do not save when they get ...
1
vote
1answer
21 views

Remove CPT slug from URL WordPress

I have created custom post type with the slug (example: loan-officer). I want to remove CPT slug from the URL. I have used below code, I have seen so many threads like this, still, nothing is working. ...
0
votes
0answers
13 views

how selectively get data into front page from custom post type

Hello i'm first tackling on wordpress, any help would be much appreciated . i want to in admin's panel menu add custom page where admin can add ID's of posts and those posts should be display on front ...
0
votes
1answer
17 views

Wordpress theme files Organization

I am new at WordPress themes development, and I am willing to build a complete theme, while I still at the index.php, I found that the file itself becomes more complicated, a lot of HTML tags comes ...
0
votes
1answer
20 views

add diffrent images to a page

I want to add diffrent images to a page,the_post_thumbnail_url() just show feature image but I don't want to dispaly feature image at all! what should I do? Is there another solution?
0
votes
0answers
5 views

WooCommerce use different template for Archive page and Single page

I am building a theme with WordPress and WooCommerce. I created a woocommerce.php file in my theme folder, but all the page of WooCommerce use this template. How do I use different template for ...
0
votes
0answers
25 views

Custom themes that won't work when theme is changed

I am building a couple custom themes from previously designed and developed sites. I developed them and will be maintaining as well. As I am sort of new at custom theming I always hear that I should ...
0
votes
1answer
18 views

Nav menus all outputting the same links

I have registered the following menus in my functions.php // register menus function register_menus() { register_nav_menus( array( 'footer-01' => 'Footer 01', '...
0
votes
0answers
12 views

Action hooks that trigger on new post/page/media being added

I am looking to create some sort of activity log that will track recent actions being done in the wp-login. For example when the admin will all one of the new post, page or media to to the site it ...
0
votes
0answers
7 views

how to create custom job template in my theme using simple job board plugin?

I'm developing a theme with the simple-job-board plugin, I want to create a custom job board in my theme and not have to modify wp-content\plugins\simple-job-board/templates/archive-jobpost.php
0
votes
1answer
17 views

WordPress Theme With Modified View

I'm very new to WordPress. I'm going through some tutorials in developing a theme. What I'm trying to grasp is creating a theme when the pages are a bit different. They all have the same theme but ...
0
votes
0answers
5 views

How to develop school result printing site with wp…which plugin and theme is suitable?

Please I am working on school website that just needs to allow teachers to upload the results of their students; and students will also login to view their result. I know that achieving this kind of ...
0
votes
0answers
13 views

woocommerce reduce total inventory stocks on status change to complete

so my problem is when someone submit an order and complete it stocks only getting reduced from that specific products which is variable of a product, for example: There is product of Pen in total of ...
0
votes
2answers
12 views

add page items to index

I want to show page items in my wordpress theme and this is the code: <section id="two"> <div class="inner"> <?php $pagesargs = array( ...
0
votes
0answers
12 views

How can we stop showing short code in create or edit post section

I've tried one solution which wasn't helpful i added js in admin area with css display none but problem is js takes few seconds to load and it's not good practice to show short code for few seconds. ...
1
vote
1answer
21 views

How to enqueue scripts and styles only when there are needed?

I have page created based on ACF and flexible fields layout. In my theme I have some JS scripts like masonry, fancybox, lazyload. For now im using standard wp_enqueue_style in function.php file. Is ...
0
votes
0answers
7 views

Post Thumbnail Uploaded pragmatically and attached with post but not showing on Front-end or Post Edit Page

I am trying to do something like this. For multiple file upload, I want to create a post for each image and attach that image with the post. Everything is working. As you can see in the picture image ...
0
votes
0answers
22 views

WordPress Customizer Control with React

I am just doing a demo on the WordPress customizer API to edit the header with custom controls. I have designed a custom control by extending WP_Customize_Control and Jquery to refresh/postMessage ...
0
votes
1answer
13 views

Wordpress theme settings not saving

I am trying to develop a theme. I am at the part of using the settings API. The code I use for the settings are as follows: In the example snippets I'm using variables to show the structure of my ...
0
votes
0answers
17 views

create loop for the_content()

I want to create loop for the_content method to destroy content error but I don't know how to create this is what I have now: <div class="b-bottom"> <p><?php the_modified_date('F ...
0
votes
0answers
18 views

Issue with ACF and setup_postdata

On my single post template, I hook a partial template using the following code in order to display related products above the post content : <?php if ( have_rows( 'featured_products' ) ) : ?&...
0
votes
0answers
10 views

How to incorporate Tabler UI in my custom plugin?

I want to use Tabler UI in my custom plugin. https://tabler.io/ How I could make the www.rooturl.com/tabler to be the index page so I can use the contents of tabler that offers? Or is there a better ...
0
votes
0answers
9 views

404 error in linked page

I have two kind of detail pagea page for posts and another for news the post page detail is single.php and it's ok but another page is sinle-news.php and when I click on link it open 404 page! this is ...
0
votes
1answer
14 views

Alter shop page lay-out in OceanWP theme

In OceanWP, I want to alter my shop page by a Beaver Builder template so I modified part of the index.php file as follows: <?php // BLOG PAGE if ( is_home() ) { /* Beaver Builder generated ...
0
votes
1answer
29 views

How to wrap all titles generated by Gutenberg “Heading” block with <span> tag

Gutenberg is still relative new concept, so I lack experiences (and the Internet lacks good tutorials). My goal it to wrap all heading titles generated by Gutenberg's "Heading" block with the <span&...

1
2 3 4 5
82