Hi, I have a problem modifying the information on the site.
Application Version - OJS 3.2.1.2
Error 403
Forbidden
You don’t have permission to access /index.php/islas/api/v1/contexts/1 on this server.
Hi @Frank_Enrique_Sanche ,
Are you trying to access the API. I don’t have a lot of familiarity with using the API, so someone else may have to comment, but, in case you haven’t seen it, our API documentation might be of some help: REST API Usage Guide
-Roger
PKP Team
marc
May 25, 2021, 9:12am
3
Looks like a mod_rewrite issue.
In short: On 3.x, you need special rules for the API url.
Take a look to this post from Antti-Jussi:
opened 05:14PM - 12 Jul 19 UTC
closed 08:51PM - 22 Oct 19 UTC
**Describe the bug**
See: https://forum.pkp.sfu.ca/t/errors-after-removing-inde… x-php/31314
and: https://forum.pkp.sfu.ca/t/ojs-3-1-2-1-journal-statistic/54224/4
**To Reproduce**
Steps to reproduce the behavior:
1. Add a context specific base url which masks the context shortname, e.g.: `base_url[journal] = https://my.journal.com`
2. Navigate to the Article Statistics (Dashboard -> Statistics -> Articles)
3. Enter some text in the Article Details search
4. Result will be 404s from the application API calls
**What application are you using?**
OJS 3.1.2
**Additional information**
Core problem appears to be here:
https://github.com/pkp/pkp-lib/blob/27eeff555bdcfa6da9f787d259184b1cfacff025/classes/handler/APIHandler.inc.php#L174
This pattern requires the URL to contain the context key.
My trace through the code to find this is documented here:
https://forum.pkp.sfu.ca/t/errors-after-removing-index-php/31314/33?u=ctgraham