Seems to fix the case where the meta is not in the root of the epub
--HG-- extra : rebase_source : 29d9f279a5ec3debcb67c5c11c82cd268fad4931
This commit is contained in:
parent
1f65d1eb65
commit
e6d18cfbe4
1 changed files with 6 additions and 0 deletions
|
@ -171,6 +171,12 @@ class EPub {
|
|||
error_log ("Unable to find " . $path);
|
||||
return false;
|
||||
}
|
||||
$ref = dirname('/'.$this->meta);
|
||||
$ref = ltrim($ref,'\\');
|
||||
$ref = ltrim($ref,'/');
|
||||
if (strlen ($ref) > 0) {
|
||||
$path = str_replace ($ref . "/", "", $path);
|
||||
}
|
||||
return str_replace ("/", "-SLASH-", $path);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue