![]() |
here is a MINI im talkin lil modification i did to the headlines.php to make it display a selected number of headlines instead of showing the same amout as the news.
in pluhheadlines.php find: PHP Code:
PHP Code:
|
Wow, look at all these posts. :)
Sorry I've been gone, but I'm glad there are people using my little hack. :) |
Quote:
:) |
I want to use this hack. However theres allota stuff to read here hehe, would it be ok to use the stuff from the first page or were there bugs fixed?
|
Well, haven't messed with it in a while...
Post any suggestions that ya'll would think is necessary, or wanted, or whatever. :D |
hmm, getting some odd errors:
Warning: Undefined variable: REQUEST_URI in path\to\global.php on line 39 Warning: Undefined variable: QUERY_STRING in path\to\global.php on line 47 Warning: Undefined index: HTTP_POST_VARS in path\to\global.php on line 64 Warning: Undefined index: action in path\to\global.php on line 64 Warning: Undefined index: action in path\to\global.php on line 67 Warning: Cannot add header information - headers already sent by (output started at path\to\global.php:39) in path\to\functions.php on line 1457 Today's News However at the very bottom its posting my news.. is there somthin I missed? hehe |
if you go back a couple pages you'll find out how to fix your header problem a whole bunch of us had that same problem :).
|
Quote:
you should add my code fix in the headlines :). lol. its simple but yeah it is useful. |
I read it but have a short term memory :p Ill dig back a bit hehe
|
Im getting that assortment of errors when I am logged in? I already have the cookie thing set. Also do I put those require commands on the index of the site itself where the news is included?
|
eh I cant get this thing to work for the life of me.
|
try including the admin/config.php and the global.php on your main page before the <html> tag. and than take them out of the pluhnews.php
|
hm when I do that it crashes.. My main page right now is .shtml is there anything I need to change beside adding those commands at the top and renaming it to .php? (i am somewhat new to PHP, just started toying with it recently)
I get a sweet assortment of errors :( |
btw I dont remember ever seeing anyone entounter these ones:
Warning: Undefined variable: REQUEST_URI in \path\to\global.php on line 39 Warning: Undefined variable: QUERY_STRING in \path\to\global.php on line 47 Warning: Undefined index: HTTP_POST_VARS in \path\to\global.php on line 64 Warning: Undefined index: action in \path\to\global.php on line 64 Warning: Undefined index: action in \path\to\global.php on line 67 then there is this one which is what I did see: Warning: Cannot add header information - headers already sent by (output started at \path\to\vbulletin\global.php:39) in \path\to\vbulletin\admin\functions.php on line 1457 This is what I get when I include it on my index Warning: Undefined variable: REQUEST_URI in \path\to\vbulletin\global.php on line 39 Warning: Undefined variable: QUERY_STRING in \path\to\vbulletin\global.php on line 47 Warning: Undefined index: HTTP_POST_VARS in \path\to\vbulletin\global.php on line 64 Warning: Undefined index: action in \path\to\vbulletin\global.php on line 64 Warning: Undefined index: action in \path\to\vbulletin\global.php on line 67 Fatal error: Failed opening required './admin/config.php' (include_path='') in \path\to\vbulletin\global.php on line 72 This isnt fun anymore :( |
in your global.php look for all the ./global and replace that with the full path to your global.php than it should work.
|
and your index should be a .php not .shtml because it cant phrase php . Try changing the file extension before you try changing all your paths in global.
|
Yea, I have tried most of that. I will try it again though. One thing is that my Index is located in a different DIR than the pluhnews.php would that make a difference?
|
I am getting closer now, I am now getting
Warning: Undefined variable: REQUEST_URI in \path\to\global.php on line 39 Warning: Undefined variable: QUERY_STRING in \path\to\global.php on line 47 Warning: Undefined index: HTTP_POST_VARS in \path\to\global.php on line 64 Warning: Undefined index: action in \path\to\global.php on line 64 Warning: Undefined index: action in \path\to\global.php on line 67 And my news gets added at the bottom. BUT I have not seen these "QUERY_STRING" and all the other things mentioned anywhere else in this thread. \ When I do the require command at the top of my index page I get those errors at the very top above all the layout, no more header error though :) |
also try putting your PluhNews in the same directory as your index.php seeing thats what the instructions say :).
|
Yep. Tried that :( (thats where it is now with these errors)
|
*bump*
Anyone have any ideas? |
im fresh out of ideas.. maybe one of the real gurus can help you :).
WOOHOO!! </Goldfinger is now a senior member :), 100th post > |
*bump* again, someone help me :(
hehe |
I figured it out, just deleted the code giving me errors and created a global2.php :)
|
Have another question though (as if u wanted to see my name again) Is there a way to include the Date at the top of that days news.. i.e.
October 15, 2001 blah - posted by Hamma @ 3:53PM blahblah Comments Here is a link to the current page I am using now, and an example of how Id like to configure Pluhnews: http://www.dragonwolves.com/index.shtml |
Quote:
Anybody has an answer for that? Possible to have categories? |
I fixed everything until I didn't get any more path error messages, but nothing is included :(
http://www.wiredguy.com/test.php |
If you look at the HTML, you can see the browser stops reading the source code once it hits the include. What's up with that?
|
If you visit the page in a browser, nothing shows up either:
- http://www.wiredguy.com/forums/PluhNews.php What's going on? |
I'm pleased to announce.... it works!!! :)
|
Does this work with 2.2.0?
|
Yes.
|
if I go to /forums/Pluhcomments.php (I named it that for a differrent use on my site) it works fine, but if I include it in a php file in a /folder/ as
Code:
<?php Include ("/forums/Pluhcomments.php"); ?> Quote:
I also included the pluhconfig in the comments.php script I am changing since I want it to display the info for a certain thread (I will hard code the thread ID into each article and include the comments.php) This is a great Hack Perfect. Or better yet, if you could post the code to do this X Comments last post by user" line only and then set it so that I can have a var $threadid= that I have in the article that it grabs to tie the above to the thread for the article? thanks |
Ok I moved the require global/admin to the test page, and now I am getting
Quote:
I added .mydomain.mydomain.org to the cookies this (changed name of real domain). So what am I doing wrong? I am still completely new to PHP. HELP!!!!!!!!!!!!! |
Back to square one.
I want to Include PluhHeadlines.php on each article page. All articles are in a /folder off main site. So I do PHP Code:
PHP Code:
www.mysite.com/critcalmass/some-article.php Now I get the Error Quote:
What am I missing? I am still completely new to PHP. As I was writing this, I tried using Absolute paths, and it works. I have implemented the headlines.php to replace my "This Week @Mac Write" at the top of all pages. Now to try out the Pluhnews.php but This afternoon it's 3AM and I need to get sleep (or finish watching TRUE LIES?) |
Here's a minor improvement to the hack that will allow you to use more than one forum as your source for news. :)
In PluhNews.php Find: PHP Code:
PHP Code:
example: PHP Code:
In PluhHeadlines.php Find: PHP Code:
PHP Code:
|
This "tweak" is for people who installed fastforward's spider friendly urls.
In PluhNews.php Find: //gotta convert that damn unix time crap Add BEFORE: PHP Code:
PHP Code:
PHP Code:
|
Cool additions. I've got an idea though:
What about allowing a paramater to be passed. For example, pluhnews.php?site=site1 would give news for the forum designated as "site1." |
I THINK you can do that by removing the variable $newsforums from the config file and then passing it in as the parameter.
newsforums=1 for example. Amy |
I have
"X Comments posted by XXXX" I want to manually enter the thread ID that this link, and the thrad it pulls the info from. So what do I change to fix it? |
All times are GMT. The time now is 02:01 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|