View Issue Details

IDProjectCategoryView StatusLast Update
06880Development [All Projects] Theme editorpublic2015-08-21 15:51
ReporterResearchOnBlogsAssigned ToDenisChenu 
PrioritynormalSeverityminor 
Status closedResolutionfixed 
Product Version2.00 
Target Version2.05Fixed in Version2.05 
Summary06880: Allow adaptation of 5 point slider
Description

in terms of theming it would be great to add some classes to the slider answer.

TagsNo tags attached.

Activities

ResearchOnBlogs

ResearchOnBlogs

2012-11-15 14:56

developer  

5point_slider patch.txt (2,436 bytes)
# This patch file was generated by NetBeans IDE
# It uses platform neutral UTF-8 encoding and \n newlines.
--- <html>qanda_helper.php (<b>30.10.2012 14:38:17</b>)</html>
+++ <html><b>Current File</b></html>
@@ -1022,14 +1022,14 @@
         $answer.="
         <script type=\"text/javascript\">
         document.write('";
-        $answer.="<div style=\"float:left;\">'+
-        '<div style=\"text-align:center; margin-bottom:6px; width:370px;\"><div style=\"width:2%; float:left;\">1</div><div style=\"width:46%;float:left;\">2</div><div style=\"width:4%;float:left;\">3</div><div style=\"width:46%;float:left;\">4</div><div style=\"width:2%;float:left;\">5</div></div><br/>'+
-        '<div id=\"{$id}sliderBg\" style=\"background-image:url(\'{$imageurl}/sliderBg.png\'); text-align:center; background-repeat:no-repeat; height:22px; width:396px;\">'+
+        $answer.="<div id=\"slider-wrapper\"><div id=\"slider-inner\" style=\"float:left;\">'+
+        '<div id=\"slider-scale\" style=\"text-align:center; margin-bottom:6px; width:370px; padding-right: 11px;\"><div style=\"width:2%; float:left;\">1</div><div style=\"width:46%;float:left;\">2</div><div style=\"width:4%;float:left;\">3</div><div style=\"width:46%;float:left;\">4</div><div style=\"width:2%;float:left;\">5</div></div><br/>'+
+        '<div id=\"{$id}sliderBg\" class=\"slider background\" style=\"background-image:url(\'{$imageurl}/sliderBg.png\'); text-align:center; background-repeat:no-repeat; height:22px; width:396px;\">'+
         '<center>'+
-        '<div id=\"{$id}slider\" style=\"width:365px;\"></div>'+
+        '<div id=\"{$id}slider\" class=\"slider\" style=\"width:365px;\"></div>'+
         '</center>'+
         '</div></div>'+
-        '<div id=\"{$id}emoticon\" style=\"text-align:left; margin:10px; padding-left:10px;\"><img id=\"{$id}img1\" style=\"margin-left:10px;\" src=\".{$imageurl}/emoticons/{$value}.png\"/><img id=\"{$id}img2\" style=\"margin-left:-31px;margin-top:-31px;\" src=\"{$imageurl}/emoticons/{$value}.png\" />'+
+        '<div id=\"{$id}emoticon\" class=\"slider emoticon\" style=\"text-align:left; margin:10px; padding-left:10px;padding-top: 25px;\"><img id=\"{$id}img1\" style=\"margin-left:10px;\" src=\".{$imageurl}/emoticons/{$value}.png\"/><img id=\"{$id}img2\" style=\"margin-left:-31px;margin-top:-31px;\" src=\"{$imageurl}/emoticons/{$value}.png\" />'+
         '</div>";
         $answer.="');
         </script>
5point_slider patch.txt (2,436 bytes)
ResearchOnBlogs

ResearchOnBlogs

2012-11-15 14:57

developer  

slider_after.png (18,218 bytes)
slider_after.png (18,218 bytes)
ResearchOnBlogs

ResearchOnBlogs

2012-11-15 14:58

developer  

slider_before.png (14,373 bytes)
slider_before.png (14,373 bytes)
c_schmitz

c_schmitz

2012-11-15 15:10

administrator   ~22185

Tony, can you check if this is the right approach and if yes, if it can be applied in a stable version without affecting existing templates or rather be done in 2.10.

tpartner

tpartner

2012-11-15 21:01

developer   ~22212

roB2009, can you please attach your test survey?

DenisChenu

DenisChenu

2012-11-16 09:23

developer   ~22229

Last edited: 2012-11-16 09:24

View 2 revisions

Tony: Maybe it's best to only use a javascript/css file for "5 point choice with slider"

Use same HTML than "no attribute set" and just use
header_includes("5point.js");
header_includes("5point.css","css");
To do the job.

After we can use same files for array 5 point (and maybe 10 point), and the script and css can be easily replaced by template.

:)

PS: maybe it's a 2.1 issue, because it's in qanda.php

tpartner

tpartner

2012-11-16 12:20

developer   ~22264

Okay, over to you Denis :)

DenisChenu

DenisChenu

2013-03-25 22:20

developer   ~24863

Bot sure have time for 2.05 : but think all this "HTML/javascript" must be set in external js file.
And next some question attribute ca be moved easyly in Plugin.

Same think for multi numeric/smlider for example

DenisChenu

DenisChenu

2013-04-05 12:11

developer   ~24911

All is in external css and js file, then all can be replaced by same file name in template OR by template.css/template.js

Don't change look of old system.

Related Changesets

LimeSurvey: 2.05 e5765fb5

2013-04-05 10:07:46

DenisChenu

Details Diff
New feature 06880: Allow adaptation of 5 point slider
Dev: Allow for slider and star
Dev: Think script can be adapted for 5 point array too
Dev: surely some css fix but tested in IE7
Dev: surely some js optimisation
Affected Issues
06880
mod - application/helpers/qanda_helper.php Diff File
add - scripts/slider-rating.js Diff File
add - scripts/star-rating.js Diff File
add - styles-public/emotes/faces.png Diff File
add - styles-public/img/slider-background.png Diff File
add - styles-public/img/slider.png Diff File
add - styles-public/img/stars.png Diff File
rm - styles-public/rating-img/star.gif Diff File
rm - styles-public/rating-img/star1.gif Diff File
rm - styles-public/rating-img/star2.gif Diff File
rm - styles-public/rating-img/star3.gif Diff File
rm - styles-public/rating-img/star4.gif Diff File
rm - styles-public/rating-img/star5.gif Diff File
add - styles-public/slider-rating.css Diff File
add - styles-public/star-rating.css Diff File

Issue History

Date Modified Username Field Change
2012-11-15 14:56 ResearchOnBlogs New Issue
2012-11-15 14:56 ResearchOnBlogs File Added: 5point_slider patch.txt
2012-11-15 14:57 ResearchOnBlogs File Added: slider_after.png
2012-11-15 14:58 ResearchOnBlogs File Added: slider_before.png
2012-11-15 15:09 c_schmitz Assigned To => tpartner
2012-11-15 15:09 c_schmitz Status new => assigned
2012-11-15 15:10 c_schmitz Note Added: 22185
2012-11-15 21:01 tpartner Note Added: 22212
2012-11-16 09:23 DenisChenu Note Added: 22229
2012-11-16 09:24 DenisChenu Note Edited: 22229 View Revisions
2012-11-16 12:20 tpartner Assigned To tpartner => DenisChenu
2012-11-16 12:20 tpartner Note Added: 22264
2012-11-21 20:02 DenisChenu Project Bug reports => Development
2012-11-21 20:02 DenisChenu Product Version 2.00+ => 2.00
2012-11-21 20:02 DenisChenu Target Version => 2.1
2013-03-25 22:19 DenisChenu Target Version 2.1 => 2.05
2013-03-25 22:20 DenisChenu Note Added: 24863
2013-03-30 14:39 DenisChenu Summary add classes to 5 point slider => Allow adaptation of 5 point slider
2013-04-05 12:09 DenisChenu Changeset attached => LimeSurvey 2.05 e5765fb5
2013-04-05 12:11 DenisChenu Note Added: 24911
2013-04-05 12:11 DenisChenu Status assigned => resolved
2013-04-05 12:11 DenisChenu Fixed in Version => 2.05
2013-04-05 12:11 DenisChenu Resolution open => fixed
2015-08-21 15:51 c_schmitz Status resolved => closed
2015-12-11 14:40 c_schmitz Category Templates => Theme editor