Page 1 of 1

Block for Psychostats and amxbans

Posted: 4. October 2009 04:49
by blastman
Hello mike im trying to integrate this http://www.solid-gaming.com/Psychostats/ and this http://www.solid-gaming.com/amxbans/ into its own custom block. Maybe a psychostats_body.html and a amxbans_body.html could you help me out with this please and thank you.


Justin

Re: Black Smoke Style

Posted: 4. October 2009 05:05
by Mike
You want to add such a huge Site to a Block? How should it work? It wont fit ;)

PS: i moved this Question cause it has nothing to do with the BlackSmoke Style...

Re: Block for Psychostats and amxbans

Posted: 4. October 2009 05:38
by blastman
Im still very new to php and html coding/ scripting but with little time to read and trial and error i came up with this mike take a look :)I made a amxbans.php file>>>>

Code: Select all

<?php
    define('IN_PHPBB', true);
    $phpbb_root_path = (defined('PHPBB_ROOT_PATH')) ? PHPBB_ROOT_PATH : './';
    $phpEx = substr(strrchr(__FILE__, '.'), 1);
    include($phpbb_root_path . 'common.' . $phpEx);

    // Start session management
    $user->session_begin();
    $auth->acl($user->data);
    $user->setup();

    page_header('AMXBANS');

    $template->set_filenames(array(
        'body' => 'amxbans_body.html',
    ));

    page_footer();
    ?>
    //--Made for Solid-gaming.com by bLa$tMaN\\
Also i used this as my block amxbans_body.html>>>

Code: Select all

<!-- INCLUDE overall_header.html -->


    <div class="panel">
       <div class="inner"><span class="corners-top"><span></span></span>

       <div class="content">
         
 <IFRAME src="http://www.solid-gaming.com/amxbans" width="100%" height="1000"
             scrolling="auto" frameborder="1">
  </IFRAME>

       </div>

       <span class="corners-bottom"><span></span></span></div>
    </div>

    <!-- INCLUDE overall_footer.html -->
And this is what i came up with which worked great for me and was rather easy :)
http://www.solid-gaming.com/amxbans.php

Re: Block for Psychostats and amxbans

Posted: 7. October 2009 15:23
by Teksonic
The only way you could get that into a block, (unless you have access to the sql info from that site) is by creating a block with an iframe in it, and using that iframe to load the page. but yes, that would make either a huge block as mike said. or a block that has to be scrolled around to see everything.

now if you have access to the sql db then you could pull the info you want and structure it in whatever way you like in a block.

as for hte code you posted, yes that would make a custome block, as long as you made the .html body file to go with it.

Re: Block for Psychostats and amxbans

Posted: 7. October 2009 19:03
by Dr Nick^
as it looks this amxbans is hosted local, as most of this.
you dont need to make it with an iframe.

if you have all info for the db, and know a little about coding/sql you can put it down yourself.
pretty easy even.

since you cant print data out that eazy and dont wanna flood your db everytime page loads i used something simmilair for eqdkp latest items block
(http://interlopers.interfrommars.nl)
/portal/block/<yourmod>.php | whole sql blurry, set a portal variable content from dql blurry
/styles/<yourstyle>/template/portal/block/<yourmod>.html | Display the content of variable inside the correct box/block style.

everything depends on what info you wanna use.
name + STEAM_ID? or also server name? or also time? or reason? or banner?
basic portal is 180 width for a block, so count what info you can put into it ;)