WordPress

WordPress is a free and open-source content management system (CMS) based on PHP and MySQL for creating websites and blogs. Features include a plugin architecture, a template system and strong management, customization and search systems; through its dynamic presentation of content, webmasters have the flexibility to create websites easily.

Share tech news, updates, or what's on your mind.

Sign up to Post

Hello,

This is a bit complicated and Ill do my best to explain.

1. I created a custom post type (Resources),
2. For this custom post type I created taxonomies (Category , Population)
3. The Custom Post type and Taxonomy were created by WCK - Custom Fields and Custom Post Types Creator
4. I imported all resources and taxonomies into Wordpress using WP All Import - ACF Add-On
5. When I imported, I mapped the ACF taxonomy fields to use the ones created by WCK

Everything appeared to work, all posts and custom fields were imported including the taxonomies

Now that I have all the data in the system I will doing 2 things with it.

1. I have a search page on public site which has drop down menus options using the taxonomies (uses a custom wp_query)
2. I have a front end form for the public to submit new Resources (uses acf_form)
3. When logged into admin and viewing resources, you will see the taxonomy are displayed in 2 separate  places in the post editor, even though they are the same data. See screen shot below

You will notice the taxonomies are not in sync.

When searching in public search tool, it uses the taxonomy checkboxes on the right, but when submitting using the acf_form. it fills the taxonomy checkboxes on the left

These are the exact same taxonomy, why are they not in sync?

So these are my options (unless anyone can suggest a better one)
1. Can I make them sync somehow?
2. Can I make my search form use the data from the acf taxonomy …
0
I have a site I am working on that when you do a search for a post_type, it won't change the title.  I have the following hack but it does not work because it runs before the jQuery library is included.

function searchfilter($query) {
    if ($query->is_search && !is_admin() ) {
        if(isset($_GET['post_type'])) {
            $type = $_GET['post_type'];
                if($type == 'product') {
                    ?>
    <script>
    (function($){
        var term = '<?php the_search_query(); ?>';

        $('.archive-title').text("Your Search for: " + term + "");
        })(jQuery);
    </script> 
    <?php
                }
        }       
    }
return $query;
}
add_filter('pre_get_posts','searchfilter');

Open in new window


You can see what I mean here: https://gardenersstage.wpengine.com/?s=seeds&post_type=product
"Shop Our Store"  Should say "Your Search for: " + term + "" Or do you know how to change the title of the page if the post type is set?
0
I'm using a Child theme in my Wordpress site, and I want to override a line in my parent theme's Functions.php file:

If( ! current_theme_supports( 'deactivate_tribe_events_calendar' ) )
{
    // Below was removed to make single events look better:
	require_once( 'config-events-calendar/config.php' );			//compatibility with the Events Calendar plugin
}

Open in new window

I want to comment out the "require_once" line. I tried adding that to my child's Functions.php line:

If( ! current_theme_supports( 'deactivate_tribe_events_calendar' ) )
{
    // Below was removed to make single events look better:
    //	require_once( 'config-events-calendar/config.php' );			//compatibility with the Events Calendar plugin
}

Open in new window

But when the site loaded it ignored that and obviously used the line from the parent theme.

How can I do that without having to worry about updating every time my theme updates?
0
I'm running a request that should return orders that are processing.
However, when I change the status in WooCommerce to On Hold, or something other than Processing - I still get the previous results, even if new orders are marked Processing.

Sometimes this clears up if I wait awhile.  If I test the same results in PostMan - i get the correct results.

Here's my code for getting the data:

Function WRequest(URL As String, method As String, POSTdata As String) As String
        Dim responseData As String = ""
        Try
            Dim cookieJar As New Net.CookieContainer()
            Dim hwrequest As Net.HttpWebRequest = Net.WebRequest.Create(URL)
            hwrequest.CookieContainer = cookieJar
            hwrequest.Accept = "*/*"
            hwrequest.AllowAutoRedirect = True
            hwrequest.UserAgent = "http_requester/0.1"
            hwrequest.Timeout = 60000
            hwrequest.Method = method
            If hwrequest.Method = "POST" Then
                hwrequest.ContentType = "application/x-www-form-urlencoded"
                Dim encoding As New Text.ASCIIEncoding() 'Use UTF8Encoding for XML requests
                Dim postByteArray() As Byte = encoding.GetBytes(POSTdata)
                hwrequest.ContentLength = postByteArray.Length
                Dim postStream As IO.Stream = hwrequest.GetRequestStream()
                postStream.Write(postByteArray, 0, postByteArray.Length)
                postStream.Close()
            End If
          

Open in new window

0
I'm looking for Wordpress plugins to replace some antiquated membership software an organization I work with is using. Essentially, we need the following:

Paid Memberships, with the ability to handle different types (like Individual, Family, Corporate, etc)
Events, with the ability to register for events
Member forum

I'm looking into Events Calendar Pro with EventBrite Tickets for the Events, and MemberPress for the membership management.

Anyone used those, or have better suggestions? The organization doesn't mind spending a little money to get what they're after.
0
I have installed a basic google analytics plugin and for the most part it works. It tracks all the pages and taxonomies but not the custom post type. So, once you drill down on the actual website to:

https://example.com/product/some-category/some-item

In google analytics it only goes as far as:

https://example.com/product/some-category/

leaving off the item.

When I view the source of the custom post type product item page, I can see that the tracking code is there.

Does anyone know why this might be happening?

Post type:

register_post_type('product', array(
'supports'      => array('title', 'editor', 'thumbnail', 'excerpt'),
'rewrite'       => array('slug' => 'product'),
'has_archive'   => true,
'public'        => true,
'labels'        => array(
        'name'         => 'Products',
        'add_new_item' => 'Add New Product',
        'edit_item'    => 'Edit Product', 
        'all_items'    => 'All Products',
),
'menu_icon'     => 'dashicons-cart'
));

Open in new window



Plugin used:

https://wordpress.org/plugins/ga-google-analytics/
0
I have purchased the Events Calendar Pro WordPresss plugin. I am trying to make the countdown timer look better but I am new to php and apparently I suck at it.

I have been trying to edit the countdown-widget.php file in an effort to make it look better because the default one is terrible. I want it to look more modern.

This is what i have tried:
<table border="0" width="100%" cellspacing="0" cellpadding="0" bgcolor="#657b86">
   <tr>
     <td width="50%"><p align="center"><img border="0" width="200" height="148" src="<?php echo $img; ?>" ></td>
   
     <td align="center" width="50%"><font size="30px"><div class="tribe-countdown-days tribe-countdown-number">DD</font><br />
            <span class="tribe-countdown-under"><?php esc_html_e( 'days', 'tribe-events-calendar-pro' ); ?></span>
      </div>
      <div class="tribe-countdown-colon">:</div>
      <div class="tribe-countdown-hours tribe-countdown-number">HH<br />
            <span class="tribe-countdown-under"><?php esc_html_e( 'hours', 'tribe-events-calendar-pro' ); ?></span>
      </div>
      <div class="tribe-countdown-colon">:</div>
      <div class="tribe-countdown-minutes tribe-countdown-number">MM<br />
            <span class="tribe-countdown-under"><?php esc_html_e( 'min', 'tribe-events-calendar-pro' ); ?></span>
      </div>
      <?php if ( $show_seconds ) : ?>
            <div class="tribe-countdown-colon">:</div>
            <div class="tribe-countdown-seconds tribe-countdown-number tribe-countdown-right">SS<br />
                  <span class="tribe-countdown-under"><?php …
0
My site is built in WordPress with WooCommerce and is a wholesale site and so all the products add to cart is disabled until the user is logs in. But due to caching of browser, even after the user is logged in, the add to cart is not being enabled, the logged in user has to refresh the page multiple times to see the add to cart button.

Below is the code I am using to disable and enable the add to cart button

* display add to cart only to wholesale group */
if(is_user_logged_in() )
{
    $current_user = wp_get_current_user();
    foreach ( $current_user->roles as $role )
    {
        if($role != "Wholesale Buyer" || $role != "Customer" || $role != "Admin")
        {
            // If user role is Wholesale Buyer or Customer or Admin, Add to Cart button and Price will display on both Single and Shop/Category Pages
        }
    }
}
else
{
    pc_woo_remove_add_to_cart_and_price();
}


function pc_woo_remove_add_to_cart_and_price()
{
    // Remove Add to cart from Single Product Page
    remove_action( 'woocommerce_simple_add_to_cart', 'woocommerce_simple_add_to_cart', 30 );
    remove_action( 'woocommerce_grouped_add_to_cart', 'woocommerce_grouped_add_to_cart', 30 );
    remove_action( 'woocommerce_variable_add_to_cart', 'woocommerce_variable_add_to_cart', 30 );
    remove_action( 'woocommerce_external_add_to_cart', 'woocommerce_external_add_to_cart', 30 );
    remove_action( 'woocommerce_single_variation', 'woocommerce_single_variation_add_to_cart_button', 20 );
 

Open in new window

0
I have a website in a cPanel account, running through a WHM installation I control. The default file owner and group appear to be incorrect, as new files are being created with "nobody" as the owner and I think the group owner too.

It looks like the default owner and group owner for a directory can be set using the setuid and setgid commands. Once one of these commands has been used on a directory, I'm not sure how to view the settings for the directory though. How do I check the default group or user owner for a directory?

I have access to a terminal session as root, through WHM.

Thanks!
0
Hi there. If I type in 'social media optimization tips' into Google, my site is in the featured snippet at the top but the image/icon in it is a competing site. Any ideas on why that is happening and how to fix it? I use to have my own logo up there but not anymore.  I've uploaded a screenshot.

Any ideas experts?
screenshot-of-wrong-image.jpg
0
Creating a wordpress theme site.  I have an image. I want the image to take up the whole page. I also want to put links on the image.

I have two images below.  The current which is what I'm trying to upload and display in it's entirety and the end result which is what I want it to look like where each word would go to a different page.

Current
End Result
0
Hello - I was hoping for some help with a CSS issue I am trying to fix - I am developing a wordpress website with the Avada theme and the design calls for these little ribbon shaped mouse overs
I was able to get the ribbon shapes on my menu items but things seems to move around a lot and seem clunky as other menu items seem to jump around on hover - and also trying to fix the active state of the menu item to have the same ribbon effect as the mouse over - Here is a link to preview the issue - http://carrolldistrib.wpengine.com/our-community/ - Any help overwriting the menu css that the theme is using to make these main menu highlights not jump around on hover and fix the active state of the menu items would be much appreciated
0
Hi Guys, on my site here https://bodyfirstpreppd.ie i am removing the local store pickup option but when you go through the ordering process at the end there is a little pop up menu that mentions the shipping options that i want to remove, i think i have found the code here on line 146.

If i want to disable it, what part of the code should i remove?

<?php
/**
 * Header template.
 *
 * @package Avada
 * @subpackage Templates
 */

// Do not allow directly accessing this file.
if ( ! defined( 'ABSPATH' ) ) {
	exit( 'Direct script access denied.' );
}
?>
<!DOCTYPE html>
<html class="<?php echo ( Avada()->settings->get( 'smooth_scrolling' ) ) ? 'no-overflow-y' : ''; ?>" <?php language_attributes(); ?>>
<head>
	<meta http-equiv="X-UA-Compatible" content="IE=edge" />
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <link rel="stylesheet" href="<?=site_url(); ?>/wp-content/themes/preppd/prep.css" />
	<?php Avada()->head->the_viewport(); ?>

	<?php wp_head(); ?>
<script defer src="https://use.fontawesome.com/releases/v5.0.8/js/all.js"></script>
	<?php $object_id = get_queried_object_id(); ?>
	<?php $c_page_id = Avada()->fusion_library->get_page_id(); ?>



	<?php
	/**
	 *
	 * The settings below are not sanitized.
	 * In order to be able to take advantage of this,
	 * a user would have to gain access to the database
	 * in which case this is the least on your worries.
	 */
	echo Avada()->settings->get( 'google_analytics' ); // WPCS: XSS ok.
	echo 

Open in new window

0
WordPress SMTP plugin.  Can any expert recommend a good / free SMTP plugin?  My site is having some issues with sending email. Thank you in advance and happy holidays.
0
I have a friend who runs an antique store, and they regularly takes images on their mobile phone and uploads them to their Facebook business page.
They also have an ecommerce website built with Wordpress and uses Woocommerce.

They are looking for an easy way to keep their website shop up to date directly from their mobile phone.

Is there a service to connect Facebook images and convert them to woocommerce products?

Any suggestions on the best way to keep their website up to date easily from just their phone?
0
I purchased wpforms to try to create an application form and would like to be able to have a type of matrix so to speak. I am required to make an online job application form  where i need to has the applicant to fill out multiple lines for previous employers and levels of educations. Any thoughts on how to do it. the wpforms seems to not be able to accommodate.
0
Hi Experts,
For the website www.Nutrimedical.gr, which is a food supplement eshop and runs WooCommerce, some warnings are occurring for all the products in Google’s Structured tool https://search.google.com/structured-data/testing-tool.

Some examples:
When we test these products with Google’s tool[/url], two warnings are coming up.
a) https://www.nutrimedical.gr/product/happy-tummy-σταγόνες-για-κολικούς/ which is a supplement for colic infants)[/url]

1. Missing field "review"
2. No global identifier provided (e.g., gtin, mpn, isbn)

For (1) [embed=file 1437960] the review tab exists and it has also one written review [embed=file 1437963]
For (2) the warning is correct because no global identifier provided

b) Second product, https://www.nutrimedical.gr/product/actibutir-ευερέθιστο-έντερο/ a supplement to counteract abdominal pain symptoms[/url]

Again, the same two warnings are coming up but now both fields are normally presented [embed=file 1437962]


[u]As I can understand, Google cannot correctly crawl the pages as we can understand from the above results[/u]

[b]My questions are:
[list]How to edit the structured data in product pages (Wordpress) so that the pages can be crawled correctly?[/b][/list]
[list]Can these warnings be fixed or it's the theme's fault?[/b][/list]


Thank you
[embed=doc 1437960]
[embed=doc 1437962]
[embed=doc 1437963]
0
The drop down menu on a WordPress website is no longer functioning. I've checked the plugins, but nothing immediate pops out at me. Grateful for some help.
ccw-desi-website-menu.png
0
I need to find a way to find all topics and replies a particular user has put in my BBpress forum. I am aware of the UserInsights plugin but I don't need all of that capability.  Nor, do I want to pay that much every year.  When I had a different forum it was a default to see all of the topics and replies a user had participated in.

I am running version 2.6.1 BBpress and version 5.4 Wordpress.

Thanks,
0
jQuery UI Autocomplete integration with Wordpress.

I have been working on integrating jQuery UI Autocomplete within my wordpress theme. I have been following this guide: https://gabrieleromanato.name/adding-jquery-ui-autocomplete-to-the-wordpress-search-form

--

Currently it is working as intended, I have on search the right results, and with them being able to log in the right div. But along with the post_title I want to fetch the posts custom taxonomy 'services_cat' - So then I can separate my search results within these categories. At the moment my below code will show the results all with the EXACT same category. So it's not actually pulling the posts right category, it's just pulling what I assume is first in the list.

Here is my code.

jQuery
(function( $ ) {
	$(function() {
		var url = MyAutocomplete.url + "?action=my_search";
		
		function split( val ) {
      return val.split( /,\s*/ );
    }
    function extractLast( term ) {
      return split( term ).pop();
    }
    function log( message ) {
      $( "<div>" ).text( message ).prependTo( ".selected-results" );
      $( ".selected-results" ).scrollTop( 0 );
    }
		
		$( "#autocomplete" ).autocomplete({
			source: url,
			appendTo: ".search-results",
      search: function() {
        // custom minLength
        var term = extractLast( this.value );
        if ( term.length < 2 ) {
          return false;
        }
      },
      focus: function() {
        // prevent value inserted on focus
   

Open in new window

0
hi

I have a wordpress site which was previously running on Apache and MYSQL.

I have had to move the site onto IIS7.5 with MySQL for Windows.

The site is running and the wp-admin area is fine but when ititially loading the site its taking approx 10 seconds to display the page, even locally on the server.

Once the site has loaded to seems to function ok.

Any idea?

thanks
0
Hello everyone. I am looking for a way to send automated emails a certain time after an appointment to follow up with clients.  Ideally it would be free...

Here is my situation:

Clients schedule appointments with me on (Square).  If I accept their appointment, the appointment gets stored on my Square calendar. Those appointments sync automatically with my Google calendar, and eventually sync (using GSync-it) from my Google calendar to my Outlook Calendar at work (Exchange). Outlook is the client that I use most often to see my entire schedule.

What I am looking for is some application that can automatically send pre-written emails to clients at certain intervals following a scheduled appointment. The first, a couple of days later, then maybe another one a few weeks later.  I see web-based scheduling services online that can do it, but i would like to stay with Square because it is free, and seems to be working fine.

I am thinking that maybe a MAPI addin to Outlook/Exchange could offer this type of functionality for appointments that I "tag".  But if I can do it through Google Calendar or Square, I will try that. Any ideas?

Thanks very much,
Kevin
0
Trying to move a website -- same domain though -- xxxxx.com/Wordpress is the developmental site, new site at a new host is: xxxxx.com only. I can't get a redirect to work, not sure what is missing. I am using web tool redirection plugin  -- since the old web site is the same domain, I am not sure what to do? Any direction.
0
I'm working with a small company that runs a website with an e-commerce system running in the Laravel framework with the rest of the site running in WordPress. Now I want to take a copy of all of this so that I can work on stuff without affecting the production site. Naturally there is no existing dev area. This was all set up for them by a 3rd party who have effectively run away and refuse to answer any calls or emails. I've created a VM running Ubuntu 18.04, Laravel (5.7 I think) MariaDB Apache2 and PHP7.2. I can (and have) taken a backup copy of the WordPress items that I can install onto the VM using the Duplicator Pro plugin. I've tested this on the VM and know that I can expand everything there and having done so I can at least rung the CMS side of WP although seeing the actual web pages is difficult.

I need to get this running partly because I may need to move from the existing hosting arrangement so want to use this as a sort of trial run in addition to creating a dev setup. My question is what do I need to do to get this working? Do I need to make changes in the Laravel set up? It's still got the "your-project" folder where I've put things like phpminiadmin.php (like phpMyAdmin but just one page) so I know that all the bits are running. Can I get away with just duplicating the file and folder structure of the production site and then run the Duplicator Pro installer script to set up the site? Am I being too naïve here? :-)
0
I have a login screen with user pro word press plugin.
after i enter username and password and press login button, nothing happens, it shows the same page.
please provide suggestions on why this is happening.
login-issues.jpg
0

WordPress

WordPress is a free and open-source content management system (CMS) based on PHP and MySQL for creating websites and blogs. Features include a plugin architecture, a template system and strong management, customization and search systems; through its dynamic presentation of content, webmasters have the flexibility to create websites easily.