Plugin doesn't deal with full URL paths
-
Stephen
- Tag set to custom field
I'm trying to get data using a custom field. I believe I'm having a hard time because it doesn't support full urls.
Could you please be more specific about where this code needs to go.
thanks
-
MarmaladeToday
Sure Stephen.
I added that code to version 1.0.0 for EE 1.6x at line 110, in the public function __construct() so that the file checking conditional from lines 106 onwards looks like this:
if (stristr($this->file, $_SERVER['DOCUMENT_ROOT']))
{$this->file = $this->file;} else if (stristr($this->file, $_SERVER['SERVER_NAME']))
{$parts = parse_url($this->file); $this->file = $_SERVER['DOCUMENT_ROOT'] . $parts['path'];} else
{$this->file = $_SERVER['DOCUMENT_ROOT'] . $this->file;}
Hope that helps,
Aidann
-
MarmaladeToday
Sorry, should have checked the formatting of that before posting. Let's try that again:
if (stristr($this->file, $_SERVER['DOCUMENT_ROOT'])) { $this->file = $this->file; } else if (stristr($this->file, $_SERVER['SERVER_NAME'])) { $parts = parse_url($this->file); $this->file = $_SERVER['DOCUMENT_ROOT'] . $parts['path']; } else { $this->file = $_SERVER['DOCUMENT_ROOT'] . $this->file; } -
Stephen
- Tag changed from custom field to custom field, plugins page, white screen
This helped a lot.
This might be another ticket.
I had to reinstall EE due to other issues. After I uploaded the file oracle plugin, I can't access my plugins page. I just get blank white screen. If I remove file oracle, my plugins page works fine. -
Stephen
I'm also on EE 2.1.0
-
MarmaladeToday
Yes, this sounds like a different ticket.
Which version of File Oracle are you using?
v1 is for EE 1.x
v2 is for EE 2.x -
George Ornbo
- State changed from new to open
Aidaan
Thanks for that. You are right - the plugin doesn't currently support full paths.
I'll roll your fix into the next release (no commitments on dates I'm afraid!)
Stephen - it sounds like your issue is a PHP error. In order to find out what this if the error is in your control panel you can edit /system/index.php and set debug = 1 to display PHP errors.
-
MarmaladeToday
Hi George,
Just thought I'd report that this fix is also needed (and appears to work) in both __construct() and get_file_data() too for the EE2 version.
Aidann
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.