Commit Graph

394 Commits

Author SHA1 Message Date
Luc Didry
c4ec2bbc41 Fix $_SERVER['SERVER_PORT'] handling
While installing Framadate on Apache, but proxyfied by an Nginx,
$_SERVER['SERVER_PORT'] failed to be correctly handled.

$_SERVER['SERVER_PORT'] is then a string and not an integer, so it was
added in the response of get_server_name() function, breaking all the
css/js links.

I don't know if there is other situations where the bug appears.

Schema of the installation:

Nginx (443) -> Apache2 (80) + Framadate

Please note that using port 80 on Nginx worked.
2018-02-28 17:09:16 +01:00
Simon LEBLANC
8720595874 Allow setting SMTP config
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
2018-02-21 11:07:11 +01:00
Thomas Citharel
77f05b1c21 fix issue with check for maxValue
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
2018-02-20 19:29:56 +01:00
Thomas Citharel
801bc08a81 Merge branch 'develop' 2018-02-20 19:05:24 +01:00
Thomas Citharel
d106d3ba41 update jquery
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
2018-02-20 18:00:27 +01:00
Thomas Citharel
a442cc5ee7 CS
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
2018-02-20 16:50:14 +01:00
Thomas Citharel
ff47a21ac2 Check that conditions on valueMax are acceptable before adding the vote
Handles people voting when the answers valueMax has been reached by someone else in the background

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
2018-02-20 16:47:10 +01:00
Thomas Citharel
76b19ee9ba fix votes wrongly calculated because of type check
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
2018-02-20 15:17:14 +01:00
Thomas Citharel
2d39a83a7f rebase and run php-cs-fixer
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
2018-02-20 14:15:18 +01:00
Erwan TERTRAIS
64ff414900 ValueMax : limit the number of voters per option
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
2018-02-20 14:15:18 +01:00
Thomas Citharel
3157d6a590 Run php-cs-fixer with a custom config. This may break a lot of things
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
2018-02-19 19:43:30 +01:00
Thomas Citharel
6b04d3542e Check for PHP 5.6
Better detection, get rid of dedicated file and use version_compare() instead

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
2018-02-19 19:37:47 +01:00
SpF
2bc9eb62d0 nl translations 2017-12-20 11:35:50 +01:00
Pierre Rudloff
3642bf87d4 Add favicon path to config 2017-02-22 21:16:09 +01:00
JosephK
ca653cf568 Merge branch 'spelling' into 'master'
Fix typos

See merge request !177
2017-02-20 07:04:36 +01:00
François B
fd3526c9c7 Fix typos 2017-02-05 04:19:04 +01:00
framartin
b0e6b82877 Sanitize names to avoid Formula Injections on CSV export 2017-01-05 18:48:46 +01:00
Olivier Perez
61e3d0735f Merge branch 'feature/piwik' into 'develop'
New tracking_code setting that inserts HTML code in the footer of every page

See merge request !163
2016-12-30 15:59:40 +01:00
Antonin
e17abed619 Get back the NL locale from master. 2016-12-26 16:32:07 +01:00
Pierre Rudloff
c5a50a7cad New tracking_code setting that inserts HTML code in the footer of every page 2016-12-22 16:14:22 +01:00
Antonin
8f6a31737d Merge branch 'fix/Some_fixes_on_comments' into 'master'
Some fixes on comments

Fix #205 

See merge request !161
2016-12-06 15:34:30 +01:00
Olivier PEREZ
cf21a10314 Remove '/action' when calculating server URL 2016-11-14 23:41:57 +01:00
Olivier PEREZ
79ae5bb77d Fix the code that checks if we should send notification regarding type of notification 2016-11-14 23:35:04 +01:00
Antonin
df8bbf3f65 Correction de l'editabilité du sondage : derniers noublis ! 2016-10-14 08:49:47 +02:00
Antonin
daf7fcd30a Bug sur l'éditabilité des sondage. 2016-10-14 08:22:15 +02:00
Antonin
ac3a8ca25c Get back the NL locale from master. 2016-10-13 17:36:39 +02:00
Olivier PEREZ
e8aac339f0 Booleanize some fields 2016-10-06 20:56:23 +02:00
Olivier PEREZ
357bc89d16 Remove useless default SQL columns 2016-10-06 20:37:46 +02:00
Antonin
e79a0bf683 Merge branch 'release' into develop 2016-08-08 15:23:42 +02:00
Olivier Perez
651289ec2d Merge branch 'bugfix/typo-in-comment-header' into 'develop'
Correcting comment typo in file header

Fix #190 

See merge request !144
2016-08-04 22:26:50 +02:00
Olivier Perez
5c11e5fe4d Merge branch 'bugfix/typo-in-comment-header' into 'develop'
Correcting comment typo in file header

Fix #190 

See merge request !144
2016-08-04 22:26:37 +02:00
Antonin
c50ca48efd Merge branch 'feature/rework_poll_creation_1st_page' into 'release'
Rework on 1st page of poll creation



See merge request !142
2016-08-04 22:07:52 +02:00
Antonin
4059956b02 Correcting comment typo in file header 2016-08-04 21:51:37 +02:00
Olivier Perez
9b39dd2fa1
New style of URL customization 2016-08-04 21:44:31 +02:00
Antonin
dc9babd2ed Merge branch 'develop' into feature/better-markdown 2016-08-04 17:49:40 +02:00
Antonin
fe3e1bc8b7 Merge branch 'feature/update-breton-translation' into 'develop'
Update, fix and add breton translation to correct branch



See merge request !143
2016-08-04 17:29:29 +02:00
Antonin
c01238b635 Merge branch 'feature/update-breton-translation' into 'develop'
Update, fix and add breton translation to correct branch



See merge request !143
2016-08-04 17:29:10 +02:00
Antonin
ccddddaf2d Merge branch 'Issue187' into 'develop'
Install framadate in non empty database

Modifications pour l'issue #187.

See merge request !139
2016-08-04 16:57:38 +02:00
gwenn
f99c402e6d Update, fix and add breton translation to correct branch 2016-07-31 00:31:43 +02:00
ecmu
f2562ce5fb Issue 187 : Install framadate in non empty database 2016-07-18 14:27:12 +02:00
Olivier Perez
0cf52c8461 Merge branch 'bugfix/install-config-escape' into 'develop'
Added escaping for install in config.tpl

In the installation process, string like the one below should be a valid application name (or DB password).
> Framadate c'est vraiment super ! "Datez" comme vous voulez \o/

It missed some escaping for single quote (') and backslash (\\), resulting in PHP parse errors.

It should be cherry-picked to the `release` branch too.

See merge request !136
2016-07-07 14:16:09 +02:00
Antonin
cd581a9d29 Added escaping for install in config.tpl 2016-07-07 11:31:51 +02:00
Antonin
b3ecf1262f Merge branch 'Fix_edition_of_expired_poll' into 'release'
Fix edition limits for expired polls

Fix #129 

See merge request !117
2016-07-01 00:34:42 +02:00
Antonin
2af04c3b1a Removing php escape and completing template ones. 2016-06-30 23:10:47 +02:00
Olivier Perez
fa5014de32
Fixed expiry date edition 2016-06-30 20:48:30 +02:00
Antonin
d37ec75550 Added configuration option for enabling rich editor by default. 2016-06-27 12:24:12 +02:00
Markus Jung
e49c19ab00 Avoid warnings due to non-existant 'en' datepicker locale 2016-06-18 22:14:15 +02:00
Antonin
83e0cae47a Markdown pour la description
- Ajout d'un editeur de markdown
    - On garde le formattage des espaces
    - On empeche l'utilisateur de mettre du html
2016-05-11 17:38:34 +02:00
Antonin
1c633d74d9 Using the library 2016-05-10 17:53:06 +02:00
Antonin
b739683d96 Install : check that the config.php file is written. 2016-05-04 01:27:51 +02:00
Antonin
f046cbdf95 Check.php 2016-05-04 00:57:45 +02:00
Olivier Perez
ab0748597a Merge branch 'feature/improve-self-editing-vote' into 'develop'
Feature : improve self editing vote

Adding a possibility to the user to enter his email address and to receive the personalized url by email.

See merge request !110
2016-05-03 21:16:05 +02:00
Antonin
fffe5dab82 Removing some unused functions 2016-05-03 17:17:48 +02:00
Antonin
69d8b7aa96 Removing useless UTF-8 specification 2016-05-02 17:51:01 +02:00
Antonin
f4aa091b80 Adapting html escape for emails 2016-05-02 17:44:14 +02:00
Antonin
391a8f751b Added the edit link reminder functionnality 2016-05-01 14:21:31 +02:00
Antonin
8085dd3c3e Adding remove key functionnality to SessionService 2016-04-29 19:38:00 +02:00
Antonin
42283dade2 Token default lenght 2016-04-29 18:46:22 +02:00
Antonin
4faf1be986 Message : allow showing a template 2016-04-29 18:46:02 +02:00
Olivier Perez
c5c1dee6a7 Fix Increase size of poll id in all tables 2016-04-27 13:22:36 +02:00
Olivier Perez
f0c36ec05f Merge branch 'Ecmu/framadate-Issue51' into develop 2016-04-27 01:15:01 +02:00
Olivier Perez
11ff60a170 Fix CHOICE_REGEX to allow space 2016-04-27 01:01:23 +02:00
Antonin
6d6334aa6d Improving edit link visibility 2016-04-27 00:12:21 +02:00
Olivier PEREZ
96c28738c4 PHP: Check if there are at most MAX_SLOTS_PER_POLL dates before create a poll 2016-04-26 23:16:08 +02:00
ecmu
8216bcbaa6 #51 : make empty vote different from 'No' 2016-03-13 16:20:38 +01:00
Olivier PEREZ
0ffdbe8573 Merge branch 'master' into develop 2016-03-05 15:59:10 +01:00
Olivier PEREZ
276f732def Fix #145 and #146 - Sort slots before check slots hash 2016-03-02 23:55:12 +01:00
Olivier Perez
a095c763fd Merge branch 'feature/Occitan' into 'master'
Feature/occitan

Request in order to integrate the Occitan language, in its lengadocian version, to Framadate. The ISO code is OC.

See merge request !101
2016-02-25 14:51:35 +01:00
Quentin
2caa5117d6 Update to add the Occitan language 2016-02-23 09:25:05 +01:00
Olivier PEREZ
bde59fe974 Fix the position computation to insert default vote when adding column 2016-02-22 23:51:50 +01:00
Olivier PEREZ
2109ef3469 More precision on MD5 regex 2016-01-06 19:38:19 +01:00
Olivier PEREZ
3fc25c0c4a Can't vote if admin made some changes on slots 2015-12-09 00:23:32 +01:00
Olivier PEREZ
cb0e74fba8 Fixes #124 - vote deletion 2015-12-08 00:20:23 +01:00
Antonin
ab9c0660cf Merge branch 'feature/UrlNaming' into 'develop'
Choix de l'URL du sondage

Traitement de l'issue #39 

- Agrandissement du champ ID
- Possilité de choisir son propre ID dans un champ texte (64 caractères, lettres/nombres/-)
 - Si ID choisi => L'ID de l'admin est généré sur 24 caractères
 - Si ID non choisi => L'ID de l'admin est généré sur 8 caractères + les caractères de l'ID
- Changement du htaccess

See merge request !97
2015-12-07 11:24:26 +01:00
Olivier Perez
a4ff2aaaa6 Standardization of regex format 2015-12-07 10:35:06 +01:00
Olivier PEREZ
6823133322 Update Framadate version number 2015-12-05 21:20:19 +01:00
Olivier PEREZ
17d050507b UrlNaming - Allow new id format when loading a poll 2015-12-05 17:28:40 +01:00
Olivier PEREZ
1efd7b9ab0 UrlNaming - Generate id unless if user has already choosen one 2015-12-05 17:28:38 +01:00
Olivier PEREZ
fac20a5908 UrlNaming - Add ID field to creation form 2015-12-05 17:28:35 +01:00
Olivier PEREZ
421f86d8a3 UrlNaming - Increase size of poll's id column 2015-12-05 14:24:38 +01:00
Olivier PEREZ
2b9f68780e Fixes #122 use the right method to use table names 2015-12-01 22:20:24 +01:00
Antonin
a219ccdee3 Added SessionService 2015-11-30 21:58:26 +01:00
Antonin
c78613481e Merge branch 'master' into develop
Conflicts:
	CHANGELOG.md
	htaccess.txt
	locale/it.json
	studs.php
	tpl/part/vote_table_classic.tpl
	tpl/part/vote_table_date.tpl
2015-11-30 21:55:56 +01:00
Olivier PEREZ
5750a36172 Rename add_slot by add_column 2015-11-30 20:38:53 +01:00
Olivier PEREZ
5d4958e1f4 Encode action values in base64 instead of url_encode (because of UrlRewrite) 2015-11-30 20:26:23 +01:00
Antonin
2dd68146a2 Merge branch 'fix/Issue109_delete_column' into 'master'
Fixes issue #109 - Urlencode title of column to delete for classical polls too

Tout est dans le titre 😃 

See merge request !85
2015-11-05 22:45:01 +01:00
Olivier PEREZ
171d45938c Move URL encore to Utils::getUrlSondage 2015-11-05 22:43:54 +01:00
Antonin
4cb189299f Merge branch 'fix/Issue114_delete_last_column' into 'master'
Fixes #114 - Can't delete last column anymore

Correction de la règle qui vérifie que la colonne à supprimer n'est pas la dernière.

`strpos` ne retourne jamais `-1` mais `false`

See merge request !82
2015-11-05 22:32:02 +01:00
Olivier Perez
acbf7db8b5 Fixes #114 - Can't delete last column anymore 2015-11-04 12:37:53 +01:00
Olivier PEREZ
c3b48b885d Refactor something :-) 2015-11-03 21:17:00 +01:00
Olivier PEREZ
40f2a1729c Better message when fail to create column 2015-11-03 21:15:47 +01:00
Antonin
15c57eeb37 Allows the admin to modify password related stuff. 2015-10-30 20:45:18 +01:00
Antonin
c6d6ad2393 Applying the password restriction in studs. 2015-10-29 11:52:13 +01:00
Antonin
b462a6bbdb Hashing the password early 2015-10-29 11:52:13 +01:00
Antonin
161b6b14c0 Password options are used with poll creation.
- Just found that the "hidden" parameter wasn't...
2015-10-29 11:52:13 +01:00
Antonin
cddbf3cb43 Safe way to hash password. 2015-10-29 11:52:13 +01:00
Antonin
f888a643e0 Added column password in poll table. 2015-10-29 11:52:13 +01:00
Olivier Perez
1ba245258a Merge branch 'master' into develop 2015-10-29 09:42:30 +01:00
Olivier PEREZ
15640a6788 Fix stupid break in adminstuds 2015-10-28 22:11:00 +01:00
Olivier Perez
2cfeb385bb Admin: Search in polls by author's mail address 2015-10-28 13:06:02 +01:00
Olivier Perez
3f1f957c5e Merge branch 'feature/ajax_submission_for_comments' into 'develop'
Feature - ajax submission for comments

The sending of comments has been ajaxified, in order to prevent the lose of vote data while commenting.

The comment list is also refreshed while commenting.

See merge request !72
2015-10-26 17:00:40 +01:00
Antonin
974148550b Refactoring for better reading 2015-10-26 16:28:59 +01:00
Imre Jonk
7ba352f0e5 Set URLs to https if HTTP X-Forwarded-Proto=https
This line changes all URLs to https URLs if the Framadate installation
is behind a reverse proxy, and the reverse proxy adds the
X-Forwarded-Proto header with the 'https' value. Configuration for
nginx:

proxy_set_header X-Forwarded-Proto https;

This setup is currently used by the Framadate installation of
Bits of Freedom (https://kies.bof.nl).
2015-10-26 15:02:02 +01:00
Olivier Perez
5ffc332b48 Merge branch 'Add_nonHTML_version_to_mails' into 'develop'
Fix #87 Use PHPMailer to add non-HTML body to mails

Utilisation de PHPMailer

See merge request !70
2015-10-22 21:58:46 +02:00
Olivier PEREZ
882203fad8 Fix #87 Use PHPMailer to add non-HTML body to mails 2015-10-22 21:34:15 +02:00
Antonin
2b38a7ddd6 Refactoring NotificationService 2015-10-13 01:03:41 +02:00
Olivier PEREZ
fe8f779217 Merge branch 'master' into develop 2015-10-12 23:58:57 +02:00
Olivier Perez
67134126b6 Merge branch 'fix/dont_sort_moments' into 'master'
Stop sorting the moments

- Don't sort moments at poll creation
- Don't sort moments at slot insertion

See merge request !65
2015-10-12 23:52:00 +02:00
Olivier PEREZ
4fa4ee0acc Merge branch 'master' into develop
Conflicts:
	admin/migration.php
2015-10-12 23:46:02 +02:00
Olivier PEREZ
49a5350f90 Fix #83 Stop sorting moments at new slot insertion 2015-10-12 23:25:51 +02:00
Olivier PEREZ
c6c9546669 Fix #83 Stop sorting moments at poll creation 2015-10-12 23:25:49 +02:00
Antonin
6196a53a45 Display the comment timestamp 2015-10-12 23:14:21 +02:00
Antonin
ba9a444f33 Adding a date column in the comment table 2015-10-12 22:26:22 +02:00
Antonin
82876c573e Set a length to comment table's name column
The name column was of text type. Passed to VARCHAR(64), like the poll name column.
2015-10-12 21:59:45 +02:00
Antonin
de18f826f0 The name can be any value.
There is no reason to limit the caracters that can be used in the name.
Thus, removing the regex.

Fix #97
2015-10-12 21:26:13 +02:00
Olivier PEREZ
d17ba242d3 Add log when adding a slot manually 2015-10-05 23:54:50 +02:00
Olivier PEREZ
4b6f7b685e getUrlSondage: Cannot define links for EDIT and ACTION at the same time 2015-10-05 23:50:51 +02:00
Olivier PEREZ
b61f60155e Fix the check for deleting the last slot 2015-10-05 23:50:00 +02:00
JosephK
74d5d87dae Oups… :-/ 2015-09-21 13:06:47 +02:00
JosephK
9a3590a9e1 Fix css header + Framanav 2015-09-21 10:03:18 +02:00
Olivier PEREZ
46afefb696 Fix RPad migration 2015-09-19 16:08:50 +02:00
Olivier Perez
09e1da3529 Add migration script to rpad some votes from 0.8 2015-09-18 11:20:04 +02:00
Olivier PEREZ
24a7fb7df2 Optimize selection of polls in admin page 2015-09-13 00:53:03 +02:00
Olivier PEREZ
7babf3f3a3 Optimize migration from 0.8 to 0.9 2015-09-13 00:06:23 +02:00
Olivier PEREZ
76d680b6dd Install: Remove useless 2015-09-07 16:46:21 +02:00
Olivier PEREZ
cbc5727ce4 Install: Display previous selections when installation failed 2015-09-07 16:37:03 +02:00
Olivier PEREZ
fd27c135c8 Install: Prefill the fields with values from InstallService 2015-09-07 16:36:57 +02:00
Olivier PEREZ
254512c55a Install: Redirections between Install and Index 2015-09-07 16:36:42 +02:00
Olivier PEREZ
a7727d8523 Install: Create installation page 2015-09-07 16:36:25 +02:00
Olivier PEREZ
a6d8342e77 Add migration script to generate vote's uniqid for legacy votes 2015-06-24 22:37:46 +02:00
Olivier PEREZ
a6788d81c2 Host can now force URL, used behind a reverse-proxy 2015-06-23 22:03:56 +02:00
Olivier PEREZ
44928b0572 Dont sort classic polls 2015-05-30 23:36:04 +02:00
Antonin
4ced550942 Merge remote-tracking branch 'upstream/release/0.9' into release/0.9 2015-05-29 18:59:09 +02:00
Antonin
fa111ab04e Prevent from deleting the last slot
- Also fix the corresponding translation when a problem arise.
2015-05-29 18:53:09 +02:00
Antonin
64b79965c6 Fixing the description newlines problem
- As it is now, description can't be in error state : we are waiting the markdown implementation to eventually change that.
	- Comments are now normaly formated (newlines are taken into account)
	- The title, description and comment regexes are now useless. Deleted.
2015-05-29 18:38:03 +02:00
Olivier PEREZ
cb0864f8fd Fix a lot of things 2015-05-29 18:11:12 +02:00
Olivier PEREZ
ad2b146c3c Remove parameter from MailService::send 2015-05-29 17:49:01 +02:00
Olivier PEREZ
278e478d1a Write log when send a mail 2015-05-29 17:41:50 +02:00
Olivier PEREZ
8313b9345d Fix after update o80-i18n 2015-05-29 17:13:35 +02:00
Olivier PEREZ
be155aa2a1 MailService now manage the anti-flood system 2015-05-29 17:06:03 +02:00
Olivier PEREZ
92d84f3193 Install PHPUnit for UnitTesting 2015-05-29 17:05:26 +02:00
Olivier PEREZ
1ec8db4c30 Check if vote name is already used + Fix missing key 2015-04-24 00:29:10 +02:00
Olivier PEREZ
551b839292 Display the count of 'if need be' 2015-04-23 23:18:31 +02:00
Olivier Perez
8882756c7f Add IT language file 2015-04-17 13:46:06 +02:00
Olivier PEREZ
45d14044f8 Factorize a little the mails 2015-04-14 22:32:41 +02:00
Olivier Perez
199e41ec93 Fix: description was required 2015-04-14 13:34:42 +02:00
Olivier PEREZ
942e2cb8d2 Merge branch 'feature/FindMyPolls' into develop
* A new page is available on index, it allows user to send by mail all the polls created by a given mail address
2015-04-13 23:55:40 +02:00
Olivier PEREZ
715bee6d7b Clean after merge request 2015-04-13 23:53:28 +02:00
Antonin
0505ab6bb2 Merge remote-tracking branch 'upstream/develop' into develop
Conflicts:
	app/classes/Framadate/Utils.php
2015-04-13 16:16:02 +02:00
Antonin
fbd45960b7 Changing some actions from POST to GET. 2015-04-13 15:45:01 +02:00