PDA

View Full Version : Forum Display Enhancements - This Day In History ~ Changes Daily


UKBusinessLive
12-26-2008, 10:00 PM
This Day in History

Just a Little hack here which you can add to your Forums, Give you a bit of content which changes daily, Should keep your members amused.

You can use this code in a variety of places, If you want it at the top of your forum you can add it to your header like below...

https://vborg.vbsupport.ru/external/2008/12/10.png

or if you want to be a bit creative you can make a new category and add the code to the discription field, this is great if you want to break up your forum like this...

https://vborg.vbsupport.ru/external/2008/12/11.png

Content changes daily and your members can read up more about the Day in History directly at the http://www.thefreedictionary.com/ site.

So lets do it......

If you want to add the code to your header, or footer, simply go to your ACP > Style Manager > Your Style

and add this to either the Header or Footer

<DIV ALIGN=CENTER>
<!--This Day in History by TheFreeDictionary.com-->
<div style="width:750px;position:relative;background-color:;padding:4px">
<div style="font:bold 15pt '';color:#000000">This Day in History</div>
<style>
#TodaysHistory {width:100%;border:none;background-color:}
#TodaysHistory H3 {margin-top:0px;font:bold 12pt '';color:#000000}
#TodaysHistory TD {font:normal 10pt '';color:#000000}
#TodaysHistory A {color:#0000FF}
</style>
<script language="javascript"
src="http://img.tfd.com/daily/history-top.js?0"></script>
<div style="font:normal 8pt '';color:#000000">
</div></div>
<!--end of This Day in History-->



If you want to add it within your forum, as a category type of insertion, just go to your ACP >Forums & Moderators > Add New Forum

In the title add : This Day In History

In the discription add the code below..

<DIV ALIGN=CENTER>
<!--This Day in History by TheFreeDictionary.com-->
<div style="width:750px;position:relative;background-color:#FFFFFF">
<div style="font:bold 15pt '';color:#000000"></div>
<style>
#TodaysHistory {width:100%;border:none;background-color:}
#TodaysHistory H3 {margin-top:0px;font:bold 12pt '';color:#000000}
#TodaysHistory TD {font:normal 10pt '';color:#000000}
#TodaysHistory A {color:#0000FF}
</style>
<script language="javascript"
src="http://img.tfd.com/daily/history-top.js?0"></script>
<div style="font:normal 8pt '';color:#000000">
</div></div>
<!--end of This Day in History-->



Remember under Posting options select "NO" to "Act as Forum" This will keep it as a standalone category style.

*****************UPDATE**********************

If you wanted to add this as an insertion after each 1st post you could use the code below (See picture ;) ) This will show it after each 1st post in threads

https://vborg.vbsupport.ru/external/2008/12/8.png

Just go to your ACP> Style Manager> Your Style> Edit Templates> Forum Display Template> Postbit Template > (then your chosen Positbit ~ either plain postbit or legecy)

Add this code to the very end of your postbit template

<if condition="!$GLOBALS['FIRSTPOSTID']">

$spacer_open
<div style="padding:0px 0px $stylevar[cellpadding]px 0px">

<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<tr>
<td class="thead" align="left">This Day in History</td>
</tr>
<tr>
<td class="alt1" align="center">
<!--This Day in History by TheFreeDictionary.com-->
<div style="width:750px;position:relative;background-color:;padding:4px">
<div style="font:bold 15pt '';color:#000000">This Day in History</div>
<style>
#TodaysHistory {width:100%;border:none;background-color:}
#TodaysHistory H3 {margin-top:0px;font:bold 12pt '';color:#000000}
#TodaysHistory TD {font:normal 10pt '';color:#000000}
#TodaysHistory A {color:#0000FF}
</style>
<script language="javascript"
src="http://img.tfd.com/daily/history-top.js?0"></script>
<div style="font:normal 8pt '';color:#000000">
</div>
<!--end of This Day in History-->

</if>
</td>
</tr>
</table>

</div>
$spacer_close

</if>



if you come up with alternative uses, feel free to share them here ;)

Thats it

Enjoy :D

UKBusinessLive
12-27-2008, 05:46 PM
:D Reserved :cool:

TimberFloorAu
12-27-2008, 07:11 PM
weird... went to your forum, and my IP is banned lol.
*reserved*

UKBusinessLive
12-27-2008, 07:13 PM
weird... went to your forum, and my IP is banned lol.
*reserved*

PM me your IP add i'll check, had lots of probs with spammers as of late

TimberFloorAu
12-27-2008, 07:16 PM
why ban IP's though.. for guest viewing ?

Surely some good captcha code upon registration would thwart spammers.

UKBusinessLive
12-27-2008, 07:22 PM
why ban IP's though.. for guest viewing ?

Surely some good captcha code upon registration would thwart spammers.

I don't just ban ip for guest viewing, i ban only for a reason, Perhaps your IP addy is on my Country Ban list, and thats there because of the amount of spambots that have been doing the curcuits lately.

The site is mainly UK Business Related So i really don't need Asian, Eastern Block or Russian members signing up

Nothing personal, Send me your IP and i'll make sure its cool ;)

GSeybold
12-27-2008, 09:26 PM
Works great for me.... Totally cool. Just have to figure out where to put it... I have it in my footer now but I think a forum would be better.

Thanks.. no problems with install.

GSeybold
12-27-2008, 10:16 PM
I decided to use it as a forum, even off topic. It gets people talking. :)

Bawtneez
12-27-2008, 10:18 PM
Very nice, thanks you =)

UKBusinessLive
12-28-2008, 12:32 AM
I decided to use it as a forum, even off topic. It gets people talking. :)

Thanks :cool:

James Argo
12-28-2008, 02:22 AM
This is verrry nice!!!

However, since my site is music related, I wonder if I can "pull" data from another source like:

http://www.thisdayinmusic.com/

http://datadragon.com/day/

Anyway, it's great mod indeed! :)

GSeybold
12-28-2008, 02:37 AM
Hey James

let me know how that works. I would like to do the same if I can figure it out.

KevinL
12-28-2008, 02:55 AM
This is verrry nice!!!

However, since my site is music related, I wonder if I can "pull" data from another source like:

http://www.thisdayinmusic.com/

http://datadragon.com/day/

Anyway, it's great mod indeed! :)

You could use something like this http://www.newsniche.com/using-javascript-to-display-rss.php

Take the RSS feeds from those sites and parse them through that program so they're html and it would be pretty much the same as this.

like here is one for your first link This Daily Music (http://www.rss-to-javascript.com/?p=151%2C381&src=http%3A%2F%2Fwww.thisdayinmusic.com%2Fxml%2Fon thisday.php%3Fshowfacts%3D1&chan=1&simple_chan=1&num=0&desc=1&desc_max=0&date=1&target=&font=&font_size=&fgcolor=000033&bgcolor=FFFFFF&use_lists=1&preview=Preview)

Sorry to go off topic :o

UKBusinessLive
12-28-2008, 06:16 PM
Just updated with additional code to make it as 2nd post of each thread

https://vborg.vbsupport.ru/external/2008/12/8.png

Might be useful to use it as a sponsored advert, by adding a text ad to the bottom of the code ??

Enjoy :D

James Argo
12-30-2008, 02:30 AM
You could use something like this http://www.newsniche.com/using-javascript-to-display-rss.php

Take the RSS feeds from those sites and parse them through that program so they're html and it would be pretty much the same as this.

like here is one for your first link This Daily Music (http://www.rss-to-javascript.com/?p=151%2C381&src=http%3A%2F%2Fwww.thisdayinmusic.com%2Fxml%2Fon thisday.php%3Fshowfacts%3D1&chan=1&simple_chan=1&num=0&desc=1&desc_max=0&date=1&target=&font=&font_size=&fgcolor=000033&bgcolor=FFFFFF&use_lists=1&preview=Preview)

Sorry to go off topic :o

Thank you KevinL :)

* I clicked installed *

steve1966
12-30-2008, 08:57 AM
Thanks, just one thing i had to change the code because it aslo centered the Currently Active Users:

<div align="center"><!--This Day in History by TheFreeDictionary.com-->
<div style="width:750px;position:relative;background-color:;padding:4px">
<div style="font:bold 15pt '';color:#000000">This Day in History</div>
<style>
#TodaysHistory {width:100%;border:none;background-color:}
#TodaysHistory H3 {margin-top:0px;font:bold 12pt '';color:#000000}
#TodaysHistory TD {font:normal 10pt '';color:#000000}
#TodaysHistory A {color:#0000FF}
</style>
<script language="javascript"
src="http://img.tfd.com/daily/history-top.js?0"></script>
<div style="font:normal 8pt '';color:#000000">
</div></div>
<!--end of This Day in History--></div>

Bio-Con
12-30-2008, 12:44 PM
This is really cool, Thanks!

UKBusinessLive
01-02-2009, 08:31 AM
This is really cool, Thanks!

Thanks :D

scottny
01-08-2009, 02:15 PM
Ok I am new to all these adding things to the site but I like this. Is there anyway do you think that it could be changed to do all Disney information.
I run a Disney site and would love it to do "This day in History" for it.

If you think it can and you can walk me through it I would love it.

Thank you,

Scott

UKBusinessLive
01-09-2009, 12:02 AM
Ok I am new to all these adding things to the site but I like this. Is there anyway do you think that it could be changed to do all Disney information.
I run a Disney site and would love it to do "This day in History" for it.

If you think it can and you can walk me through it I would love it.

Thank you,

Scott


Hi Scottny

Thanks for your idea, however the information comes directly from the http://www.thefreedictionary.com/ site.
I have not control over the content unfortunately :(

scottny
01-09-2009, 02:32 AM
Ok

thanks for the reply.

poetrymansion
01-12-2009, 09:10 PM
I know this is a great mod, but sadly im blooming useless and i think i have killed everything.. PLEASE HELP.....

i added it using the within a forum option, and now all my margins have gone nutty and dont look right anymore, even after i have removed the added forum....

PLEASE HELP....

b4 the misses see's ive just killed her site......

HHHEEEELLLLLPPPP ANYONE......

UKBusinessLive
01-12-2009, 09:21 PM
I know this is a great mod, but sadly im blooming useless and i think i have killed everything.. PLEASE HELP.....

i added it using the within a forum option, and now all my margins have gone nutty and dont look right anymore, even after i have removed the added forum....

PLEASE HELP....

b4 the misses see's ive just killed her site......


HHHEEEELLLLLPPPP ANYONE......

Post a link to your site and let me know what method you chose out of the 3 posted, I'll help where i can :erm:

poetrymansion
01-14-2009, 10:23 PM
Thanks friend... great add-on..... once i was saved from myself... lol

I'd like it to link to poetry, but i think im best just leave it alone ah lol

cheers

poetrymansion

jlew24asu
01-14-2009, 10:54 PM
I installed this in a thread and made it a sticky :) cool idea!

UKBusinessLive
01-15-2009, 12:40 AM
I installed this in a thread and made it a sticky :) cool idea!

Glad you liked it :p

UKBusinessLive
01-15-2009, 12:41 AM
Thanks friend... great add-on..... once i was saved from myself... lol

I'd like it to link to poetry, but i think im best just leave it alone ah lol

cheers

poetrymansion

:D:D You made us all smile that night Clive ;)

YLP1
01-15-2009, 12:45 AM
I installed this in a thread and made it a sticky :) cool idea!
I would really like to know how you turned it into a thread. I have tried a variety of ways and failed. This is the method I think would work best for my site. Thanks in advance.

jlew24asu
01-15-2009, 11:46 AM
I would really like to know how you turned it into a thread. I have tried a variety of ways and failed. This is the method I think would work best for my site. Thanks in advance.

just make sure you allow HTML in that forum.

I went to the site provided by the coder and did Option 2.2

http://www.thefreedictionary.com/lookup.htm#sitecontent

(I added <div center=align> code </div> to center it)

here is my thread
http://www.chicagophotoshop.com/forums/showthread.php?t=900

UKBusinessLive
01-15-2009, 04:42 PM
Nice Idea :D

MARKA
06-28-2009, 12:31 PM
Thank you. Very nice.

Any way to make the MORE and DISCUSS links open into a new window rather than taking people away from the site?

UKBusinessLive
08-08-2009, 05:27 PM
Thank you. Very nice.

Any way to make the MORE and DISCUSS links open into a new window rather than taking people away from the site?

<A HREF="newwindow.html" TARGET="_blank">a new window</A>

This value does not require the use of any frames. "_blank" is popular in web pages which are devoted to links to "other resources on the net". By opening a new window for each resource, the user has a sense of a "main" page (the list of resources) and "secondary" pages (each individual resource). However, this results in cluttering the computer screen, which may irritate some of your readers.

Find this line of code

src="http://img.tfd.com/daily/history-top.js?0"></script>

and add the "TARGET="_blank" to the end of the code, that will open the page on a new window

src="http://img.tfd.com/daily/history-top.js?0 "TARGET="_blank"></script>