RL
Forum Replies Created
-
Forum: Plugins
In reply to: [Event Tickets and Registration] Can’t add quantity after 5.2.4 updateHi @mroesele, thank you for the advice. I actually already done that on the production site but I’m just curious with the latest update, why it doesn’t work, what different setup the site has that could make a pretty obvious thing to not work and I want to fix it quick if possible. ??
@juanfra, I don’t think we’re using the shortcode.
From my understanding, the ticket form in that page is loaded from:
Single Event Template
[your-theme]/tribe-events/single-event.php…which loads:
Block: Tickets
[your-theme]/tribe/tickets/blocks/tickets.phpI tried to delete those two files from the theme folder (so it’ll use the ones in the plugin folder, right?). Then the layout is ruined, but still unable to add quantity – no errors in console.
Any pointer?
Forum: Plugins
In reply to: [Event Tickets and Registration] Can’t add quantity after 5.2.4 updateTo clarify, the page:
https://undostaging.wpengine.com/event/collaboration-and-as-negotiation-documentary-ethics/
… now contains the default ticket template (no more “Register” button as mentioned in my first Post), but the (+) add ticket button is not working.
“Enable New RSVP Experience” & “Enable Updated Tickets Experience” in Settings are checked.
Searched for ‘ticket’ in functions.php and I can’t find anything relevant (Theme wasn’t created by me).
The site has Events Tickets Plus and Events Calendar Pro, should I look into it?
Thank you.
Forum: Plugins
In reply to: [Event Tickets and Registration] Can’t add quantity after 5.2.4 updateOkay, I see this notice in the Troubleshooting page:
EVENT TICKETS
Existing theme overrides that may need revision:
blocks/tickets.php (based on 4.11.0 version)I deleted that file so it don’t override the default file in the plugin folder.
Notice is gone.
The ticket form layout changed (no more Register button, no more modal), but still, nothing happens – also in console – when I click the (+) add quantity button.
Any clues on where should I look next?
Thank you.
- This reply was modified 2 years, 9 months ago by RL.
Forum: Plugins
In reply to: get_attached_file() returns wrong path?I also got
../wp-content/uploads/
from this function. Googled. Found this thread. No solution. Take a closer look, and…I did this:
echo get_attached_file($foo -> ID);
while it should’ve been this:echo get_attached_file($foo[0] -> ID);
.—
$foo = get_posts ('post_type=attachment&post_parent=90'); echo '<pre>' . print_r ($foo, true) . '</pre>';
The 2nd line is very helpful to me on many occasions. :p
Forum: Plugins
In reply to: How to Exclude Pages in Popularity Contest?Somewhere near line #2279, there’s a line like this:
$str .= '<script type="text/javascript">AKPC_IDS += "'.$post->ID.',";</script>';
You can change it into this:
if (!is_page ()){ $str .= '<script type="text/javascript">AKPC_IDS += "'.$post->ID.',";</script>'; }
It’s by assuming that your installation is the same with mine.
With the above code, the “post weight JavaScript adder” will not appear on pages.
To reset the weighs (to test):
- Deactivate plugin
- Drop wp_ak_popularity and wp_ak_popularity_options table from database.
- Activate plugin
—
An update suggestion, post_title output is probably better to be filtered:
apply_filters ('the_title', $post -> post_title)
… so it’ll work with some title modifier plugins such as qTranslate.
Forum: Plugins
In reply to: Custom-sized ThumbnailBtw which is more efficient if we consider server process, bandwidth, bulky code, and possible native create_custom_thumbnail_size() function in the future?
#1: To recreate the resizing functions.
#2: Or to just use the smallest thumbnail size and change the dimension in HTML output? The “stretched/crippled” image will be hardly noticed if it’s small.
??
Forum: Fixing WordPress
In reply to: Turn a Page into a Post ??Hello,
Are you sure this is safe for the latest WordPress (2.8.4)?
I tried it and there seems to be no problem. Forgive me but I just want to be sure. ??
And if we want to convert Post into Page, is it safe to just set the Post into “uncategorized” and change the post_type value to ‘page’?
Thank you!
Forum: Plugins
In reply to: Custom-sized ThumbnailArr!
- Checked that both functions exists (in wp-includes/media.php and wp-admin/includes/image.php)
- Manually include wp-admin/includes/image.php before image_resize() is called in my function (because I thought it’s an “admin only” inclusion)
- Error: Functions in wp-admin/includes/image.php is defined twice (wp-admin/includes/image.php is included twice – and I can’t use include_once() because the second inclusion is after my function is called)
- Recreate image_resize() and wp_load_image() functionality in my function
- Problem solved, inefficiently
I created my function in wp-content/themes/_themename_/functions.php. Don’t know if I will not have this problem or not, if I create my function as a plugin (don’t want to create a plugin because this is a theme-specific function).
I think WordPress should include wp-admin/includes/image.php before including the theme’s functions.php, no?
Forum: Fixing WordPress
In reply to: Images disappearing when alignment is changedSo what do you do now, people?
- Use something other than IE
- Modify the core
- ???
- Profit!!
And can this be considered as WP bugs?
Forum: Plugins
In reply to: Check for login outside WordPressBig problem
the whole path (like in categories, posts) now points to the website root ??
nvm about my post above, silly solution. stick to ed or jenniemai’s above…
Forum: Plugins
In reply to: Check for login outside WordPressI was also having the same problem. After reading many posts including posts in this thread (which some of them works), instead of changing the core files, I tried changing the Blog Address (URI) in General Options, while the WordPress address (URI) remained pointing to the folder where WordPress installed.
It seems to work now (yay!), a test.php page in another folder (not in the root folder) which contains:
require('../blog/wp-blog-header.php');
$user = wp_get_current_user();
echo '<pre>' . print_r ($user, true) . '</pre>';…is now working well on login/logout state.
/blog is the folder where WordPress got installed.
Proceeding with works… I’ll let you people know if this method has any flaw. 0_o
Forum: Everything else WordPress
In reply to: about query optimizationThank you,
alter table wp_post2cat add index category_id (category_id);
I’ll do that.
—
But btw, does WP (default install) really look into the whole row in
wp_post2cat
, when it wants to retrieve posts from just a single category? Is there a reason for this? I mean, it’s hard to believe that no one in the development team realize this “problem”. That’s why I think there might be some kind of “unusual” way in WP’s core to retrieve posts by category, efficiently.Forum: Plugins
In reply to: phpBB and WP sharing login tables?@iduncan thank you ??
I actually just want to use WP’s membership system and some other functionality for another application I made, while also keep using the blog itself… but I found no tutorial like this < https://www.phpbb.com/phpBB/viewtopic.php?t=142506 > for wordpress ??
Or is there any? An easy way to include all user auth & session at the beginning of pages (outside wordpress)? I’m quite a new WP user.
But your workaround is good enough, since I can manually grab any detail from WP tables, and create a single login for both WP and my apps.
Put the iframe on the page that is shown after a successful login ??