Poco
Forum Replies Created
-
Forum: Plugins
In reply to: [Google Calendar Widget] 403 Forbidden on Cal URL – Deprecated API?I was thinking about it, and it now that they are tracking the number of queries, and the data is pretty static, it should be possible to reduce the traffic to their site by caching this on our own servers.
If anyone is concerned about more than 500,000 queries per day on their site (I’m not) then it will make sense to cache the data. Given your question about authentication, we should be able to do some sort of private authentication on the WordPress server to get the data and then surface it however you want. So both problems would be solved by doing the query server side.
It means moving the query in to PHP (I believe there are libraries available) and surfacing it through the wordpress pages using the wordpress Auth and caching the results for some time.
This might be a bit beyond the scope of what I am able to do in the near future. But if someone else wants to take it on, that sounds like a new plugin.
Forum: Plugins
In reply to: [Google Calendar Widget] 403 Forbidden on Cal URL – Deprecated API?Can you check the javascript console from your browser? It will include more detail of the errors you are getting and the server responses. They often include some useful error messages.
If you web page is public can you post the link so that I can take a look at it?
Forum: Plugins
In reply to: [Google Calendar Widget] 403 Forbidden on Cal URL – Deprecated API?Ya, that is Chaser324 who started this thread 😉
I have a branch now with the first iteration of the fix. It should be good, and I have no reason to believe it doesn’t work, it just needs some settings updates and a bit more testing.
For those willing to try it out, you can download the plugin source directly from the branch found here.
https://plugins.trac.wordpress.org/browser/google-calendar-widget/branches/upgrade_to_v3
Only ko_calendar.js and ko_calendar.php are changed. I don’t know of a good way to download a branch as a zip file, so you have to download the individual files for now.
I have not added a field in the settings for entering your Google API key, so you need to manually replace the string “YOUR API KEY HERE” in ko_calendar.js with your Google API key.
To create a Google API Key, go to https://console.developers.google.com.
- Create a project for your web site, if you don’t already have one.
- Select “APIs” under “APIs and Auth” (left menu)
- Enable “Calendar API”.
- Go to the “Credentials” page.
- Click on “Create New Key”.
- Select “Browser Key”.
- Add your URL to the referrer box or leave it blank to allow any referrer. I would leave it blank for testing and once you have it working change the rules later.
- After you create the key you will be shown the full key.
- Copy that key into ko_calendar.js by replacing “YOUR API KEY HERE”.
- Wait a few minutes. It seems that it can take a minute or two before the key is functional on their system.
The Calendar “URL”s are now IDs so you should edit your widget settings and change the URL to an ID. The IDs look like an email address.
Give it a go and let me know if you have any trouble.
Forum: Plugins
In reply to: [Google Calendar Widget] 403 Forbidden on Cal URL – Deprecated API?Update: I am getting close to a solution. It is actually a fairly straightforward transition from the old API to the new API.
I expect to have something ready to go for today or tomorrow. I’m updating the settings and testing some edge cases. If I have a preview I will post it here.
The main changes are that the calendar ID is no longer going to be the URL of the calender, but instead it will be just the id. So instead of “http://www.google.com/calendar/feeds/yourcalendar@gmail.com/public/full”, you will use just “yourcalendar@gmail.com”.
You will also need to get a Google API Key and set that in the plugin settings. I will include instructions.
Forum: Plugins
In reply to: [Google Calendar Widget] 403 Forbidden on Cal URL – Deprecated API?I am working on it now. No ETA yet but I will try to get it working as soon as possible.
Forum: Plugins
In reply to: [Google Calendar Widget] 403 Forbidden on Cal URL – Deprecated API?Thanks for the quick response and for hacking something together. This is the first I have heard of any issues and I will take a look asap since I have my own sites that still use this plugin.
I’m not sure I understand. It has been a while since I’ve worked on it, but I don’t recall any “view details”. My guess, however, is that even if that was there, it won’t show the same thing for other users as it does for you, since it is your calendar.
The best way to check what other people will see is to open an private browsing window (or incognito or whatever it is called in your browser) and view your page there. This will show you what people who are not logged into your Google Account will see.
Forum: Plugins
In reply to: [Google Calendar Widget] Centering in the widgetI think you have a different plugin installed for your calendar. It is not Google Calendar Widget
Forum: Plugins
In reply to: [Google Calendar Widget] Can't get calendar to feedThat is a different calendar. It is this one without the prefix “games”.
http://www.google.com/calendar/feeds/calendar%40dbifgs.org/public/full
Forum: Plugins
In reply to: [Google Calendar Widget] Can't get calendar to feedThe reason that your calendar is empty is because there are no future events.
The calendar URL is below and it contains only two events, both of which ended earlier in the month.
http://www.google.com/calendar/feeds/gamescalendar%40dbifgs.org/public/full
Forum: Plugins
In reply to: [Google Calendar Widget] Change date format without modifying JavascriptGood suggestion. I would be happy to consider integrating the changes if someone made it, otherwise it will have to wait until I have time.
Forum: Plugins
In reply to: [Google Calendar Widget] Ordinal suffix supportNot sure. It might be that the plugin uses a really old version of date.js. It might be worth trying to upgrade to the latest version by downloading the source from the Google code project. I will do the same when I have time.
Forum: Plugins
In reply to: [Google Calendar Widget] More than 3 calendars in sidebarTo add more calendars would require changing the code in the plugin. If you look in ko_calendar.php for “url3” you will see where the URLs are declared and duplicated. You could either fix this to come up with a more generic system that supports any number of calendars or add to the existing urls by duplicating everywhere you find “url3” and make a “url4” and “url5”.
What I have started to do where I need multiple calendars in one is that I merge them into one new calendar in Google Calendar. If you invite a calendar “address” (Look for Calendar Address in the settings) to an event as a guest, the event will be shared in both calendars. If it is edited in one calendar it will be updated in all the invited calendars.
I have created a central calendar for my club and all events are created there. Then each individual calendar that wants to see that event is invited as a guest. This is very flexible as it means that I only have to share and display one calendar address for any individual calendar, but each one displays exactly what the users need from it.
Forum: Plugins
In reply to: [Google Calendar Widget] Can't get calendar to feedDo you have a link that I can look at or any output from your JavaScript console? It is hard to debug without some information.
Forum: Plugins
In reply to: [Really Simple Share] Add Support for Bitcoin! 'coinwidget.com'I have created a shortcode plugin for coinwidget.com here http://wordpress.org/plugins/coinwidget-shortcode/