Displaying additional User Contact Information

This might help you out if you haven’t found an answer yet. /* BEGIN Custom User Contact Info */ function extra_contact_info($contactmethods) { unset($contactmethods[‘aim’]); unset($contactmethods[‘yim’]); unset($contactmethods[‘jabber’]); $contactmethods[‘facebook’] = ‘Facebook’; $contactmethods[‘twitter’] = ‘Twitter’; $contactmethods[‘linkedin’] = ‘LinkedIn’; return $contactmethods; } add_filter(‘user_contactmethods’, ‘extra_contact_info’); /* END Custom User Contact Info */ Displaying it: <a href=”https://wordpress.stackexchange.com/questions/32505/<?php the_author_meta(“facebook’, $current_author->ID); ?>”></a> http://thomasgriffinmedia.com/blog/2010/09/how-to-add-custom-user-contact-info-in-wordpress/

Tons of Twitter rows in my database

Here is a bait-and-switch approach to deleting all those rows: CREATE TABLE wp_posts_new LIKE wp_posts; ALTER TABLE wp_posts_new DISABLE KEYS; INSERT INTO wp_posts_new SELECT * FROM wp_posts WHERE post_type’http’ AND post_title<>’GET http://twitter.com/statuses/user_timeline/@xcentric.json?count=100′; ALTER TABLE wp_posts_new ENABLE KEYS; ALTER TABLE wp_posts RENAME wp_posts_old; ALTER TABLE wp_posts_new RENAME wp_posts; Now start using you website. When you are … Read more

Adding a custom line of text to php code

In the insert_posts function, before the line $post_id = wp_insert_post( $post ); add the following (and suit to your needs): Link to Twitter User Page $post[‘post_content’] .= ‘<a href=”http://twitter.com/__USERNAME__”>’ .’Follow me on Twitter’ .'</a>’; and/or Link to Twitter Status $post[‘post_content’] .= ‘<a href=”‘.$post[‘twitter_permalink’].'”>’ .’View this post on Twitter’ .'</a>’;

Twitter feed is showing blank in WP site [closed]

It is very likely because you are using the old Twitter API, for example: <script type=”text/javascript” src=”http://twitter.com/statuses/user_timeline/USERNAME.json?callback=twitterCallback2&amp;count=4″> You will need to update your code to the new API: http://api.twitter.com/1/statuses/user_timeline.json?screen_name=USERNAME&include_rts=true&count=4&callback=twitterCallback2 This requires that you edit the code of the theme. Many themes suffered this issue for a few months ago when Twitter made their changes.

Best way to allow manageable social media URLS?

The best way is on the user profile page using the contact methods extension: add_filter( ‘user_contactmethods’, ‘more_contactmethods’ ); function more_contactmethods( $contactmethods ) { $contactmethods[‘twitter’] = ‘Twitter username’; $contactmethods[‘facebook’] = ‘Facebook URL’; return $contactmethods; } This adds fields to the user profile page for those social networks. You can have as many as you like, then … Read more

Customize Embedded Tweets (or, How To Hide Photos in Embedded Tweets)

Here’s one way using the oembed_fetch_url filter to add the hide_media query parameter, that’s also mentioned in the Twitter doc page you linked to: Set an oEmbed query parameter of hide_media=true or add a data-cards=”hidden” attribute to the resulting <blockquote> element to prevent expanded content display. Here’s an example: /** * Hide media for all … Read more