in view.php are problematic. If you strip the slashes then you have to add them back before you use $page in database operations. But why strip them in the first place. The standard Moodle way of doing things is to keep them and only strip them when things are printed to the screen.
From Gustav Delius (gwd2 at york.ac.uk) Sunday, 16 January 2005, 05:54 AM:
I had a look and I assume the reason you strip those slashes is that ewiki likes it that way. So I simply added them back in the two places where $page is used in a database operation.
Martin Dougiamas added a comment - 16/Jan/05 05:54 AM From Gustav Delius (gwd2 at york.ac.uk) Sunday, 16 January 2005, 04:47 AM:
The lines
/// If the page has a ' in it, it may have slashes added to it. Remove them if it does.
$page = ($page === false) ? stripslashes(EWIKI_PAGE_INDEX) : stripslashes($page);
in view.php are problematic. If you strip the slashes then you have to add them back before you use $page in database operations. But why strip them in the first place. The standard Moodle way of doing things is to keep them and only strip them when things are printed to the screen.
From Gustav Delius (gwd2 at york.ac.uk) Sunday, 16 January 2005, 05:54 AM:
I had a look and I assume the reason you strip those slashes is that ewiki likes it that way. So I simply added them back in the two places where $page is used in a database operation.
The lines
/// If the page has a ' in it, it may have slashes added to it. Remove them if it does.
$page = ($page === false) ? stripslashes(EWIKI_PAGE_INDEX) : stripslashes($page);
in view.php are problematic. If you strip the slashes then you have to add them back before you use $page in database operations. But why strip them in the first place. The standard Moodle way of doing things is to keep them and only strip them when things are printed to the screen.
From Gustav Delius (gwd2 at york.ac.uk) Sunday, 16 January 2005, 05:54 AM:
I had a look and I assume the reason you strip those slashes is that ewiki likes it that way. So I simply added them back in the two places where $page is used in a database operation.