phpBB

Development Discussion Board

phpBB's testing ground of bleeding edge code
Advanced search

Includephp tag

All style (template, theme and imageset) related questions for the new release; advice, feedback here please.

Re: Includephp tag

Postby ChrisRLG » Tue Feb 06, 2007 2:02 pm

You may have done what I did.

I have two admin accounts - the first I do not use - its my backdoor access if anything happens to my active one.

BUT that first admin account was what received the founder admin status when I did my test update to phpBB3b5.

So did you do the same - is the founder admin in your other account.
User avatar
ChrisRLG
Registered User
 
Posts: 160
Joined: Wed Oct 11, 2006 9:47 am

Re: Includephp tag

Postby Nicholas the Italian » Tue Feb 06, 2007 2:46 pm

ChrisRLG wrote:BUT that first admin account was what received the founder admin status when I did my test update to phpBB3b5.

Yes, he's not the founder probably.
This has changed in CVS: all phpbb2 admins will become phpbb3 founders.
User avatar
Nicholas the Italian
Registered User
 
Posts: 659
Joined: Mon Nov 20, 2006 11:19 pm
Location: 46°8' N, 12°13' E

Re: Includephp tag

Postby BossDK » Tue Feb 06, 2007 6:13 pm

Yes, that's it! I remember from the completion of the conversion process ,that I swiched to the #1 user from my old database, which is not me. Thanks for the clear up, I can modify the DB directly to give me the nessary access!

Thanks a lot Wink
test
BossDK
Registered User
 
Posts: 8
Joined: Sun Jan 11, 2004 6:34 pm

Re: Includephp tag

Postby Highway of Life » Tue Feb 06, 2007 7:05 pm

To set yourself to Founder Status:
Code: Select all
UPDATE phpbb_users SET user_type = 3, user_permissions = '' WHERE user_id = x

x = YOUR user_id.
Image
User avatar
Highway of Life
Registered User
 
Posts: 1399
Joined: Tue Feb 08, 2005 10:18 pm
Location: I'd love to change the World, but they won't give me the Source Code

Re: Includephp tag

Postby Kaade » Mon Mar 12, 2007 4:34 am

Okay, it's been quite some time since I worked on this concept, but I've just finished a working version of the template.
Basically, it's quite easy to implement:
overall_header.php, Line 1:
Code: Select all
<!-- PHP -->
   //Load the Joomla page
   $file = file_get_contents("http://localhost/exordium/joomla/index.php?option=com_content&task=view&id=13&Itemid=27");
<!-- ENDPHP -->


That page you see there is just a blank page. It does not matter where it is because you can replace the Joomla breadcrumb with the phpbb breadcrumb.

overall_header.php, where you want to replace a joomla tag (eg the breadcrumb):
Code: Select all
<!-- PHP -->
   //Breadcrumb
   $startc = strpos($file, "<!-- Start Crumb -->");
   $part = substr($file,0,$startc);
   
   //Print our part out
   echo $part;
<!-- ENDPHP -->
<!-- PhpBB Crumb Start -->
<!-- INCLUDE breadcrumbs.html -->
<!-- PhpBB Crumb End-->
<!-- PHP -->
   $endc = strpos($file, "<!-- End Crumb -->");
   $len = strlen($file);
   $file = substr($file,$endc,$len-$endc);
<!-- ENDPHP -->


overall_footer.php, end of file:
Code: Select all
<!-- PHP -->
   $endc = strpos($file, "<!-- End Other Footer -->");
   $len = strlen($file);
   $file = substr($file,$endc,$len-$endc);
   echo $file;
<!-- ENDPHP -->


Basically, it just replaces things in the Joomla template (for me, it was <!-- Start Section --> through to <!-- End Section -->) with stuff you define in the phpbb template.

Does anyone see any major issues with this, appart from relying on Joomla to be up the whole time? (Specifically performance related)
Image
Kaade
 
Posts: 6
Joined: Sat Jul 08, 2006 12:53 pm

Re: Includephp tag

Postby Kaade » Sat Mar 17, 2007 1:15 am

to see this in action, visit http://forums.exordiumonline.com/ the joomla install is located at http://www.exordiumonline.com/
Note: it breaks with SEF on joomla, because it adds a <base href="joom url"> to the head, but that's easily removed in the first file loading section :)
Image
Kaade
 
Posts: 6
Joined: Sat Jul 08, 2006 12:53 pm

Re: Includephp tag

Postby bob175 » Sat Feb 07, 2009 4:53 pm

Is there a limit to using the include tage on a php page? I'm trying to use it to show 5 RSS feeds and for some reason, only two will show at a given time. I can't get 3 or more to show - is this a problem/limit on my server or phpbb?
bob175
Registered User
 
Posts: 5
Joined: Sat Feb 07, 2009 12:57 am

Re: Includephp tag

Postby bob175 » Sun Feb 15, 2009 7:02 pm

Anyone know if there is a limit on phpincludes?
bob175
Registered User
 
Posts: 5
Joined: Sat Feb 07, 2009 12:57 am

Previous

Return to [3.0/Olympus] Styling

Who is online

Users browsing this forum: No registered users and 7 guests