Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

Can I Add CSS code in page without administrator account ?

  • nicotonic
  • nicotonic's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
8 years 9 months ago - 8 years 9 months ago #138318 by nicotonic
Hi,

I have user account to create survey (but not administrator of server) on a LimeSurvey Install.
A problem, for example : I want to enlarge a column on table answer type.

This CSS style works when I inject it in Chrome for example.
Code:
<style>
div.answers th.answertext {
width:35% !important;
}
</style>

- But how to put it in header page of my survey (I'm not administrator of server) :
- if I can't: how to tweak form ?




Thanks for help :kiss:
Last edit: 8 years 9 months ago by nicotonic.
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
8 years 9 months ago #138324 by tpartner

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
  • nicotonic
  • nicotonic's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
8 years 9 months ago #138326 by nicotonic
Yes cool it works
Code:
<script type="text/javascript" charset="utf-8">
   alert("Test!");
</script>
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
8 years 9 months ago #138329 by tpartner
Try adding this to the source of the group description or to the source of a question:

Code:
<script type="text/javascript" charset="utf-8">    
  $(document).ready(function(){
    $('head').append('<style type="text/css">\
      div.answers th.answertext {\
        width:35% !important;\
      }\
    </style>');
  });
</script>

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
Moderators: tpartnerholch

Lime-years ahead

Online-surveys for every purse and purpose