elementor / elementor/wp2static
Spaces in URL file asset results in 404, file not copied over during Crawl
Open
bug
- Dominant language
- PHP
- Stars
- 1.5k
- Forks
- 294
- PR merge metrics
- No merged PRs in 30d
Description
In ```7.0-alpha-007```, I have some file assets under ```wp-uploads``` containing spaces, e.g. ```spaces are bad.jpg```, resulting in a 404 response during the crawl; subsequently, those files aren't copied over to the ```wp2static-crawled-site``` folder.
Not sure if it's the best place/method to handle it, but modifying ```Crawler->crawlUrl()``` at line 185 resolves the issue:
```diff
+ $encoded_url = str_replace(' ', '%20', $url);
+
+ $response = $this->request->getURL( $encoded_url, $handle );
- $response = $this->request->getURL( $url, $handle );
```
Contributor guide
Assessment
This issue has not been assessed yet.