Archive for the ‘Web Development’ Category
Curious?
Posted by AI Dating | Filed under Developments, General, Web Development
For the last months I have been working on a dating site that uses fuzzy inferencing. In order to test new functionality I like to obtain some more user data.
Therefore I’d like to kindly ask anyone to sign up, even if you are not single, and answer the questions that are asked to you by the dating assistant.
The menu on the left is not active yet and you will not be able to use more than one photo.
If you are in a relationship or you want to withdraw your data later this year, please let me know. I would also encourage you that if you have a partner that he/she can also try the system. It would be nice to see whether you will be matched to your partner or not (matches are not yet visible to the user). Also I like to know any feedback you have, especially concerning the functionality or user experience. The project is almost finished and I am working on documenting the work. After the write up I hope i can use the feedback to improve the web site and to add more functonality.
The sign up page can be found at: http://www.aidating.co.uk/signup/
If you want to log on at a later stage you can do so at: http://www.aidating.co.uk/login/
Note that most effort is gone into the GUI and the matching algorithm and that contacting other users was not the primary concern during the period of the project itself. You can obviously expect this functionality soon since it is necessary part of every dating site. Also not that it is just a prototype and I therefore do not claim any specific results yet. You can leave any feedback regarding the site in this thread.
Wasting time
Posted by AI Dating | Filed under Web Development
So many things that take up time while developing things you have in mind. When a human being has to a thousand things and jut ten things go wrong, it will still double the needed time you would have needed to just do that thousand things. This something you do not always realize when planning. After all it is hard to plan mistakes because they appear pretty randomly in your work.
As an example I was working on a photo uploader. After all, what constitutes a good first impression? Is it intelligence, no. I rather think it is plain old attractiveness. Probably the reason why so many people fell in love with those überattractive celebrities. And probably also the reason why they have so many relationships that don’t work out (or is it just that the media is too much focussed on those break ups?). Attractiveness might constitute to a good first impression, falling in love, it does not help much for a long time stable relationship. Well I am loosing the main point now. The photo uploader. I was uploading a photo in the GUI, and Ithought it worked out. The next steps were to generate a thumbnail as well and to add a reference to the database. After generating a thumbnail I downloaded them to see what they looked like. Terrible! The image was completly distorted and not even recognised by some photo software. So I spitted through all the code. Seeing what could have gone wrong. Maybe not the right dimensions, a wrong setting that reduces the quality so much. I kept sending debugging. Till I downloaded the originally uploaded photos and realised they were as distorted as the thumbnails. So the problem was actually not with the thumbnails at all. However uploading and copying is quite basic in the back end. I wondered how this could have gone wrong. After all this code was highly similar with some online resources that described the process. So, I looked into the javascript for the uploader. Maing that javascript code was a pain after all. I looked into content-types and form encryptions. Nothing worked out. And then finally, Euraka!, I found out what was wrong. The ftp program downloaded the photos in ASCII mode instead of binary mode. No errors in the script at all. I lost at least a day for debugging something that was just working. I got the clue when I was reengineering the uploader seperately under the html root (where things are visible in the browser). And it just appeared to work. So I made it more similar to my real application and it was still working. So I knew I had too look somewhere else for the error.
The lesson is, we make mistakes. Always plan double the time you would rationally need to implement something. Some people might have said, just drop the photo uploader as a requirement. It has nothing to do with AI after all. Other people might say, test every aspect of whatevery you do. Testing is not always a bad idea. After all, I was testing and found out it didn’t work (or it did work actually). However testing everything you do, what some scientists do, takes at least 10 times the time you need for implementation.
But happily it works now so I can put more effort into the main part. The matching process. The interaction between user and the questioning software agent. The fuzzy logic.
Databases
Posted by AI Dating | Filed under General, Web Development
Currently I am upgrading the database queries to use PEAR::MDB2 for there queries. This is both more future proof and it has possibilities to prevent from potential mysql injection attacks to harm the site.
Ajax GUI
Posted by AI Dating | Filed under Developments, Web Development
Currently I am working on the AJAX GUI in which I use EXT JS. EXT JS is an AJAX framework like those of Google, Dojo, Mochikit, Spry. EXT is based on Yahoo’s YUI framework. The use of AJAX enables me to do asynchronous updates in the graphical user interface (like updating questions from the AI matching agent) and it makes it more easy to build rich user interfaces. On the other hand you have to make extensive use of Javascript, which is harder than conventional web development and it takes more effort to protect all possible asynchronous requests from unauthorised use.
Templating and friendly urls
Posted by AI Dating | Filed under Developments, Web Development
Today I installed the Smarty template engine in order to keep the programming logic and presentation logic seperate. I embedded smarty in a mechanism for url rewriting so the page requests are queried to the database and then processed by smarty so that every request can be shown in whichever template.
Security
Posted by AI Dating | Filed under Developments, Web Development
Since a dating site deals with extensive user data, security might be an issue. Although from the ethics perspective people will agree on the fact that the supplied information becomes property of the application and/or organizations around it. Just like on MySpace and other social profile equivalents. However the data gathered should also be stored in a secure way so that other users can’t access it when they don’t have permission to get it.
So I looked into authorisation systems. Some scripts are now secured using the apache authorisation module (.htpasswd). However for the user pages I needed an authorisation script that is secure and provides people with a login and sessions so they can stay logged in for some time. Many scripts were available but I decided to go with the Auth extension of Pear. For which an installation of Pear is also a prerequisite. So today I installed PEAR and I am experimenting with the offered authorisation options and how to implement those. Good authentication is a necessity especially since AJAX requests are quite vulnerable to misuse. Tomorrow I will look into how to store the user data. PEAR is also used for the database abstraction layer and might be used for other functionality that will be implemented.
Creating a secure PHP login script
Creating a secure PHP Login Script
Pear
Domain Hunting
Posted by AI Dating | Filed under Developments, Web Development
For the past months I have been thinking about how to represent a dating site. How should the user experience be. One part of it is the GUI and another aspect is the name. What is in a name? Well a lot I guess! Almost every name related to dating (including stupid names incorporating numbers, mistypings, etc) have been taken, either by dating sites or domain hunters.
So it was very hard to come up with a name. The name should be original, easy to remember and it should somewhat cover what the web site is about. So many things came to mind and were usually taken. So for the moment I have the names “AI Dating” which covers what it is about but it is a bit tech savvy and I’ve got the name “Dating Atmosphere” which is not too bad but it is quite long for a domain name. Dating Atmosphere was actually derived from datingsphere, but that was taken as usually. With the sphere in the name I wanted to represent the idea in the web application that you might be in the middle and potential dates are in spheres around you based on functional proximity (match percentage). Possibly this will be shown in such a way in the GUI if there is time to develop it that way. This is one of the aspects that is novel and not seen on other dating sites (afaik).
So for the moment the dating site can be found at: aidating.nl (for a Dutch audience), aidating.co.uk (for the UK audience) and datingatmosphere.com (possibly for an international audience).
If you have any suggestions for a nice name that has not been taken, please let me know ;-).