Advertisement:

SMF Blog

Started by jesterhawk, February 10, 2006, 07:54:28 PM

Previous topic - Next topic

jesterhawk

Hello,

I would like to add a blog to my site and then thought it would seem only logical to be able to have the SMF be the blog.  I am sure that someone who knows what they are doing could setup something that gets called from the main index page of a website and looks at a special forum for the blog.  I don't know how to do that, but it would seem like since all the posting functions are already there it would be easy.  I could be wrong, but if someone is going to do it or has done it, I would like to know.

Thanks,
JH
-----------------------------------
Jesterhawk

jesterhawk

Ok, I must have did something wrong at first because I did a search on BLOG (or thought I did) and got nothing.  Then I thought that was odd, therefore, I tried it again and this time found a bunch of stuff. 

Sorry, this has been discussed.

Thanks,
JH
-----------------------------------
Jesterhawk

Trekkie101

http://blogs.lux-mundi.co.uk

I have a very basic blog type thing, would this perhaps do fine?

Things like a "new post" button are really easy for me to code in.. its basic but im just using it as a proof of concept.

jesterhawk

Yeah, that would work.  I don't need something overly complicated.

-----------------------------------
Jesterhawk

Trekkie101

Right, well, the code:

Code (index.php) Select
<?php
#Blog Roll
#Another Trekkie101 Innovation

#First, get the SSI loaded
require("../forum/SSI.php");

#next echo out the beautifuly amazing header
echo'<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Blogs</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />

</head>

<body bgcolor="#CCCCCC">
<br />
<br />
<center>
<table width="550" bgcolor="#FFFFFF" cellpadding="10" style="border: 1pt solid #000000">
<tr>
<td><center><table width="400" bgcolor="#EBEBEB" cellpadding="10" style="border: 1pt solid #B3B3B3">
<tr>
<td><center><big><big>Blog Center</big></big><br /><small><a href="http://www.lux-mundi.co.uk">Home</a>, <a href="http://lyrics.lux-mundi.co.uk">Lyircs</a>, <a href="
http://trekkie.lux-mundi.co.uk">Trekkie</a>, <a href="http://forum.lux-mundi.co.uk">Forum</a>, <a href="http://live.lux-mundi.co.uk">Live</a></small></center>
</td>
</tr>
</table><br /><a href="http://forum.lux-mundi.co.uk/index.php?action=.xml;type=rss2;sa=news;board=77;limit=10"><img src="rss.gif" border="0" alt="
rss" /></a><a href="http://forum.lux-mundi.co.uk/index.php?action=.xml;sa=news;board=77;limit=10"><img src="xml.gif" border="0" alt="
xml" /></a></center><br /<br />'
;


#get the lyric number from the url
$messageidnumber $_GET['blog'];
if (isset(
$messageidnumber)) {      //check that ones been set ;)
ssi_grabMessage($messageidnumber); echo'<br /><br /><a href="index.php">Back</a>';  //if it has, grab the message of it
} else {                            //right nones set, do something else, look busy! I know, show some links BAHAHAHA!


//This is gonna get ugly!
echo'
<b><big>Blog Roll - Lux-Mundi </big></b><br /><img src="filetypes.png" alt="blogs" border="" align="right" /><br />'
;
        
$array ssi_boardNews($board 77.0,$limit 10,$start null,$length null,$output_method 'array');
foreach ($array as $news)
{
echo' ' $news['icon'] . ' - <b><a href="index.php?blog=' $news['message_id'] . '">' $news['subject'] . '</a></b> ';
echo' <br /><small>Posted: '.$news['time'].' by ' $news['poster']['link'] .'</small>';
echo' <br /><br /> '$news['body'] .'<br />'$news['new_comment'] . '<hr /><br />';
};
//Wasnt so bad, was it?

//end the else?
}

echo
'
</center>
<br /><center><img src="katomic.png" alt="blogs" border="" /><br />
 <br />

<table width="200" bgcolor="#EBEBEB" cellpadding="10" style="border: 1pt solid #B3B3B3">
<tr>
<td><center><small>&copy; Lux-Mundi 2005</small></center></td>
</tr>
</table></center></td>
</tr>
</table>
<br /><br /></body>
</html>'
;
?>


You'll need to change the links as you want them, and the $board= variable can to your board, limit to however many you want to show initally. Copyright and that stuff, do what you like with it.

And attached are the images i use. Layout is hard coded so change at will.

Lastly, you NEED this mod:
http://mods.simplemachines.org/index.php?mod=18



clearly

Trekkie101, do you know the name of the font used in the first and second picture?
I mean this:



Thanks.

Trekkie101

Damn I attached the wrong images.

Erm, dunno. Took them from a site that was offering standardised buttons.

HoTmetal

Quote from: jesterhawk on February 10, 2006, 07:54:28 PM
Hello,

I would like to add a blog to my site and then thought it would seem only logical to be able to have the SMF be the blog.  I am sure that someone who knows what they are doing could setup something that gets called from the main index page of a website and looks at a special forum for the blog.  I don't know how to do that, but it would seem like since all the posting functions are already there it would be easy.  I could be wrong, but if someone is going to do it or has done it, I would like to know.

Thanks,
JH


Are you trying to add blogs for your users, or use SMF to blog? I had my blog site set up using SSI to blog.  I had SMF installed in a separate DIR, & used SSI to pull post & allow users(guests) to comment. Do a search on SSI posts by unknown. This should put you on the right track. The rest is trial & error.

Slotos

Quote from: eastwest on February 11, 2006, 03:32:39 PM
Trekkie101, do you know the name of the font used in the first and second picture?
I mean this:



Thanks.

I can't say I have any visual memory at all, but those fonts remind me hxxp:www.narisoval.ru/download/fonts/webcondc.zip [nonactive] and hxxp:www.narisoval.ru/download/fonts/websmc.zip [nonactive].

mkress

Quote from: Trekkie101 on February 11, 2006, 01:10:59 PM
ssi_grabMessage($messageidnumber);

that code is not included in ssi.php

mfg
Markus

Trekkie101


Vinspire^

Quote from: cNc-Rickc on February 11, 2006, 09:16:31 PM
Are you trying to add blogs for your users, or use SMF to blog? I had my blog site set up using SSI to blog.  I had SMF installed in a separate DIR, & used SSI to pull post & allow users(guests) to comment. Do a search on SSI posts by unknown. This should put you on the right track. The rest is trial & error.

I want to add a blogs function for my users. Is there such mod in SMF ?

Intergrated Blog in SMF ... I did some search on the site and so far .... I think its not available yet right ?

H

Moving to Tips and Tricks so it can get more exposure :D
-H
Former Support Team Lead
                              I recommend:
Namecheap (domains)
Fastmail (e-mail)
Linode (VPS)
                             

anunlike

Quote from: clearly on February 11, 2006, 03:32:39 PMTrekkie101, do you know the name of the font used in the first and second picture?
I mean this:



Thanks.

According to EKstreme.com's button maker, the font is 'Silkscreen'. (?)

Hasanudin

#14
Unknown column 'm.ID_MEMBER' in 'on clause'
File: /public_html/forum/SSI.php
Line: 1569

* Hasanudin using SMF 1.1 RC2

deadpoeticstar

im trying to do the same thing but integrate it into my blog

Alan S

i believe if you use tinyportal Feline from the tinyportal theme is after working on a mod that allows each user to have a blog , see http://www.tinyportal.net/smf/index.php?topic=6226.0 for more details
Quote from: Eliana Tamerin on August 23, 2008, 04:10:10 PM
SMF 7 is where it gets good. That has time travel. You can go back and post before the guy who flamed you. :P

HRM

#17
I have tried this script thingy. It does work and looks nice but dont know what to do with it.. ???

It's a great thingy to use inside a portal by example.

http://www.muziek4um.nl/

To install something for the cat's 'cut' is never nice..... (old dutch saying) :D

HRM

Really looks beautiful only clicking on the message title wont bring us to the the forum post :(

http://www.muziek4um.nl/index.php?page=5
To install something for the cat's 'cut' is never nice..... (old dutch saying) :D

HRM

Quote from: Alan S on July 11, 2006, 04:50:56 PM
i believe if you use tinyportal Feline from the tinyportal theme is after working on a mod that allows each user to have a blog , see http://www.tinyportal.net/smf/index.php?topic=6226.0 for more details
Does that really works? Cause that would really be very cool!
To install something for the cat's 'cut' is never nice..... (old dutch saying) :D

deadpoeticstar

Quote from: HRM on August 24, 2006, 04:26:22 PM
Quote from: Alan S on July 11, 2006, 04:50:56 PM
i believe if you use tinyportal Feline from the tinyportal theme is after working on a mod that allows each user to have a blog , see http://www.tinyportal.net/smf/index.php?topic=6226.0 for more details
Does that really works? Cause that would really be very cool!

Yes it really does work and its quite ingenious

Alan S

Quote from: HRM on August 24, 2006, 04:26:22 PM
Quote from: Alan S on July 11, 2006, 04:50:56 PM
i believe if you use tinyportal Feline from the tinyportal theme is after working on a mod that allows each user to have a blog , see http://www.tinyportal.net/smf/index.php?topic=6226.0 for more details
Does that really works? Cause that would really be very cool!

Yea its called felblog , go to www.tinyportal.net for the info on it or www.xyfrauen.com for the creators page
Quote from: Eliana Tamerin on August 23, 2008, 04:10:10 PM
SMF 7 is where it gets good. That has time travel. You can go back and post before the guy who flamed you. :P

DawnsWebDesigns

Felblog no longer works & isn't being offered for a while.  And this code left here...where was it supposed to be posted?  I use 1.1.2 & Tinyportal & added the php code to an article & got this:

Parse error: syntax error, unexpected '<' in /home/.mischa/dawnswebdesigns/leforce.dreamhosters.com/Sources/Load.php(1766) : eval()'d code(231) : eval()'d code on line 1

Anybody know where I can find a blog mod?  One that works & can be downloaded?

DawnsWebDesigns

I tried this again using a script box instead of a php box...it still didn't work out right.  Most everything I typed in the script box actually showed up on the page...also as just an article (TP).  Anybody got an update to this code?  I've looked across 2 sites & searched many pages...no blogs mods.  :(

ckgb


DawnsWebDesigns

Quote from: ckgb on March 17, 2007, 04:04:10 PM
На smfhacks.com посмотри

You mean the blog mod from SMFHacks?  It had bugs & is no longer offered. :(

As of now...if you use Felblog your image verification code/listen to code won't show up on the registration page.  If you use the invite mod & block registrations to invites only...you can disable the image verification.  Otherwise you can't use it.

H

-H
Former Support Team Lead
                              I recommend:
Namecheap (domains)
Fastmail (e-mail)
Linode (VPS)
                             

spottedhog

#27
Have been thinking about how to actually create a "SMF Blog" and I think I have conceptualized most of it, but need some help with a couple of things.  My approach may be totally wrong, and that is OK.

Here goes............

I am thinking this can be done using 2 of the Mods; Custom Action, ssi_Topic, or ssi_TopicNews, and then creating a new ssi by modifying the ssi_BoardNews to display only Topics and not replies.

For the new ssi (ssi_TopicsList or ssi_blogList for example), have it display Topics, listing the first created first.  Could probably leave out all the other graphics, etc. and just have the Topic Name with a limit to the # of characters allowed in the "description".  The Topic name would need to be linked to a Custom Action created to display that Topic and all of its replies (ssi_Topic or ssi_TopicNews).

Overview
What to do:

  • Place a text/graphic button on the main template menu.
  • Add the button text to the language files.
  • Create a forum board name "Blogs".
  • Make the permissions for Regular Members to Create Topics and Reply to only own topics.
  • Probably would want to cancel permissions for Polls and Attachments.
  • Create a Custom Action for the Blogger's List using the modified ssi_BoardNews (board# = Blog board initially created.)
  • Create a Custom Action for the Blog using ssi_Topics or ssi_TopicNews.

The concept is to place a button on the default theme in the template menu that will open up the "SMF Blog".  The button would open the Custom Action created for the modified ssi_BoardNews, and would list the topics from the Blog forum board (BloggersList).  Maybe have the character limit small to encourage the Topic to be a short description of the blog.

Then the links created in the Blogger's List open up the other Custom Action created for ssi_Topics or ssi_TopicsNews.

I have not spent any time on trying this, but right now I know the issue would be in modifying the ssi_BoardNews to create a new ssi_blogger or ssi_TopicLister or some other such name.

Taking pieces from other Mods, here is how the template menu buttons can be created:     

#Let's take care of the Language file addtions first
Add to $languagedir/Modifications.english.php:
$txt['blog'] = 'Blog';

#Let's create a button for the menu in the default theme

Put the follow code just before the Logout button, (around line 580)

// the [blog] button
echo ($current_action == 'bloglist' || $context['browser']['is_ie4']) ? '<td class="maintab_active_' . $first . '">&nbsp;</td>' : '' , '
<td valign="top" class="maintab_' , $current_action == 'contact' ? 'active_back' : 'back' , '">
<a href="', $scripturl, '?action=bloglist">' , $txt['blog']  , '</a>
</td>' , $current_action == 'bloglist' ? '<td class="maintab_active_' . $last . '">&nbsp;</td>' : '';


#Make button code for themes with a graphic
Place a graphic named "blog.gif" in $themedir/THEMENAME/images/english.

Insert this before the Logout button:
echo '
       <a href="', $scripturl, '?action=contact">', ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/blog.gif" alt="' . $txt['blog'] . '" style="margin: 2px 0;" border="0" />' : $txt['blog']), '</a>', $context['menu_separator'];


There would need to be 2 Custom Actions created.  One would be the Blogger's List, the other the Blog.

Blogger's List Custom Action (uses the newly created ssi from the modified ssi_BoardNews):
<div align="center"><h3>Blogger's List</h3></div>
<div>
ssi_blogger($boardID);</div>


Blog Custom Action:
<div align="center"><h3>Blog</h3></div>
<div>
ssi_TopicNews($topicID);</div>


It might be nice to be able to put the "blogger's username before "Blog", but I am unsure how to program that.

The first Custom Action, Blogger's List, would have clickable links to the other Custom Action so that the proper topicID is displayed.

Sooooo....  I guess the last part I am missing is how to get the topicID for the Blog Custom Action.

In Summary...
For this to work properly, I need the new ssi created, using something like a modified ssi_BoardNews, but only displaying Topics from a specific board, and then the links would be to a new Custom Action to show the single "Blog" using the ssi_Topics or ssi_TopicNews.

--need a new ssi_topicList (or ssi_blogList)
--need to know how to put the TopicID in the link that opens the Blog Custom Action.

Ideas?  Comments?

John S

hey, is it possible to have a blog in everyones profile?, say a button on the left that says 'Blog' and people can go to their blog and add comments, all that needs to be displayed is the time, date stamp, title of blog and message. - of course only the user can modify and add..

this seems straight forward.. is this possible?

Advertisement: