| | |
Online voting
Please support our PHP advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
Thread Solved |
•
•
•
•
Originally Posted by bondito
Hi, i am a computer science final year student, i was thinking of creating an online voting/polling system,the system could include surveys as well. I really need some ideas in designing the system and any idea you send to me will be highly appreciated.
Most the polling scripts will come with a administration panel (the good ones at least), I dont believe its complete withought it, so you'll have to also look at developing both the polling frontend, and an admin area to manage, create the polls.
Theres a lot of ways to actually go about doing the project, but if I were to do it, I'd first create a simple templating system (having your php logic seperated from your design makes it much less confusing), then develop the admin panel first (think of how the database will store all the results, and how the admin will create the forms), then go on to the actual forms that will be the frontend.
Though it sounds simple, a polling system can be a lot of work.
If you want to really go overboard, try searching the web for AJAX, and use it to validate, populate, submit forms on the poll frontend.
There arent many ajax based polling systems out there open source, (i checked) so it will be unique.
Pretty much you'll have to look into php php sessions, dynamic php forms, javascript (or php) form validation, mysql database functions, css, AJAX if you go further. Searching the net should yield alot of info.
Googluck.
www.fijiwebdesign.com - web design and development and fun
Cpanel Email - Let users Register email accounts on your website upon registration
Ajax Chat - Fully browser based chat!
Cpanel Email - Let users Register email accounts on your website upon registration
Ajax Chat - Fully browser based chat!
PHP, CFM and ASP are ideal for voting system. All these can do the same thing using different scripting methods. It is more important to know what kind of server you are going to use (depends on budget too). PHP is open source and free to use from installing apache server to database connectivity, which may be a good solution for a course work that is low in budget.
However, if you are looking for something that is highly complex or required more security, then I would suggest JSP. It should be very straight forward if you know JAVA.
However, if you are looking for something that is highly complex or required more security, then I would suggest JSP. It should be very straight forward if you know JAVA.
Ecommerce-Web-Store.com Building Your e-Business.
•
•
•
•
Originally Posted by shad
Thanks for the info, i was wondering how i would be able to go about creating the admin side of the system, how would the administrators be able to create new polls for the system. Thanks
First create the structure for your database. If you look at existing poll scripts, you can view the database structure using phpmyadmin.
The idea would be to save the info needed for each individual poll, and all the form fields on the poll.
You could store each poll in a table called 'polls' with the columns, id, title, description, creator, date, published etc etc.
This singles out each poll and also allows you to keep track of who created it and when (creator, date) and if its published or not and other optional features.
You can then create a table for all the poll's form fields called poll_fields.
First you will need to make sure the poll fields are linked to an existing poll, so you give it a table column called poll_id. This will have the value of one of the id's of the rows in the 'polls' table.
Its also good to have an index for your poll_fields table, so you can give it an id column also. (so you can identify each row on its own)
Then you can add another table column called form_field, this will hold your form fields. You can also add other colums like, field_type, field_description, field_length etc.
When you create a form fields, you can save each one into a different row in this table, but have the poll_id set to the same poll id.
So an example poll saved in the db would be:
Table: polls
id = 1, title = 'My first Poll', description = 'An example Poll', creator = 'myname', date='some_date', published='1'.
Table: poll_fields
id = 1, poll_id = 1, form_field = 'name', field_type = 'textbox', field_description = 'Fill in your Name';
id = 2, poll_id = 1, form_field = 'age', field_type = 'textbox', field_description = 'How Old Are You?';
id = 3, poll_id = 1, form_field = 'sex', field_type = 'textbox', field_description = 'Are you male or female?';
Now all you have to do is create the php pages that allow a admin to input this data into the db for each poll, and edit the data.
You'll notice that all the field_type's are textbox. Usually you will want textarea, selectbox etc. You can also add this, but you will need one more table to hold the options for a selectbox. Its just like the poll_fields except you link it to the poll_fields id, instead of the poll's id.
Hope that helps... :-|
www.fijiwebdesign.com - web design and development and fun
Cpanel Email - Let users Register email accounts on your website upon registration
Ajax Chat - Fully browser based chat!
Cpanel Email - Let users Register email accounts on your website upon registration
Ajax Chat - Fully browser based chat!
Hi. Welcome to Daniweb. Your question is nowhere related to php. You can post your question in geeks' lounge forum! or even better, google it !
Last edited by nav33n; Feb 21st, 2008 at 6:03 am.
Ignorance is definitely not bliss!
*PM asking for help will be ignored*
*PM asking for help will be ignored*
•
•
Join Date: Jul 2007
Posts: 110
Reputation:
Solved Threads: 1
Have a look at the democracy sections of www.myverdict.net. Is this the sort of thing you're looking to build.
Having built the site from scratch, I can tell you exactly how I went about it.
Best Regards
Taffd
Having built the site from scratch, I can tell you exactly how I went about it.
Best Regards
Taffd
![]() |
Similar Threads
- Online Voting System (JSP)
- Online voting !! (ASP.NET)
Other Threads in the PHP Forum
- Previous Thread: dynamic table
- Next Thread: connecting database
| Thread Tools | Search this Thread |
5.2.10 action apache api array beginner beneath binary broken cakephp checkbox class classes cms code cron curl database date destroy display dynamic echo echo$_get[x]changingitintovariable... email encode error fcc file files folder form forms function functions google header howtowriteathesis href htaccess html image images include insert ip javascript joomla limit link local login mail memberships menu mlm mod_rewrite multiple multipletables mysql mysqlquery neutrality oop open passwords paypal pdf php provider query radio random record remote rss script search server sessions sockets source space sql strip_tags syntax system table template thesishelp tutorial update upload url validator variable video voteup web window.onbeforeunload=closeme; youtube






