stml
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: “more tag” not working on updated blog, custom theme…@thatruth2006 I’m not sure that makes sense… the_content() is in use on all these templates – it certainly has *something* to do with index.php…
This problem is still occurring – no solution found as yet…
Forum: Fixing WordPress
In reply to: “more tag” not working on updated blog, custom theme…Yes, I’ve tried deactivating all plugins. It’s definitely not a plugin issue.
Forum: Fixing WordPress
In reply to: Disable Comments RSS Feed in wp_headI wrote a quick plugin that does this. Copy and paste the following into a file called stml_beheader.php in your plugins folder and activate.
//////////////////////////////////////////
<?php
/*
Plugin Name: STML Beheader
Description: Removes unneccesary stuff from wp_head
Author: James Bridle
Version: 1.0
Author URI: https://shorttermmemoryloss.com*/
remove_action( ‘wp_head’, ‘feed_links_extra’, 3 );
?>//////////////////////////////////////////
You can remove other unwanted stuff as well by adding lines like:
remove_action(‘wp_head’, ‘wlwmanifest_link’);
remove_action(‘wp_head’, ‘rsd_link’);Hope that works for you.
Forum: Fixing WordPress
In reply to: 404 page not showingI had this problem, and it did appear to be caused by setting a static front page. Setting a specific posts page as well fixed it.
Forum: Fixing WordPress
In reply to: WP hacked, Ads added to Google cacheTo clarify, this has nothing to do with the theme in use.
Forum: Fixing WordPress
In reply to: WP hacked, Ads added to Google cachewp_footer() is completely legitimate. I was using a custom theme, but always leave wp_footer() in in case it is required at some point.
While it wasn’t in this case, and I could remove it, the problem is not with wp_footer() but the malicious code that was being inserted by it, and working out where this code is, and how it got there, is the primary concern.
Forum: Fixing WordPress
In reply to: I was hackedThis hack is quite seriously widespread, in that I’m noticing it quite regularly in blog results from Google (as per my tweet someone has posted above), now others have noticed in Yahoo.
There seems to be little info about it on the web – is it time some more senior Devs looked at this a little more closely?
Forum: Fixing WordPress
In reply to: WordPress redirecting legitimate directoriesStill haven’t figured this out.
This solution does not work for me either: https://www.ads-software.com/support/topic/126593
Forum: Fixing WordPress
In reply to: WordPress redirecting legitimate directoriesNo, nothing there is called lists. And I’ve tried renaming the directory to lots of other things, in any case.
Forum: Developing with WordPress
In reply to: Tags being used as categories by WPI put in that ‘massive WP fan’ comment to deflect those replies! I’m aware bugs will creep in – what I’m saying is that I’m surprised that tags were implemented in a way that this could happen. It’s criticism, not an attack.
Have joined wp-testers as I implement on average a couple of WP installs a month, and do want to give something back…
Forum: Developing with WordPress
In reply to: Tags being used as categories by WPGood to know, and thanks for the info. I’m not going to edit the core, but this seems like a pretty serious thing to me, and I’m surprised it’s possible to confuse tags and categories this easily… it suggests all the implications of adding tags to WP haven’t been fully thought out.
(I speak as a massive WP fan…)
Forum: Themes and Templates
In reply to: Custom Fields and Custom TemplatesNote that I still had to reset $post_ID in order to use it in the sidebar after running query_posts:
<?php /* Template Name: News */ ?> <?php get_header(); $newsid = $post->ID; ?> <h2 class="storytitle">News</h2> <div class="storycontent"> <?php query_posts('showposts=10'); global $more; $more = 0; while (have_posts()) : the_post(); ?> <h3><?php the_time('j/m/y'); ?>: <a>" alt="Read this article..."><?php the_title(); ?></a></h3> <?php the_content(__('(Read more...)')); ?> <?php endwhile; ?> </div> <?php $post->ID = $newsid; ?> <?php get_footer(); ?>
Forum: Themes and Templates
In reply to: Custom Fields and Custom TemplatesIt wasn’t a variable/scoping problem – the problem was in my sidebar:
<div id="sidebar"> <h1><span class="smname">Stephenie Meyer</span> </h1> <div id="sidebar_content"> <?php if ( is_page() && comments_open() ) { comments_template(); } else { echo ''.get_post_meta($post->ID, sidebar, true).' '; } ?> </div> </div>
Because I wasn’t using a loop, the if query couldn’t understand comments_open() – by adding is_page() as well, I forced it to ignore this on query_posts pages.
Forum: Themes and Templates
In reply to: Custom Fields and Custom TemplatesOK, have now updated my news.php to this:
<?php /* Template Name: News */ ?> <?php get_header(); $newsid = $post->ID; ?> <h2 class="storytitle">News</h2> <div class="storycontent"> <?php query_posts('showposts=10'); global $more; $more = 0; while (have_posts()) : the_post(); ?> <h3><?php the_time('j/m/y'); ?>: <a href="<?php the_permalink(); ?>" alt="Read this article..."><?php the_title(); ?></a></h3> <?php the_content(__('(Read more...)')); ?> <?php endwhile; ?> </div> <?php $post->ID = $newsid; echo $post->ID; ?> <?php get_footer(); ?>
As you can see, I’m currently echoing the post ID at the end to test it – it shows the correct ID.
I also echo it in the sidebar, to double-check – and it’s still the correct ID.
However, the get_post_meta($post->ID, sidebar, true) still is not working – nothing happens! If I place it at the bottom of news.php, it prints the correct field content, but refuses to do so in the sidebar – even though it’s being passed the correct ID!
Forum: Themes and Templates
In reply to: Custom Fields and Custom TemplatesOK – can confirm that this method is passing the ID of the last post displayed by query_posts to the sidebar, not the ID of the originating page.
Anyone know how I can get around this?