News:

Wondering if this will always be free?  See why free is better.

Main Menu

Include another file

Started by 0x00000000, July 31, 2018, 03:08:23 PM

Previous topic - Next topic

0x00000000

Hi all,

I've some problem with including another php file in my index template.. It gives me error 505 or just won't load page..
At the top of index page I put include "QueryAPI.php";
Can someone explain me how it can be added?
Thanks in advance.

Arantor

What does the file do? Including into the template is a bad idea.

0x00000000

Show info about game server via IP and PORT(name, status, etc..).
Can you share your ideas cause this won't work via template.

Illori

what is the contents of your file and where do you want the information to show up?

0x00000000

File is attached.
In index.template.php, function template_body_above

Arantor

Including that file on its own will do absolutely nothing - it's just a class, it just defines some things that can be called.

But the other question is super important: where should the results of this be shown anyway?

SychO

Just out of curiosity, what type of game server are you trying to query
Checkout My Themes:
-

Potato  •  Ackerman  •  SunRise  •  NightBreeze

d3vcho

Quote from: SychO on August 01, 2018, 06:56:36 AM
Just out of curiosity, what type of game server are you trying to query

I'm guessing it's a SA:MP (San Andreas Multiplayer) server.
"Greeting Death as an old friend, they departed this life as equals"

0x00000000

Quote from: Arantor on July 31, 2018, 03:47:46 PM
Including that file on its own will do absolutely nothing - it's just a class, it just defines some things that can be called.

But the other question is super important: where should the results of this be shown anyway?
Under <body> element, something like a banner.

Arantor

*Where* under the <body>? You can't just jam it in at the top of the page because that'll break the rest of the layout.

Advertisement: