Sean Davis
Forum Replies Created
-
Hi @fabgan,
I’m not 100% sure how you envision the “with related categories and sub-categories” part of the display, but you can easily display downloads using the
[downloads]
shortcode described here: https://docs.easydigitaldownloads.com/article/224-downloadsThat’s going to display all of your downloads, regardless of category. But you can use the shortcode’s attributes to specify which categories to show.
Please have a look at that documentation. If there’s a more specific type of display you’re thinking about, just let me know and I may be able to point you in the right direction.
No problem at all!
@behroozdanta
1 – Use
edd_get_total_sales()
: https://github.com/easydigitaldownloads/easy-digital-downloads/blob/master/includes/payments/functions.php#L825$sales = edd_get_total_sales(); echo $sales;
2 – We don’t have a function specifically for that so you’ll have to develop something custom. I don’t think it would be too difficult, though.
Try looping through all Downloads, checking what each one returns for
edd_get_download_sales_stats( $download_id )
: https://github.com/easydigitaldownloads/easy-digital-downloads/blob/b3b09b718d04ded5611b8b34194cbb77190a2c47/includes/download-functions.php#L593 If any number of sales are returned for a download, increment by one until you’ve checked them all.Hi Behrooz,
I’m not quite sure I understand. Are you saying you’re just trying to get the total number of sales for all Downloads in your store? Or the number of Downloads that have sold at least once?
Your code is not in line with how I’m interpreting your question. So if you could provide just a bit more detail (no code) about what you’re trying to retrieve, I may be able to point you in the right direction.
Thanks!
Great! Glad to hear it’s all sorted out now.
I assume the log you’re referring to is the SparkPost log? If no, can you go to Settings -> SparkPost -> Overrides (tab) in your WordPress admin, and check/save the Email Logging settings. Then go to the Email Logs tab to view the email logs. After trying another test EDD purchase, both the purchase receipt and admin notifications will show up there.
For those, is there anything in the “Response Data” column? If so, what response did you get for both emails?
Hi there,
That’s interesting indeed. I have not used Sparkpost before but I’m going to check with the team to see who has. I’ll see if we can replicate.
Considering the email shows up in the log and there’s no error, please go ahead and make sure the emails aren’t in your spam folder or anything similar.
I’ll reach out again shortly. Thanks for your patience!
I’m going to go ahead and close this ticket so we can continue over on GitHub. We’ll wait for your reply there. Thanks!
Hey there,
If you’ve got some dev experience, we’re troubleshooting over on GitHub: https://github.com/easydigitaldownloads/easy-digital-downloads/issues/6952
We aren’t able to replicate at the moment, attempting to do so on the same MySQL version that you are on. No luck. It’s possible that other elements in your environment are part of the issue. So when you get a chance, please work with us either here or over on the GitHub issue to provide more details about your environment.
Thanks!
In the mean time, can you let me know what version of WordPress, PHP, and Easy Digital Downloads you are on? Please provide all three.
Hi there,
Sorry for the slow delayed reply.
I’m forwarding this to one of our lead developers to have a look. We’ll be in touch with you again shortly.
Thanks!
Hi there,
Sorry for the slow reply here. In the ‘Logging sent emails in WordPress’ section of the doc you linked, we refer to email logging tools. Though your email are not properly sending, it’s possible that the intent to send the email is recognized there.
Have you configured any logging tool yet? If not, can you give that a try and let me know if any reference to the EDD emails show up in there?
Thanks!
Outstanding. We’re here if you run into anymore issues.
No, browser tools have no affect on the actual site. My browser doesn’t have access to your site itself, only the elements that can be seen on the screen. I can manipulate them in my view. A page refresh on my end erases all of my temporary changes.
You can right click right now on this very screen, click the option related to the word “Inspect” or “Inspector”, and see the HTML and CSS that makes up the page you’re viewing. It’s just a browser tool to see how a page is structured, styled, and other things. Developers use it to see how changes will look before actually making them on the real site.
I’m not sure what happened to your site, but it sounds like something is going wrong at the server level. Your site depends on a database to pull data from, and your database connection is failing.
Contact your host immediately and report the issue. They should be able to track it down in seconds.
No worries. There are browser tools that allow me to see the issue without a refresh.
It actually looks like you have other CSS in the way that’s causing an issue. Line 976 of your style.css file located here: view-source:https://beaconpointservices.org/wp-content/themes/bp/style.css?ver=4.9.8 That file appears to be in the root of a theme with a folder called “bp”.
The CSS rule located on that line (976) looks to (I can only take an educated guess) apply to all links
:not()
specified there. It appears to be intentionally excluding elements that are included in your theme, perhaps? In other words, that CSS rule does not intentionally exclude EDD buttons (or any other buttons for that matter), so the CSS written there applies to EDD’s buttons… interfering with the changes you’re trying to make.Here’s a screenshot of what it looks like when I disable the CSS targeted by line 976: https://cl.ly/5cfb18b99b2b
I’m not sure if that CSS is custom, or if it came in the theme you’re using, so written by someone else. But the act of using
:not()
in the CSS selector to exclude certain types of links, as opposed to writing CSS that targets the links you actually want to target, can always lead to unexpected results like this. Because you have no way of predicting what HTML elements will be introduced in the future by other plugins, or even WordPress itself.—–
Here’s what you can do, though, to solve the issue in just a couple of steps:
Step 1
On that same line 976 in the CSS file, change this:
a:not([title="1"]):not([title="2"]):not([title="3"]):not([title="4"]):not([title="5"]):not(.btn):not(.nav-link):not(.navbar-brand):not(.ab-item):not(.no-style):not(.dropdown-item):not(.elementor-button-link):not(.nc_tweet)
To this:
a:not([title="1"]):not([title="2"]):not([title="3"]):not([title="4"]):not([title="5"]):not(.btn):not(.nav-link):not(.navbar-brand):not(.ab-item):not(.no-style):not(.dropdown-item):not(.elementor-button-link):not(.nc_tweet):not(.edd-add-to-cart):not(.edd_go_to_checkout)
(all I did was add
:not(.edd-add-to-cart):not(.edd_go_to_checkout)
to the end of the selector)Step 2
Replace that entire chunk of CSS I gave you earlier with this:
.edd-add-to-cart.plain, .entry-content .edd-add-to-cart, .edd-go-to-checkout.plain, .entry-content .edd_go_to_checkout { background-color: #564865; border: none; color: #ffffff; text-align: center; text-decoration: none; padding: 15px 32px; font-size: 16px; cursor: pointer; }
(all I did was change
.edd-go-to-checkout
to.edd_go_to_checkout
… my mistake)That should have everything looking the way you want and functioning as expected, as it transitions from an Add to Cart button to a Checkout button. I tried to use my browser to check but it appears your site started experiencing an error while I was trying to use the browser tools.
Please give it a test and let me know.