Jurre
Forum Replies Created
-
Forum: Hacks
In reply to: Using the flash uploaderThank you. I can definitely use that as a starting point.
Forum: Themes and Templates
In reply to: child theme or not ??It depends on your theme.
Forum: Hacks
In reply to: if and statement with custom fieldsYou are missing the final )’s in your calls to get_post_meta(). I suggest you use a proper editor which can highlight simple mistakes such as these.
Also, you cannot check for equality with = as it is the assignment operator. Use == instead.
On a side note, I hate the syntax with the :… just use { }. Much prettier ??
Forum: Fixing WordPress
In reply to: Modify the loop on single post…From what I can understand from the given piece of code, I think the following would probably be a solution.
Try changing this line:
<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
To this:
<?php $my_query = new WP_Query(); $my_query->query(); if($my_query->have_posts()): while($my_query->have_posts()): $my_query->the_post(); ?>
You may want to pass some parameters to the query() function to control which and how many posts are shown, information on the available parameters can be found here.
?>Forum: Plugins
In reply to: Make upload on my widgetHi,
I am currently facing the same problem. Did you (or anyone else) solve this issue?
Forum: Fixing WordPress
In reply to: Modify the loop on single post…You can create a new WP_Query object and use that in a secondary loop to query all posts and display the gallery.
Something like
$my_query = new WP_Query; $my_query->query(array('cat' => 1)); while($my_query->have_posts()) { $my_query->the_post(); // the_title(); and all the usual stuff goes here }
Forum: Plugins
In reply to: post_updated hook missing argumentsNever mind
I completely failed to check the documentation for add_action(). The solution was, of course, to set $accepted_args to 3.Not the most intuitive behavior I’m afraid, but it works now.
Forum: Themes and Templates
In reply to: Margin-bottom @ thumbnail in post loopTry giving the <img> a display: block.
Forum: Fixing WordPress
In reply to: blank page after login via admin.phpIf you have actived any non-standard plugins or themes, disable them by deleting the files.
Also, try taking a look in your server’s error logs. This could shed some light on the issue. Where these can be found is dependent on your server setup or hosting provider, but usually they can be found somewhere in your hoster’s control panel (DirectAdmin, Plesk, etc).
Forum: Plugins
In reply to: update_post_meta: data gets overwritten when uploading a fileI simply added a member variable $this->submitted that gets set to true when the data has been saved.
Forum: Plugins
In reply to: update_post_meta: data gets overwritten when uploading a fileAs usual, I solved my own problem. Turns out WordPress’s save_post hook gets called twice by default (why? it’s not in the codex). The second time it ran my submit function the upload would fail and update the post meta with the empty string.