Hi all

Here is a simple tip to insert a "You Might Be Interested In ... " (call it whatever you like really) section at the bottom of all blog posts, sort of like we have Related Videos on the video module.

Here's how it looks:


What does it do? It pulls in the middle column modules from the blog page, e.g. Latest Blog Posts, Most Popular Blog Posts etc. In the example above it is pulling in the Latest Featured Blogs from the Featured blog posts page.

How to install it:

  • Add this script to your Custom Code box (also attached as a text file):
<!-- SP You Might Be Interested In -->
<script type="text/javascript">

x$(document).ready(function() {
x$('.xg_widget_profiles_blog_show .xg_module_with_dialog').append('<h2 class="interested">You Might Be Interested In ... </h2><div id="SPmoreblogs"></div>');
x$('.xg_widget_profiles_blog_show .xg_module_with_dialog #SPmoreblogs').load('/profiles/blog/list?promoted=1 .xg_widget_profiles_blog_list .xg_column.xg_span-4.xg_last .xg_module:contains("Latest Featured Blog Posts")');
});
</script>


The script looks for modules with certain headings on certain pages, so you can change the highlighted items to suit your needs.

  1. If you want the 'You Might Be Interested In ... ' to say something else then change the orange You Might Be Interested In ...
  2. If you want to load a module from the All Blogs page (rather than the Featured Blogs Page as I am using) then change /profiles/blog/list?promoted=1 to /profiles/blog/list
  3. If you want to load a box other than Latest Featured Blog Posts change it to whatever you want, e.g. Most Popular Blog Posts

 

  • Add this CSS to your Advanced CSS section in Design Studio, tweaking the bits that you need to

/*You might be interested font*/
.interested{

font-family:georgia!important;
font-style:italic!important;
font-size:24px;
color:#a10227!important;
margin-left:10px;
}

/*List items*/
#SPmoreblogs li {

background: #F9F9F9;
border: 1px solid #E4E4E4;
display: block;
float: left;
margin-right: 3px;
min-height: 58px;
padding: 5px;
width: 168px;
border-radius:3px;
-moz-border-radius:3px;
-webkit-border-radius:3px;
}

/*Removes border from module*/
#SPmoreblogs .xg_module{
margin-top:10px;
border:none;
}

/*Removes module header*/
#SPmoreblogs .xg_module_head{
display:none;
}

I hope this is of use. YOu can check out a live demo here.
Enjoy
SP

ps. this is for blogs only for now. Not had time to do the forum. Might get round to it at some point if no one else hacks it in the meantime.

Tags: Professional Ning Design, Related Items, You might be Interested in

Views: 1186

Attachments:

Reply to This

Replies to This Discussion

Excellent!  Thank you for sharing

terrifically SWEET potato!

Sweet tip brother! Thanks for sharing.

showing words only - www.nepalichristians.com help-sp,

Looks like you've removed the code, shrawan. Could be you've added a break in the script that is causing the issue. SP

I have the same problem.

I did this and nothing happened.

is it on your site at present? can i look?

my previous reply is still valid. you don't have Latest Featured Blogs but you do have Últimas mensagens de destaque do blog

change them and it will work. although I notice you have a #.UMi1V3c7ejI append to your url (from assthis I guess) so not sure if that will affect it.

SP

Thanks, now it worked!

RSS

Latest Activity

Allison Leahy replied to Jen's discussion 'Jen's Running List - Updated 4/6/2013' in the group The Sandbox
"Sure does. Thanks for capturing this."
42 minutes ago
Profile IconAndre Lacerda, solo and 2 other members joined Allison Leahy's group
Thumbnail

The Sandbox

Join The Sandbox to experiment with Ning 3.0 now!The Ning Team will be triaging bug reports and…See More
43 minutes ago
Yaron replied to Allison Leahy's discussion 'Changes to Ning 3.0 Based on Your Feedback'
"Some embedded videos from members on our Ning 2.0 site can be seen in full screen, but most cannot.…"
54 minutes ago
Kos replied to Jen's discussion 'Jen's Running List - Updated 4/6/2013' in the group The Sandbox
"Allison I was just on IE 10 and here was the screen I got.  Look a little empty?  LOL…"
1 hour ago
Fabio replied to Bosco Carvalho's discussion 'Futuro das Redes Ning' in the group Criadores Brasileiros - Brazilian Creators
"Tenho que dizer que concordo com o Thiago, tenho o meu NING 2.0 www.radarhiv.com com 12 mil membros…"
1 hour ago

NC for Hire
Jen replied to Jen's discussion 'Jen's Running List - Updated 4/6/2013' in the group The Sandbox
"Thanks, I'm using FireFox 20.0.1. I wonder if it's a problem with FireFox and Ning?"
1 hour ago
Kos replied to Jen's discussion 'Jen's Running List - Updated 4/6/2013' in the group The Sandbox
"Firefox 20.0"
1 hour ago

NC for Hire
Jen replied to Jen's discussion 'Jen's Running List - Updated 4/6/2013' in the group The Sandbox
"Kos, What browser are you using, if you don't mind me asking. Thanks, Jen"
2 hours ago

© 2013   Created by Ning.

Badges  |  Report an Issue  |  Terms of Service