The server-side programming language that the WordPress core, plugins and themes are written in.

learn more… | top users | synonyms (1)

-1
votes
2answers
6 views

Upload images and attachments from frontend form

I'm not very expert of wordpress and I'm trying to create a frontend form sending information to my php function through ajax. I'd need help about uploading images and files as attachments of the ...
1
vote
1answer
28 views

Is there a way to get 3+ dimensional array from a single MySql command

For example an array that has all the months, inside each month are all the users registered that month, and details on every user. I could solve it by simply searching for all users registered this ...
-1
votes
1answer
19 views

WooCommerce - Getting variation ID from attribute values

I am building a WooCommerce store and am adding variable products to the cart programmatically after submission of a Gravity Form. I am getting the data from the form and includes the product_idas ...
-3
votes
0answers
31 views

Changing Pagination Numbering in Genesis Framework [closed]

Due to some requirements in the content I publish on my website, I need to change the pagination numbering from 1 2 3 4 to 0 1 2 3. I need to find a way to decrease the ID of the paginations to ...
2
votes
1answer
846 views

Crop image from get_theme_mod Customizer field

I'm using the following code to allow a user to upload a custom image (in addition to header image) through the customizer. Is there a way to crop the image when displaying it? ...
0
votes
1answer
30 views

Integrating WordPress to my website, while keeping my own authentication system

I've recently integrated WordPress to my website and I've been trying to find out the correct way to replace Wordpress' authentication system with the one on my website. My website already has a user ...
1
vote
0answers
12 views

wp attempt focus, disabling without touching core

So i've added an extra field to the login form. I have used js to place it at the top. However, whatever I do I don't seem to be able to change the tabindex(or start focus for that matter. Is there a ...
0
votes
1answer
13 views

Adding an interior 'hero' area with some added php title customization

Ok here it goes. I hope Im at the right place. Sorry if this has been answered I looked over on the regular SO but couldn't find an answer. I'm currently building WP site that has a slider area on ...
1
vote
2answers
1k views

Execute a shortcode when clicking on a image

I asked this in stackovorflow under javascript and was informed not possible so I trying here I have a shortcode for a opt-in form and I want it to pop up when a image is clicked I tried the ...
-2
votes
0answers
11 views

Latest news not showing in category page, but showing in home and other pages except category page [on hold]

<ul> <?php $parameter = array( 'numberposts' => '5','post_type' => 'college_notification' ); $recent_posts = wp_get_recent_posts( $parameter ); ...
-1
votes
0answers
12 views

Customizing The Events Calendar, with Avada template [on hold]

So we are trying to incorporate banner ads into the events calendar so when you view a list of all the events on for a certain day/time etc there is an ad every x events. Specifically we would like to ...
0
votes
0answers
15 views

Automatically require PHP files causing error in wp-admin

I have been using this function to automatically require in PHP files. function req_php_files($filepath) { $Directory = new RecursiveDirectoryIterator($filepath); $Iterator = new ...
0
votes
1answer
11 views

How do I routinely extract the thumbnail of the most recent post?

I would like to write a PHP snippet that can communicate with Wordpress. When a new post is published, a file today.jpg will be generated from the thumbnail url (a custom field) of the most recent ...
0
votes
1answer
23 views

PHP getting error when trying to access WP-Admin Dashboard

I'm unable to get into the backend of my site, and it's throwing the error Warning: ...
0
votes
0answers
19 views

Locked out of Admin account, unable to access php database and unaware of email used to create site [on hold]

As you can see by the title I have been caught in Wordpress limbo. I had access to the admin account on sitename.com/wp-admin through username and password. However after adding a plugin the account ...
0
votes
0answers
16 views

Hide empty categories from get_categories

I'm trying to hide the empty categories (with no posts associated) from a list in an archive page. I'm using hide_empty as suggested on Wordpress codex but it's not working, the code outputs all ...
-1
votes
0answers
7 views

need help in custom single product woocommerce [on hold]

can change destitute variation attribute field in single product woocommerce form one column vertical to two or three columns? as attach file
-1
votes
0answers
10 views

ACF flexible content repeater [on hold]

I'm having trouble inserting a repeater within a block of flexible content, have tried a few different ways but it breaks each time. Am able to keep creating new blocks like the callout-panel but as ...
0
votes
2answers
2k views

How to exclude specific category from the get_the_category(); array

In my loop I've added: <?php $categories = get_the_category(); $separator = ' '; $output = ''; if($categories){ foreach($categories as $category) { $output .= '<span ...
0
votes
0answers
22 views

How to stop printing header, footer, sidebar and other items (Tesseract theme)?

My screen pages look fine. All elements on a page look like they will print on one page. When the page prints, the header, menu (drop down), footer, social media icons at bottom (also showing link ...
1
vote
2answers
546 views

Remove price from Woocommerce variable product dropdown menu

I'm trying to hidden or remove the price on each variable products inside dropdown menu on a single product page. Please see image attached below. I believe here is the codes that needs to be ...
-3
votes
0answers
15 views

How can I show last 10 post with JSON and PHP? [on hold]

Firstly, I'am sorry for my bad English. I want to show my last 10 post with PHP from my JSON. I made a PHP page and I get some errors. I fixed some but an error comes again. If you had an alternative ...
0
votes
1answer
550 views

Save custom meta box data to database

I have a custom post type Events. Under Events, I have a custom meta box which selects the time and data of the event: <?php $meta_boxes[] = array( 'id' => 'event_date_option', 'title' ...
0
votes
0answers
24 views

Adding a query string to product links

I need to add a query string to the end of the links generated by a [products] shortcode from WooCommerce. Each product appears with three links. The image, the title and the add-to-cart button. I ...
3
votes
1answer
86 views

Retrieve POST data from AJAX call

I have the following JS script : jQuery('#form-recherche').submit(ajaxSubmit); function ajaxSubmit(){ var newFormRecherche = jQuery(this).serialize(); jQuery.ajax({ ...
0
votes
1answer
26 views

How to order users alphabetically by name? in plugin UPME

I have this code: <?php class UPME_List_Cards { public $upme_options; public function __construct() { global $upme; add_shortcode('upme_latest_members_list', ...
0
votes
1answer
435 views

Wordpress GET parameters causing 404 Not Found

all, I'm having a problem with my wordpress page while using encrypted $_GET parameters to obtain data. this is my function: function encryptDecrypt($key, $string, $decrypt) { if($decrypt) { ...
0
votes
1answer
768 views

Sort posts by custom fields value using dropdown menu

I'm trying to sort my posts by a custom field value, called price. Only using numbers in the custom field value. I want that the visitors of the website can sort the posts on price by using a ...
0
votes
1answer
16 views

Wp_mail doesnt work

I created a form for mail sending, but it does not work. Email function is enabled in php. if (!$error_msg) { $to = "mail@to.send"; $headers[] = 'Content-Type: text/html; charset=UTF-8'; ...
0
votes
2answers
31 views

Get Custom URL For Custom Taxonomy

I've got a custom post type called productpopups, and to sort them I have a custom taxonomy called productcategory. The post type has it's own special template (single-productpopup.php) and I'm trying ...
0
votes
1answer
13 views

get_page_templates only return templates with “home” in the filename

I have the following custom page template filenames: template-about-1.php template-about-2.php template-home-1.php template-home-2.php I have this function to get_page_templates: function ...
0
votes
0answers
20 views

Allow one use group to manage another

I have a website where members and their managers have accounts. The members can create and upload their content, but the managers have their own login and can see a list of the members they manage. ...
0
votes
0answers
25 views

Blank screen on wp-admin

I know this question has been asked tons of times but it was all outdated; I tried every single thing and it still doesn't work. Here is what I tried so far: Renaming the folder Renaming plugins ...
0
votes
1answer
442 views

TCPDF get_post_meta outside the loop

I want to be able to export a html page to PDF. I downloaded TCPDF (mainly because it allows me save High resolution images and shrinks the filesize.) The TCPDF folder is in my theme folder. If a ...
0
votes
1answer
25 views

Post order in layout (css problem?)

I made the layout for blog and styled each post in block. I have problem with display order of post. I use standard loop: <?php query_posts('cat=317&showposts=6'); ?> <?php if ( ...
2
votes
1answer
1k views

Using PHP to toggle stylesheet and header image, set in cookie

I haven't done a lot of work with cookies or Wordpress before so I think I've been a bit over-optimistic in my quest :p I have created two themes for my site, night and day. I would like the user to ...
1
vote
1answer
2k views

Fatal Error relating to sessions.php

here is the error code I have Warning: Unterminated comment starting line 2079 in /home/teamspor/public_html/wp-includes/user.php on line 2079 Warning: ...
0
votes
1answer
22 views

How can I use a text and a function php

I want to display a text and a function in same sentence: <?php echo 'Right sidebar'; ?> <?php echo the_content(); ?> Something like this: <?php echo 'Right sidebar' the_content(); ...
0
votes
1answer
71 views

Integrating PHP into Javascript to display map markers with Google API

I am getting one map marker to display but not multiple markers. However the data displays in the HTML log. I think I am missing a loop or did not use my current loop correctly. Anyone who could ...
0
votes
2answers
106 views

How to overwrite orderby with add_query_var

So I would like to have an archive that displays its posts in a random order. <?php $query = new WP_Query($query_string."&orderby=rand"); ?> But also then if the user chooses they ...
0
votes
0answers
28 views

Make shortcode work in all posts displayed by loop, not just the first one

I have a post archive displaying post and author meta at roadtripsharing.com/road_trip I added a do_shortcode(); in the loop, specifically related to the "New Message" button which opens a dialogue ...
0
votes
0answers
16 views

Custom database query with accents returning no results

I have an issue where using accents in my custom database query (wpdb) returns no results. $wpdb->get_results( "SELECT * FROM table WHERE city = 'Montréal'" ); Returns nothing, while ...
0
votes
1answer
14 views

change “missing attachment” text functions.php

The wordpress core file : post-template.php as this text "missing attachment" that i want to change with "-" ..the problem is that when wordpress upgrades the file is changed back to the old "missing ...
1
vote
1answer
2k views

Woocommerce displaying product categories and products on custom theme

Am trying to create custom Woocommerce supporting theme in Wordpress. What am facing is regarding the displaying of Product Categories when accessing the main category and 1st level of categories. ...
0
votes
0answers
22 views

function to write the output of a variable + post_title in post_content

I have a function that writes the output of a function of a rand_keys + the post_title in post_content, but writing the title but only happens after I click manually on the update button on the ...
0
votes
1answer
16 views

Create page in templates for pages or the pages manager?

In terms of slowness and loading which differences noted in the pages created as a template and created by adminisrtador? Example template page: <?php /** Template Name: My Page name */ ...
0
votes
2answers
635 views

Get unique post in parent category

I have a parent category and several child categories. I also have several posts that belong to the child categories. Each post can be belong to several categories. I want to know how to query the ...
0
votes
0answers
43 views

Adding read more function through wordpress

First of all. I know wordpress has a read more function but that won't work either. Probably the same issue that's stopping me in the following. So i'm trying to create a read more function on my ...
1
vote
1answer
637 views

Theme Options Page - User Updates Logo

I'm a newbie to WordPress Development so bear with me. Site: https://wordpress-portfolio-zacnespral21.c9.io/ On the site above I would like to add an option in the themes options page for the user ...
0
votes
1answer
458 views

Custom HTML structure in wp_list_categories

I am trying to accomplish an Ajax navigation for the categories and for that I need the code to look something like: <ul> <li data-level="1">Parent Category</li> <li ...