David Matthew
Forum Replies Created
-
Forum: Plugins
In reply to: [Guillotheme] Redirection should skip wp-sitemap.xmlHi @brynzovskii, just to update you, I’m using the below code at the moment and it works for sitemaps generated by plugins like Slim SEO (the one I use) but for some reason I haven’t yet figured out, it’s not working for WordPress-generated sitemaps.
/** * The redirect function. */ public function redirect() { $options = get_option( 'guillotheme_settings' ); if ( $options['skip_sitemap'] !== null ) { // This should catch anything containing both 'sitemap' and '.xml' $regex = "/^.*?\bsitemap\b.*?\bxml\b.*?$/"; $req = esc_url( $_SERVER['REQUEST_URI']); if ( preg_match( $regex, $req ) ) return; } if ( ! is_admin() ) { ...
As you can see I’m using a regex to catch any kind of sitemaps (as I figured they all must have ‘sitemap’ and ‘.xml’ in common) and comparing with the request URI using
preg_match()
. I didn’t go withstr_contains()
as it’s supported only in PHP 8+.Could you maybe try this code on your site (or a variation of it – ignore the
$options['skip_sitemap']
bit) to see if it’s something server-related on my end? If you can’t it’s ok, I’ll try to track down whatever it is that’s going wrong. May not get the time in the next few weeks though as I’ll be away.- This reply was modified 3 years, 5 months ago by David Matthew.
Forum: Plugins
In reply to: [Guillotheme] Redirection should skip wp-sitemap.xml@brynzovskii Thanks for the suggestion – I’ll update the plugin to include this as an option! Once done (hopefully can get some time this weekend) I’ll reply back here and let you know. ??
Forum: Reviews
In reply to: [Ventus - Weather Map Widget & Shortcode] Extremely Helpful and Beautiful!Hi Sarah,
Thanks so much for the review! I really appreciate the kind words.
I will be updating the widget as soon as I can, and will certainly take your suggestions on board.
Thanks again,
DavidForum: Plugins
In reply to: [Ventus - Weather Map Widget & Shortcode] Wrong WeatherHi Jennifer,
When I checked, I didn’t see any difference in the temperatures showing on the widget versus the website?
Screenshot of the widget on your website: https://snipboard.io/dnSIlu.jpg
Screenshot of the windy.com website: https://snipboard.io/8MQlm0.jpgGroveland for instance I can see on both as 89°.
When interacting with the widget, just be aware that it can be quite easy to accidentally change the forecast time when zooming in for instance, which is something I did. I then noticed some temperature discrepancy like you described.
Hope this helps.
Thanks,
DavidForum: Reviews
In reply to: [Ventus - Weather Map Widget & Shortcode] Nothing but Awesome! Thanks!Delighted to read it, thank you! ??
Forum: Reviews
In reply to: [Ventus - Weather Map Widget & Shortcode] Ein tolles WidgedDelighted to read that iMacfux, thank you for the review! ??
Forum: Plugins
In reply to: [Ventus - Weather Map Widget & Shortcode] Multiple maps on a same pageHi there dfpjusa,
Thanks for reaching out, and I’m delighted to hear you like the plugin! ??
I’ve looked at the page in question and it’s the first time I’ve seen this behaviour. On this test page for instance I have three instances of the widget showing, all with the forecasts enabled: https://davidmatthew.ie/ventus-test/
Just as a test, if you have the accordions auto-expanded do they load properly then?
Kind regards,
DavidForum: Plugins
In reply to: [Ventus - Weather Map Widget & Shortcode] Location IncorrectHi ctcns,
Thanks for reaching out.
When I inspect the iframe on your page, I can still see the default value (53.199) as the latitude. This usually happens when the shortcode contains incorrect formatting, usually due to the inverted commas used.
I’ve re-formatted the shortcode if you want to try pasting this in instead?
[ventus width="100%" height="600px" radius="20px" lat="44.096" lon="-64.240" zoom="4" layer="wind" scale="C" units="km/h" pressure="true" marker="true" forecast="true" time="12"]
Hope this helps.
Thanks,
DavidForum: Plugins
In reply to: [Ventus - Weather Map Widget & Shortcode] Forecast hangs in frameMarking as resolved as unable to replicate issue.
Forum: Plugins
In reply to: [Ventus - Weather Map Widget & Shortcode] Forecast hangs in frameHi aggieoutlaw8, sorry to read that. I haven’t been able to replicate what you’re experiencing on my own site: https://davidmatthew.ie/ventus-test/
I tried to replicate using the widget (on the page sidebar) and using the direct embed from windy.com and didn’t see the forecast hang in either.
Does the same thing happen using a default theme (like twentytwenty) and with all other plugins disabled?
I don’t see anything obvious, I’ve tried the same settings and it’s displaying in the right area for me?
Settings: https://snipboard.io/uHdFvL.jpg
Result: https://snipboard.io/EyTM6V.jpgYour longitude seems to be set to the default (approx. at the same height as Dublin). The issue could be related to caching, I’m not sure. But it does seem the settings are ok and I wasn’t able to replicate the issue.
If you still need assistance you could use a service like https://snipboard.io/ and link to the screenshot? I’d need to see the widget settings so I could replicate what you’re experiencing. Thanks
Hi there,
The widget may be reverting to the default value for the longitude if it has too many figures after the decimal place. Try shortening it to -0.118 and let me know how you get on. If you’re still experiencing issues, please share the url to where you have the widget embedded.
Hope this helps.
Thanks,
DavidForum: Plugins
In reply to: [Ventus - Weather Map Widget & Shortcode] Static Code Block?Ah ok, thanks for clarifying aggie. I don’t have a workaround for this I’m afraid. You might need some custom JavaScript for this, maybe using the Geolocation API?
Forum: Plugins
In reply to: [Ventus - Weather Map Widget & Shortcode] Static Code Block?Hey aggie, if you have to reload a few times there might be some browser or server caching going on, it’s hard to say. I haven’t experienced that on my own site.
How would we use the lat long from the post itself?
I’m not fully sure what you mean here? The easiest way to get whatever latitude and longitude you need would actually be to go straight to windy.com and make note of the first two numbers after the URL, e.g. windy.com/?53.338,-6.259; you can use these as your arguments then in the iframe src URL, like so:
lat=53.338&lon=-6.259
Hope this helps!
- This reply was modified 3 years, 11 months ago by David Matthew.
- This reply was modified 3 years, 11 months ago by David Matthew.