Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Site News Plugin..
Author Message
enlightenme
Junior Member


Posts: 27
Joined: Feb 2009
Reputation: 0
MyBux: 0
Post: #1
Site News Plugin..
And I thought all my problems were solved after I figured out the Custom Pages Plugin...LOL

At least the Site News plugin is much easier. However, I got tripped up with the code I am supposed to insert in my homepage.

Is there anything wrong with this code (is there anything missing?):

PHP Code:
<?php

define
("IN_MYBB"1);
define("KILL_GLOBALS"1);
define("NO_ONLINE"1);


$directory_to_forum "asianadventures.org/forum/index.php"

require 
dirname(__FILE__)."/".$directory_to_forum."/global.php";

$plugins->run_hooks("site_news_plugin_run");

?>

This is what shows up on my home page:

Code:
run_hooks("site_news_plugin_run"); ?>

Please let me know what I need to correct. Thanks a lot people!

http://www.asianadventures.org
02-13-2009 04:22 AM
Nickman
Manager



Posts: 1,557
Joined: May 2008
Reputation: 32
MyBux: 280
Post: #2
RE: Site News Plugin..
First I can tell
PHP Code:
$directory_to_forum 
is wrong. It should be a path like forum if I'm not mistaken. Also are you adding the above code to a page that ends in .html? Because the page must have the extension .php...
02-13-2009 04:38 AM


enlightenme
Junior Member


Posts: 27
Joined: Feb 2009
Reputation: 0
MyBux: 0
Post: #3
RE: Site News Plugin..
(02-13-2009 04:38 AM)Nickman Wrote:  First I can tell
PHP Code:
$directory_to_forum 
is wrong. It should be a path like forum if I'm not mistaken. Also are you adding the above code to a page that ends in .html? Because the page must have the extension .php...

Thanks Nickman! I got it to work, finally (you can check it out - click the link on my signature).

I have another question though:

Where do I place the CSS code to format the site news area? Am I supposed to place it within the PHP code? and if so are there any vital tags I need to include?

Also, is there a way to automate this plugin? So for example, if I wanted it to automatically display the most current thread on my homepage, how can this be done, if possible?

Thanks again!

http://www.asianadventures.org
(This post was last modified: 02-15-2009 01:05 AM by enlightenme.)
02-14-2009 10:11 PM
Dalton
Tuts Team Lead



Posts: 1,044
Joined: Aug 2008
Reputation: 3
MyBux: 196
Post: #4
RE: Site News Plugin..
I'd think you could just put it in global.css.. however I've never used the plugin so I'm not entirely sure.

02-15-2009 12:16 AM


enlightenme
Junior Member


Posts: 27
Joined: Feb 2009
Reputation: 0
MyBux: 0
Post: #5
RE: Site News Plugin..
No offense Dalton, is there anyone that can help me with this?

http://www.asianadventures.org
02-15-2009 03:40 PM
Dalton
Tuts Team Lead



Posts: 1,044
Joined: Aug 2008
Reputation: 3
MyBux: 196
Post: #6
RE: Site News Plugin..
Isn't there a CSS style in Templates & Themes --> *select theme* ?

02-17-2009 03:48 AM


enlightenme
Junior Member


Posts: 27
Joined: Feb 2009
Reputation: 0
MyBux: 0
Post: #7
RE: Site News Plugin..
(02-17-2009 03:48 AM)Dalton Wrote:  Isn't there a CSS style in Templates & Themes --> *select theme* ?

None that I could see. This is a plugin as you probably known.

http://www.asianadventures.org
02-19-2009 12:46 AM
 




New to MyBBSource?Need Assistance?
  • Mark Forums Read
  • View Forum Staff
  • Looking for a MyBB Host?

  



Theme created by AK-47. Find more great themes and skins at K! Dezign R1s.net