792 reputation
718
bio website visztpeter.me
location
age
visits member for 3 years, 9 months
seen Apr 23 at 20:43

Nov
22
comment upload images on front by user using form
See my updated answer. The only issue is with the media library folder. I think if the user will see the wordpress uploader modal window, its fine, we just need to find a way to hide the media library tab, so they don't have access to the already uploaded photos. I'm currently looking into this, i'll post an update if i found something.
Nov
6
comment Elegant way to signify inheritance and relationship between posts
If i understand your question correctly, the 2 segments are a part if the complete show and you can only access the complete show from the frontend right? When you click on it, on the same page it will show the 2 additional segments. So if this is the case then you really don't need to create new posts for the segments.
Nov
6
comment Retrieve featured image as object
Well, usually you only need 1 size. You can use Advanced Custom Fields with the image field which will retrieve a full array with all sizes, but if you place the function i wrote inside your functions.php, its not that complicated.
Nov
6
comment Elegant way to signify inheritance and relationship between posts
I think its much easier to use custom fields to store the segments. The best plugin to use is Advanced Custom Fields PRO(or buy the separate Repeater addon), or you can use the free alternative called Simple Fields and look for also the repeater function.
Nov
4
comment How can add posts without category into category
You can rename the Uncategorized category to News?
Oct
28
comment Order get_users() by last login date. Is it possible?
Thanks, answer updated.
Jul
6
comment Posts to expire (deleted) after a date
How many coupons do you have? it should't be too slow, since its only going to run once a day.
Jul
6
comment Populate custom field on publish or update
in your theme's functions.php file
Jul
6
comment Posts to expire (deleted) after a date
Oh boy...:) You need some experience with WordPress to do something like this. But the code goes inside your theme's function.php file or create a plugin for it. How and where do you registered the coupon post type for the Coupons?
Jul
6
comment Posts to expire (deleted) after a date
The 3 example you showed in the question will work with strtotime, but its not fool-proof. The problem is that 01/12/2014 could be december 1. or january 12, nobody knows 100% sure.
Jul
6
comment Custom widget not appearing on front end
Also, looks like the widget appears on the other pages on the site, correct?
Jul
6
comment Custom widget not appearing on front end
First, theres a html syntax error with this, the widget that will be generated is inside a div, and you're trying to display the widget inside a paragraph tag, which is not going to work properly. In short, a paragraph element may not contain other block elements. So change <p class="opening-hours"> to <div class="opening-hours">
May
15
comment Dump contents of a variable inside a filter/hook callback that runs during save post
The filter probably runs in the background, so if you don't stop the function using die(), the var_dump still works, you just can't see it.
May
15
comment Getting page ID inside loop
Use a regular include instead of the get_template_part: include(locate_template('content-custom.php')); This way the variables are passed, so you can re-use them in your template.
May
15
comment Custom user fields validation on registration
The ajax_register_form() function is only hooked to an ajax-request, so the form data is not processed with a regular submit, only if the ajax works. I would suggest you to fix the ajax form submission first, or else you need to edit the ajax_register_form function to work with regular forms which would take more effort to do in my opinion. You can test it by changing the first add_action( 'wp_ajax_nopriv_ajax_register_form'... line to add_action( 'init'..., this will submit your form properly, but make sure you have a conditional logic in your function so it won't run always
May
15
comment Getting page ID inside loop
Simply define a variable outside your custom loop for your current post id that you can re-use later
May
12
comment Change id=“respond” to the comments container
I don't see any filter to change this, so i think the easiest solution is to wrap your comment_form() function in a div with a specific id. <div id="respond-1"><?php comment_form(); ?></div>
May
2
comment Get Tag Slugs that start with a word
Check the updated answer for a solution that works better when you have lots of tags
May
1
comment wordpress option page data from select form is not saving to database
Are you sure its not saved correctly? Try print_r on the $options variable.Maybe the selected() function is not working properly.
Apr
11
comment Open first link in subnavigation when clicking top navigation
Simply add the Pizza sub navigation as the main menu item and rename it to Food