Open homepinr opened 5 years ago
Thanks Rene,
This is really helpful - here's what the response in the API looks like when we visit here:
https://api.thegreenwebfoundation.org/data/directory
{
"iso": "BE",
"id": "651",
"naam": "Kinamo SA",
"website": "https://www.kinamo.be/",
"partner": null
}
So, this makes me think the code in the attachDirectory
function in the WP theme is the problem:
https://github.com/thegreenwebfoundation/tgwf2015/blob/master/js/directory.js#L15
Updating the template generation code would be the first place I'd check here, as it's using a bunch of nested if-statements at the mo, and revisiting this would be worthwhile.
There is some bug in the admin-code, that results in urls from hosters that are put into the system, in the format starting with 'http://' of 'https://' being displayed, without the ':' in the green web directory on the site, even while the input looks OK in the admin-environment:
So this Belgian hoster details look OK, but when I click on the url, I get referred to 'http//www.kinamo.be', so the ':' has somehow dropped out.
When looking at the Green Hosting Directory on the site, the same thing happens (see down left for referring url:
Ideally, we would want to solve this in a way that the system becomes a bit more agnostic to the exact format: as well http, https, www as directname.topdomain should do it in practice.
If someone could address this issue (probably it is in the wordpress-code!), would be awesome!