luckdragon
Forum Replies Created
-
Forum: Plugins
In reply to: I wrote this simple plugin but its not working – helpfirst off, you never call wp_mail so it’s not actually sending mail, secondly, even if it were, you have no headers defined, and lastly,
in that function what is “single_post_title()”? i.e. how does it know what id it’s supposed to be getting the post for? publish_post changes the data, therefore the $post variable is empty until it’s re-read, so only $post_ID is available.function send_email($post_ID) { $FromEmail = "address@mail_is_from.com"; $to = "myemail@myemail.com"; $mypost = get_post($post_ID); $subject = $mypost->post_title; $body = $mypost->post_content; $headers = "MIME-Version: 1.0" . "\r\n"; $headers .= "Content-type:text/html;charset=iso-8859-1" . "\r\n"; $headers .= "From: \"$FromEmail\" <$FromEmail>\n"; @wp_mail($to, $Subject, $body, $headers); }additionally, did you know that the publish_post hook gets executed anytime a post is saved and has a status of published?.. i.e. when it’s first converted from draft to published, if you edit it, and then save it, etc…
Forum: Hacks
In reply to: Manual Redirectare you saying that on the first visit, they choose, but from that point forward, they don’t? and what do you mean by go to the same page on a different url, as far as a browser is concerned, if it’s a different url, it’s a different page, even if the content is the same.
Forum: Hacks
In reply to: How to a hide plugin from specific usernames?hide it how? from the menu? or from the list of plugins? or both?
Forum: Fixing WordPress
In reply to: What's the correct syntax for quotes within a php statement?the positioning of your ‘ and ” are correct, however you are doing <? and ?> within an echo statement, which is already between <? and ?> so that is confusing the situation, not the quotations
echo '<a href="'.the_field('field_name').'">'.$linked_words.'</a>';Forum: Plugins
In reply to: I wrote this simple plugin but its not working – helpremove the ()
add_action(‘publish_post’,’send_email’);Forum: Plugins
In reply to: [Plugin: Mad Libs] Suggestionsit already has that, it also allows the user to be able to submit puzzles, or stories which can be converted into puzzles by the admin
Forum: Fixing WordPress
In reply to: Front Page is not showing up completelynot sure what’s not coming up, but it looks like it’s having problems getting to df.gasbuddy.com which means your page isn’t finishing loading, so if you have any scripts that run onLoad, they won’t execute because the page hasn’t completed
Forum: Hacks
In reply to: How We Can Change Location for Admin Login Wp-admin So can Protect?http://www.michikono.com/2007/02/12/who-else-wants-to-hide-their-wordpress-admin-folder/
that gives you instructions on how to do it.
Forum: Fixing WordPress
In reply to: Change "/wp-admin" to "/admin" ?Forum: Fixing WordPress
In reply to: Can i make pages specific to certain users?it doesn’t sound like his blog/idea is that large, and that there are only specific pages that would fall into this scenario. I agree that in a large environment, doing what he wants to do is madness, but people ask questions to get answers, so I offered an answer as opposed to “don’t do it”, if he’s running a private blog and he’s got some posts made for specific people, then doing it wouldn’t be so bad.
also, josh, you said you found things to do it in groups, why couldn’t you just put each user into their own group, and then filter by groups?
Forum: Fixing WordPress
In reply to: Please Help!!! Hide a line from sidebar<div class=”down-image”>
the first <div> after that has style=”margin-left: 45px; color: #4d4d4d;”
search for that, and add display:none; to the style
Forum: Fixing WordPress
In reply to: Can i make pages specific to certain users?one more simple way to control it is to define an extra field on the page with the username that has access to it, then in the page (might be single) template put an if statement testing against that extra variable and the user logged in.. if they match, show the page, if they don’t, redirect or show something else.
Forum: Fixing WordPress
In reply to: Fatal Error after updatesno, it’s saying that a function is being defined twice (or actually, a class), if you have ftp access, then I would recommend renaming
wp-content/plugins/jetpack to something else temporarily as it looks like it’s the jetpack plugin that’s causing the issueForum: Fixing WordPress
In reply to: insering database into a siteI could help you with it, tho I’m not sure how we can get in contact with each other on here, since they keep blocking email addresses when someone posts them.
guess you could check out my old website. I’m still working on re-designing it with WP so that my plugins and the like have a place to be demo’d 🙂
Forum: Fixing WordPress
In reply to: Error in index.php?if that is exactly what your first 5 lines look like, then the problem is that the <?php or <? that is supposed to be on line 1 is missing