A tool for coordinating presents.
We all know the drill: It's christmas really soon, and you have to figure out both your own wishes, and what to give to others. It can be a pain to coordinate properly with a lot of mailing/calling/texting back and forth to figure out who buys what to whom. With this easy-to-use tool, the participants can write their own wishes, see other people's, and reserve/unreserve gifts.
You can try a demo at http://projects.psylicium.dk/onskedemo/
All you need is a webhost which supports PHP 7.0, and access to a MySQL database.
Create a new empty database, and import the included
/mysql/dbcreate.sql. This will create the required tables.
Set the necessary variables for connecting to the database in
// Database host $dbhost = "<YOUR_DATABASE_ADDRESS>"; // Database username $dbusername = "<DATABASE_USERNAME>"; // Database password $dbpassword = "<DATABASE_PASSWORD>"; // Database name $dbname = "<DATABASE_NAME>";
func.phpand enter som bacic settings for your site:
An invite code and mail settings (where the registration mail with the password will be sent from):
$mailfrom = "From: Wishably <email@example.com>"; $invite_code = "<invite-code>";
The title of your site:
The URL of your site:
$basedir = "http://mysite.com/wishably/";
The language (refer to /lang/languages.txt for supported languages):
This should be it! Simple, eh?
A text field can be added below the wishlist on the front page (welcome message, instructions etc.), but this is disabled by default. To enable it, open
index.php and edit the variables at the top:
$display_text = 0; $page_text = 'This is displayed in the text field below the wishlist';
$display_text sets whether the text field is shown.
0 disables it,
1 enables it.
$page_text contains the text you want to show. You can use standard HTML formatting.
You can also display a list of the registered users at the bottom of the wish list:
$display_users = 1;
This is enabled by default, but you can disable it by setting
$display_users = 0; in
The application is multilingual, and can be displayed in whatever language it is translated into. You can set the display language in
func.php by changing
include('lang/lang_XX.php') where XX being the language. Check
/lang/languages.txt for more info and current translations.
For easy management, I have included an admin section where you can either delete all current wishes (but leaving user information) or wipe the entire database for easy reuse.
First thing to do after setting up
After the above steps are completed, the first thing you'll need to do is create an administrator account. This is done by going to /admin/createadmin.php and entering your desired login details. It will set the
admin cell to 1 in the database. You have to delete or rename this file to some random gibberish upon completion - otherwise, anyone can gain admin rights.
All participants sign up. The registration process should be spam-proof using a honeypot to fool bots trying to sign up. There's also the required invite code to make it extra secure, and that as well prevents strangers from joining.
Let's take a christmas present example:
- Phoebe wish for a book, some earrings and four new winter tires, so she adds them to "My Wishlist". These wishes will be shown on the index page for all to see (and reserve).
- Now Chandler comes by to enter some of his wishes as well. He sees that Phoebe wants some tires and a book, so he reserves those wishes. Since they are now taken, they won't be displayed on the index page anymore. Chandler can still see them under "My Reservations" - and of course Phoebe also still sees them under "My Wishlist".
- Phoebe can edit or delete her wishes at any time, but she should use this WITH CAUTION! She can't see which of her presents have been reserved - or perhaps even bought. (That would also ruin the whole surprise, right?)...
- If Chandler get second thoughts, or can't afford the tires, he can unreserve them. The wish now becomes available, and is yet again shown on the front page for others to reserve.
By doing it like this, everyone can see what other people wish for, and it's shown in a nice and clean way to avoid accidentally getting the same gift from different people.
2017/09/22: Version 2.1
- Fixed: I noticed some bugs when running the app on a local server, and they should be gone now.
- Changed: Changed some settings for global variables and stuff...
2017/09/14: Version 2.0
- Added: Frontend administration for basic database operations
- Added: The option for users to select their own password
- Added: The option for users to reset and set a new password
- Fixed: Inconsistency in error messages
- Changed: Rearranged some of the variables across files
- Changed: Made some minor cosmetic adjustments
2017/01/19: Version 1.01
- Minor bugfixes
- Added: Language support
2017/01/16: Version 1.0
- Committed to GitHub. As I originally made this in danish, this is of course best suited for people understanding the language. I will add some easy-to-use translation functionality in the next version, which will (hopefully) be released very soon.
This was created in January 2017 by Henrik Mortensen (http://psylicium.dk). Background image by Rolf Schweizer Fotografie (https://www.flickr.com/photos/schweizerrolf/23543699950/).
Copyright (C) 2017 Henrik Mortensen
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.