EzPortal - Portal Software for Forums

EzPortal - Made to Fit Your SMF Forum - Glad You Found Us!
+- +-

UserBox

Welcome, Guest.
Please login or register.
 
 
 
Forgot your password?

+- Recent Posts

Smiley missing in shoutbox 2.1.4 by hustreamload
July 26, 2023, 08:14:02 am

Re: Theme Select Box question? by Shades
March 15, 2023, 06:49:49 pm

Re: Theme Select Box question? by Shades
March 09, 2023, 02:09:24 pm

Re: Theme Select Box question? by Shades
March 09, 2023, 01:55:53 pm

Re: Theme Select Box question? by EzPortal
March 09, 2023, 01:47:42 pm

Re: Theme Select Box question? by Shades
March 09, 2023, 01:34:07 pm

Re: Theme Select Box question? by EzPortal
March 09, 2023, 12:20:17 pm

Re: Theme Select Box question? by EzPortal
March 02, 2023, 11:26:15 pm

+- HTML Menu


Sample HTML Block Usage - You May Custom Code it, as needed!

Recent Topics ezBlock

Smiley missing in shoutbox 2.1.4 by hustreamload
July 26, 2023, 08:14:02 am

Theme Select Box question? by Shades
March 15, 2023, 06:49:49 pm

Where is the facebook button color? by EzPortal
February 28, 2023, 06:45:09 pm

Display on Mobile - SMF 2.1.3 and EZ 5.5.2 by BugginIn
December 29, 2022, 04:07:13 pm

Blocks Help by Riggs1973
November 20, 2022, 12:59:30 pm

Surface ol lite theme release Free! by Steffen K.
November 18, 2022, 03:57:24 am

Undefined index: href by EzPortal
October 04, 2022, 08:49:59 pm

SMF-ezportal_column_5.cache): failed to open stream: No such file or directory by EzPortal
June 04, 2022, 11:40:13 am

Arcade block error: failed to open stream: No such file or directory by Shades
May 20, 2022, 02:47:13 pm

ezPortal 5.5 by EzPortal
May 20, 2022, 09:59:30 am

Author Topic: Need help with a php block please.  (Read 14846 times)

0 Members and 1 Guest are viewing this topic.

Offline ratr

  • Posts: 2
  • Karma: 0
  • Gender: Male
Need help with a php block please.
« on: November 20, 2010, 01:57:55 am »
I have a php orientated league program. The writer of the program has this simple instruction to show the league ladder on a website: <?php include ("pokerleague_.php"); ?>

I have set up a php block for the bottom of my page but using the above example gives me the following message within the block of ezBlock unable to run PHP syntax error! .

I have tried putting the following options after the first " and before pokerleague_.php.

http://www.mydomain name/tester/
/home/ratr/public_html/mydomain name/ezportal/
("../tester/pokerleague_.php")
and even tried \ instead of /


No luck so far, I'd really like to get my league ladder to show in a block rather than include it in the site code. I'd ask the writer of the program however while he mentions a help forum I can not find a link to it on his site or in the readme within the software.
any help would be appreciated, as giving me a little information is like handing a stick of dynamite to a lunatic which should explain that my php knowledge is about .01%
I'm running SMF 2.0 RC4 with the latest version of ezPortal.

Thank You

Offline EzPortal

  • Administrator
  • *****
  • Posts: 1298
  • Karma: 67
Re: Need help with a php block please.
« Reply #1 on: November 20, 2010, 07:15:38 am »
Use just include ("pokerleague_.php");
Like ezPortal? Support me at https://www.patreon.com/vbgamer45/

Offline ratr

  • Posts: 2
  • Karma: 0
  • Gender: Male
Re: Need help with a php block please.
« Reply #2 on: November 20, 2010, 03:45:52 pm »
Thank You for your reply, but that didn't work. It just left it blank. So I thought I would try putting a copy of the pokerleague_.php in the same folder as the forum in case that was the problem. It game me an error and from that I copied the directory structure it said it was trying to access.

So I then tried
include ("/home/ratr/public_html/mydomain name.com/tester/pokerleague_.php"); and it works  :)   however without your prompt to my problem and my newbieness (if that is a word) trying everthing (and a bit of luck too) I'd still be at it.

So thank you for your time and effort, without such I would not have the block I wanted working i'm certain.

Offline DenDen66

  • Newbie
  • *
  • Posts: 46
  • Karma: 0
Re: Need help with a php block please.
« Reply #3 on: September 22, 2015, 07:52:28 am »
On this PHP issue. the

Code: [Select]
include (name_file.php); works.

However, if I move my file to another domain name: example http://otherdomainname.com/

and us this code:

Code: [Select]
include (http://otherdomainname.com/name_file.php);
It does not work.

What I my missing?

I have tried using  Ratr approach as well

Code: [Select]
include ("/home/ratr/public_html/mydomain name.com/tester/pokerleague_.php");
and it did not work either.

I am using SMF 2.0.11 and I am trying to fetch a file that is used by several forums all the time and I do want to use one copy of this file, because it does change from time to time.

Thanks for your help




Offline Maxx

  • VN Vet E4
  • Hero Member
  • *****
  • Posts: 560
  • Karma: 8
  • Gender: Male
  • Web Designer
    • SurfaceThemes - Web Design Ideas Classic Rock
Re: Need help with a php block please.
« Reply #4 on: September 22, 2015, 08:54:07 am »
Denis,

More then likely EZ, will need to assist you on this, but ezblocks some times, take time to fetch RSS feeds and other stuff, so please try to give it chance to fetch, before making alterations in code@!

regards,
Maxx
If you find this Portal System useful, please consider supporting us with a small Donation!
Check out the How to Section!!
Please remember to keep your back ups, up to date, before you try anything new!

Offline DenDen66

  • Newbie
  • *
  • Posts: 46
  • Karma: 0
Re: Need help with a php block please.
« Reply #5 on: September 22, 2015, 09:53:55 am »
Denis,

More then likely EZ, will need to assist you on this, but ezblocks some times, take time to fetch RSS feeds and other stuff, so please try to give it chance to fetch, before making alterations in code@!

regards,
Maxx

Thanks for your answer Maxx.

I understand your point. However, when I use this code:

Code: [Select]
include (name_file.php);
It appeares almost instantly.

So what you are telling me is that if the information it need to fetch is on another domain, it will take more time, even if it is on the same server? Ok so I have no problem with that,

The question then is the following: should the following code work to go and get the information that is on another domain.

Code: [Select]
include ("http://otherdomainname.com/name_file.php");
I imagine it should, but when I try it it does not.

Offline EzPortal

  • Administrator
  • *****
  • Posts: 1298
  • Karma: 67
Re: Need help with a php block please.
« Reply #6 on: September 22, 2015, 11:21:34 am »
This topic may help you Denis on the remote include
http://stackoverflow.com/questions/9038694/fopen-is-not-working-on-my-server
Like ezPortal? Support me at https://www.patreon.com/vbgamer45/

Offline DenDen66

  • Newbie
  • *
  • Posts: 46
  • Karma: 0
Re: Need help with a php block please.
« Reply #7 on: September 22, 2015, 12:36:45 pm »
It worked. It was the allow-url-fopen that was not activated. Now it is. ;-)

Thank you

Offline EzPortal

  • Administrator
  • *****
  • Posts: 1298
  • Karma: 67
Re: Need help with a php block please.
« Reply #8 on: September 22, 2015, 01:09:15 pm »
Glad to help
Like ezPortal? Support me at https://www.patreon.com/vbgamer45/

 

Related Topics

  Subject / Started by Replies Last post
2 Replies
6746 Views
Last post September 30, 2014, 10:24:54 pm
by EzPortal
0 Replies
4141 Views
Last post May 22, 2016, 04:39:46 pm
by Miker1029
2 Replies
5709 Views
Last post February 07, 2017, 07:55:45 am
by landyvlad
3 Replies
10593 Views
Last post May 17, 2021, 01:05:41 pm
by EzPortal
3 Replies
4651 Views
Last post August 21, 2021, 11:06:47 pm
by EzPortal

+-SMF Gallery

Quick Menu


Powered by EzPortal