Phil Johnston
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: XML RPC File upload?I have another question – on that page it says
“Many scripts in Perl, Python, PHP, Applescript and Java have already been written and are ripe for the picking (and tweaking)”I am looking for one done in PHP that I could work on tweaking and then eventually working into flash. Do you know of any PHP scripts or forms that would work? I can’t seem to find any yet
Thanks
Forum: Fixing WordPress
In reply to: XML RPC File upload?great, thanks for pointing me in the right direction
Forum: Fixing WordPress
In reply to: Howto get substring of the_content() ???ok so I figured it out. For anyone trying to do this in the future….
Open the file “wp-includes/template-functions-post.php”
On line 74 or so there is a function called “the_content”
Copy that whole function and paste it below
Rename it to something like “the_content_modified”
Change the line that reads “echo $content;”
To “return $content;”Now you can store it in a variable using:
$myVariable = htmlspecialchars (the_content_modified(”, 0, ”));*this example will keep all the HTML tags
Phil
Forum: Fixing WordPress
In reply to: Howto get substring of the_content() ???Hey,
I want to store the output of the_content in a PHP variable as well. However, I don’t think I can use post->post_content because I need the code to be HTML – (so it includes the
tags and <p> tags and stuff). Is there any way to store that code in a variable?eg- either have post->post_content output as HTML
or- store the_content in a variableHELP!
Forum: Fixing WordPress
In reply to: When the author posts, it doesn’t show who posted it.hey, try reposting the code like this:
<!– uncomment the “by <?php the_author(); ?> to put the author’s name on the post –>
<div class=”post”>
<h2 id=”post-<?php the_ID(); ?>”>” rel=”bookmark” title=”Permanent link to <?php the_title();?>”><?php the_title(); ?></h2>
<small>Posted in <?php the_category(‘, ‘); ?> on <?php the_time(‘F jS, Y’); ?> by <?php the_author(); ?></small>
<div class=”entry”>
<?php the_content(‘Read the rest of this entry ?’); ?></div><p class=”postmetadata”><?php edit_post_link(‘Edit’,”,’|’); ?><?php comments_popup_link(‘ Leave A Comment ?’, ‘1 Comment ?’, ‘% Comments ?’); ?></p>
<?php trackback_rdf(); ?>
</div>Forum: Fixing WordPress
In reply to: how do i post to a specific page?I’m not sure if you guys have this working yet but I did something like this before.
This really helped:
https://me.mywebsight.ws/2006/12/18/move-wordpress-blog-to-inner-page/And I think you’ll need this too – to exclude categories from a blog page use this plugin:
Forum: Fixing WordPress
In reply to: Problems with postingHey Antonia,
What do you mean by only one line at a time?Forum: Installing WordPress
In reply to: Installing WP to root directoryTry removing or re-naming the index.html or index.htm file
Forum: Installing WordPress
In reply to: Second Step Problems-I’m not sure…but it could be that not all the files were actually uploaded – that happened to me once and I got an error like that. One of the files containing the function didn’t get uploaded so I had to upload it again.
Hope you figure it out!
Forum: Fixing WordPress
In reply to: When the author posts, it doesn’t show who posted it.I’m pretty sure you need to add something like this to “the loop”:
———-
<p>Posted by <?php the_author_posts_link() ?> on <?php the_time(‘d M Y’); ?>
———-
*the loop is anywhere after the line that looks like:
———-
<?php if ($posts) : foreach ($posts as $post) : start_wp(); ?>
———-and it is in the “index.php” of your theme
Hope this helps
Forum: Plugins
In reply to: Replacing a string within the_content() with another?I am trying to do this same thing – replace a string in ‘the_content’
I am using it in the RSS file but I want the RSS to output all the HTML (including tags and stuff). So the way I am using it is like this:
<![CDATA[<?php the_content('', 0, '') ?>]]>
What I want to do is take that output and store it in a variable and do a string replace after all the tags.
(I am pulling the content into Flash – but wordpress adds a space after the tags which translate as a full line break in Flash – so I want to replace the space with nothing so it’s gone)
Has anyone come up with a way to store the output of ‘the_content’ in a variable yet?
Forum: Fixing WordPress
In reply to: whole blog: gonedid you happen to delete your theme at all? I would recomend checking the themes folder to make sure all the files are still there
Forum: Fixing WordPress
In reply to: Blog by Email – managing imagesHere’s another thing Im working on – I want postie (or maybe WordPress?) to auto create thumbnails of each image uploaded by postie like WordPress does for you when you upload images.
Does anybody have even a small idea that might help?
Forum: Fixing WordPress
In reply to: Blog by Email – managing imagesI am still working on this….
To re-define what I’m doing:I am now using postie to Blog by email but also sending image attachments. Postie automatically adds the image to the post. However, what I am trying to do is make the image a seperate entity. I want to be able to post just the image URL in the loop by itself. Is there anyway of doing this?
It seems like there would be – and that it would be simpler than what postie is already doing, which is adding the photo to the html of the post.
Any help?
Forum: Installing WordPress
In reply to: upload file in the “write > write post” tabHey – I am not really sure what your problem is- but is it possible that your chmod isn’t set to allow uploads? Just a guess…