PHP "Include" in phpnuke 7.4

  Post new topicReply to topicPrintable Version
<< View previous topic View next topic >>
Share: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
#1   PHP "Include" in phpnuke 7.4
xfactor151
CZ Newbie
xfactor151 has been a member for over 20 year's 20 Year Member
Status: Offline
Joined: Sep 22, 2004
0.00 posts per day
Posts: 4
Points: 461
   
I was using XOOPs, just swithced to phpnuke 7.4, have to admit that it is much better. An issue that I am having is "including" a php page into phpnuke 7.4, In XOOPS, I could create a block and save it in php format with the following statement ,

<?php @include("http://radioiv.com/jamroom/chart.php"); ?>

and insert the php page in a center custom block. I have tried this with phpnuke 7.4 and it does not work. Read a post in another forum and tried doing this:

ob_start();
include ("jamroom/chart.php");
$content .= ob_get_contents();
ob_end_clean();

Didnt work.. so I tried this one:

ob_start();
include ("http://radioiv.com/jamroom/chart.php");
$content .= ob_get_contents();
ob_end_clean();

Didnt work either.... All I see on both of this is the url displayed in the block. Can someone please guide me in the right direction?? I would like to learn how to create modules, is there a "DUMMIES book on how to create modules for phpnuke???" Can someone please tell me how to include this php page?? Thanks in advance

Xfactor [ Register or login to view links on this board. ] [ Register or login to view links on this board. ]



Back to top Reply with quote
#2   re: PHP "Include" in phpnuke 7.4
SpLiNteR
CZ Addict
SpLiNteR has been a member for over 20 year's 20 Year Member
uk.gif
Occupation: Student
Age: 34
Gender: Male
Fav. Sports Team: Leeds United
Website:
Status: Offline
Joined: Feb 08, 2004
0.05 posts per day
Posts: 397
Points: 206,328
AIM Address Yahoo Messenger MSN Messenger ICQ Number
I don't know how to code blocks or use PHP-Nuke for that matter, but some of your PHP coding is slightly off.

The first include has an @ in the middle which could have stopped it from working.

<?php include(blah.php); ?>


And on the includes, as long as that file is in your site directory, always make the link relative to where it's being linked from minimize problems and such.

Hope that helps
Andre



_________________
Back to top Reply with quote
#3   re: PHP "Include" in phpnuke 7.4
xfactor151
CZ Newbie
xfactor151 has been a member for over 20 year's 20 Year Member
Status: Offline
Joined: Sep 22, 2004
0.00 posts per day
Posts: 4
Points: 461
   
Just tried that, did not work, seems that phpnuke does not let translate the saved file to php, like XOOPS. Only saves the block content in HTML. Any ideas?



Back to top Reply with quote
#4   re: PHP "Include" in phpnuke 7.4
Kelly_Hero
PayPal Donation
CZ Revered Member
 Codezwiz Site Donator
usa.gif southcarolina.gif
Occupation: Web Developer
Age: 59
Gender: Female
Website:
Status: Offline
Joined: Aug 20, 2003
0.49 posts per day
Posts: 3765
Points: 351,412
   
Have you tried the block creator?
[ Register or login to view links on this board. ]



Back to top Reply with quote
Display posts from previous:      
Add To: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
<< View previous topic View next topic >>
Post new topicReply to topic

Jump to 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum