- Posts: 19
- Thank you received: 0
OS Property support center
Using $this when not in object context
- adam
- Topic Author
- Offline
- New Member
-
Less
More
8 years 3 months ago #91956
by adam
Using $this when not in object context was created by adam
Get blank page with error Using $this when not in object context
using J3.6.4 with PHP7.1 and OS 3.03
Any ideas why this happened?
using J3.6.4 with PHP7.1 and OS 3.03
Any ideas why this happened?
Please Log in or Create an account to join the conversation.
- adam
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 19
- Thank you received: 0
8 years 3 months ago #91960
by adam
Replied by adam on topic Using $this when not in object context
Double checked the issue is when using PHP 7.1
Please Log in or Create an account to join the conversation.
- Mr. Dam
-
- Offline
- Administrator
-
Less
More
- Posts: 12987
- Thank you received: 1681
8 years 3 months ago #91969
by Mr. Dam
Replied by Mr. Dam on topic Using $this when not in object context
Hi Adam,
Where do you use $this in OS Property?
Thanks
Dam
Where do you use $this in OS Property?
Thanks
Dam
Please Log in or Create an account to join the conversation.
- adam
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 19
- Thank you received: 0
8 years 3 months ago #91971
by adam
Replied by adam on topic Using $this when not in object context
Thats the error message I get when use PHP7.1.
Blank page only the text Using $this when not in object context on all sites.
Even on the backed under stetting i get error
Blank page only the text Using $this when not in object context on all sites.
Even on the backed under stetting i get error
Please Log in or Create an account to join the conversation.
- Mr. Dam
-
- Offline
- Administrator
-
Less
More
- Posts: 12987
- Thank you received: 1681
8 years 3 months ago #92164
by Mr. Dam
Replied by Mr. Dam on topic Using $this when not in object context
Hi Adam,
Can you send me the screenshot of that error?
Thanks
Dam
Can you send me the screenshot of that error?
Thanks
Dam
Please Log in or Create an account to join the conversation.
- adam
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 19
- Thank you received: 0
8 years 3 months ago #92189
by adam
Replied by adam on topic Using $this when not in object context
Again,
there is only a blank page with the text: Using $this when not in object context on all sites.
I switched back to PHP 7.0 and all fine.So the issue come when I switch to PHP 7.1.xxx
In frontpage all pages blank where you using OS property. In the backed when you want to go to settings in OS property
there is only a blank page with the text: Using $this when not in object context on all sites.
I switched back to PHP 7.0 and all fine.So the issue come when I switch to PHP 7.1.xxx
In frontpage all pages blank where you using OS property. In the backed when you want to go to settings in OS property
Please Log in or Create an account to join the conversation.
- adam
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 19
- Thank you received: 0
8 years 2 months ago #92343
by adam
Replied by adam on topic Using $this when not in object context
any progress?
Please Log in or Create an account to join the conversation.
- Mr. Dam
-
- Offline
- Administrator
-
Less
More
- Posts: 12987
- Thank you received: 1681
8 years 2 months ago #92344
by Mr. Dam
Replied by Mr. Dam on topic Using $this when not in object context
Hi,
Your question isn't clear, so we can't answer you. In this case, you can submit ticket and send
1. The email you entered when you purchased OS Property from us so we can verify the transaction
2. Your site url with super admin account so we can check your modification.
Dam
Your question isn't clear, so we can't answer you. In this case, you can submit ticket and send
1. The email you entered when you purchased OS Property from us so we can verify the transaction
2. Your site url with super admin account so we can check your modification.
Dam
Please Log in or Create an account to join the conversation.
- adam
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 19
- Thank you received: 0
8 years 2 months ago #92347
by adam
Replied by adam on topic Using $this when not in object context
Really not clear?
There are no modification!! Do you have a server with use PHP 7.1.xx? So you will see the error.
I track down the email as we working for them as freelancer not the owner
There are no modification!! Do you have a server with use PHP 7.1.xx? So you will see the error.
I track down the email as we working for them as freelancer not the owner
Please Log in or Create an account to join the conversation.
- Ben
- Offline
- New Member
-
Less
More
- Posts: 9
- Thank you received: 1
8 years 1 month ago #94894
by Ben
Replied by Ben on topic Using $this when not in object context
In case anyone else experienced this problem, I tracked it down to the use of JSite::getMenu();
It may be entirely unrelated, but there was an issue raised with the Joomla core here which provided a clue .
By replacing the variable definition for $menus - the problem appears to have been resolved.
The two occurrences I had to change were in :
components/com_osproperty/helpers/helper.php
[lines 4205 & 4249]
So the lines now look like this:
I'm running OS Property 3.0.9 on PHP7.1 on Apache 2.4 (MySQL 5.7).
It may be entirely unrelated, but there was an issue raised with the Joomla core here which provided a clue .
By replacing the variable definition for $menus - the problem appears to have been resolved.
The two occurrences I had to change were in :
components/com_osproperty/helpers/helper.php
[lines 4205 & 4249]
So the lines now look like this:
Code:
$menus = JFactory::getApplication()->getMenu(); //JSite::getMenu();
I'm running OS Property 3.0.9 on PHP7.1 on Apache 2.4 (MySQL 5.7).
The following user(s) said Thank You: adam
Please Log in or Create an account to join the conversation.
Moderators: Mr. Dam, Nguyen Phu Quan
Support
Documentation
Information
Copyright © 2025 Joomla Extensions by Joomdonation. All Rights Reserved.
joomdonation.com is not affiliated with or endorsed by the Joomla! Project or Open Source Matters.
The Joomla! name and logo is used under a limited license granted by Open Source Matters the trademark holder in the United States and other countries.
The Joomla! name and logo is used under a limited license granted by Open Source Matters the trademark holder in the United States and other countries.