How can I use a different logo for each survey, but without changing de template

Mehr
3 Jahre 4 Monate her #109980 von helviobrito
helviobrito erstellte das Thema How can I use a different logo for each survey, but without changing de template
Hi.

Please help me. I've alreedy looked into the forum and the mamual and didn't find a clear answer for may issue.

I use LM 2.05+ Build 140302 and a mdified version of Vallendar template. I need to change the logo for each survey, but I didn't figure out how to do this. Can anone help me?

Bitte Anmelden um an der Konversation teilzunehmen.

Mehr
3 Jahre 4 Monate her #110000 von tpartner
tpartner antwortete auf das Thema: How can I use a different logo for each survey, but without changing de template
In the template file, you can use the placeholder for the survey ID in the filename of the logo image.

So, something like:

<img src="path/to/images/logo-{SID}.png" />

.

Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Folgende Benutzer bedankten sich: helviobrito

Bitte Anmelden um an der Konversation teilzunehmen.

Mehr
3 Jahre 4 Monate her #110022 von helviobrito
helviobrito antwortete auf das Thema: How can I use a different logo for each survey, but without changing de template
Thanks for your attention, tpartner. But, please, I'd like to know which template file I'll use to put this line in: survey. pstpl or starpage.pstpl?

Bitte Anmelden um an der Konversation teilzunehmen.

Mehr
3 Jahre 4 Monate her #110023 von tpartner
tpartner antwortete auf das Thema: How can I use a different logo for each survey, but without changing de template
It depends on where your logo is - probably in startpage.pstpl.

What template are you using? Can you activate a sample survey?


.

Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

Bitte Anmelden um an der Konversation teilzunehmen.

Mehr
3 Jahre 4 Monate her #110024 von tpartner
tpartner antwortete auf das Thema: How can I use a different logo for each survey, but without changing de template
It depends on where your logo is - probably in startpage.pstpl.

What template are you using? Can you activate a sample survey?


.

Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

Bitte Anmelden um an der Konversation teilzunehmen.

Mehr
3 Jahre 4 Monate her #110025 von helviobrito
helviobrito antwortete auf das Thema: How can I use a different logo for each survey, but without changing de template
I am using Vallendar, with a little modification only to change the color of warning texts from pink to red.

Here is a survey that you can see as an example: focuspesquisa.com.br/focusOnline/181521/lang-pt-BR .

See the logo focusOnline in the questions page? I'd like to change it only in this survey, for example, not affecting the others active ones.

Bitte Anmelden um an der Konversation teilzunehmen.

Mehr
3 Jahre 4 Monate her #110027 von holch
holch antwortete auf das Thema: How can I use a different logo for each survey, but without changing de template
Can't access the survey without a token and on the startpage there is no logo.

I'm not a LimeSurvey GmbH member. I answer at the LimeSurvey forum in my spare time. No support via private message.
Some helpful links: Manual (EN) | Question Types | Workarounds

Bitte Anmelden um an der Konversation teilzunehmen.

Mehr
3 Jahre 4 Monate her #110028 von holch
holch antwortete auf das Thema: How can I use a different logo for each survey, but without changing de template
But Tpartners solution would affect all other surveys that depend on this template that you use.

But I think it is a very elegant solution, if you have many surveys and they all need a different logo. You just put the logo file into the respective folder with the Survey ID in the file name and the template will use this file.

However, this change will affect all previous surveys, because they don't have the correct name and one disadvantage is that you would have to create a logo file for each survey, even if the logo stays the same. So if you usually use always one logo and just for this survey you need to use another one, I think it is easier to copy the template and change the logo file.

I'm not a LimeSurvey GmbH member. I answer at the LimeSurvey forum in my spare time. No support via private message.
Some helpful links: Manual (EN) | Question Types | Workarounds

Bitte Anmelden um an der Konversation teilzunehmen.

Mehr
3 Jahre 4 Monate her #110029 von helviobrito
helviobrito antwortete auf das Thema: How can I use a different logo for each survey, but without changing de template
Sorry. Use the login Testing and the token 123456.

So, I think that the logo goes in the survey.pstpl. My generic logo url is there. So, supose I have an image named newlogo.png and I want it just in the survey with the ID 181521. Do I change the images's name to newlogo-181521.png?

Bitte Anmelden um an der Konversation teilzunehmen.

Mehr
3 Jahre 4 Monate her #110030 von tpartner
tpartner antwortete auf das Thema: How can I use a different logo for each survey, but without changing de template
Yeah, no access for me either.

I think it is easier to copy the template and change the logo file.

No, we can do it dynamically for a single with JavaScript but I would need to see a survey to give the script details.


.

Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

Bitte Anmelden um an der Konversation teilzunehmen.

Mehr
3 Jahre 4 Monate her #110031 von tpartner
tpartner antwortete auf das Thema: How can I use a different logo for each survey, but without changing de template
Still don't see a logo. That survey is using the default template with no logos.

Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

Bitte Anmelden um an der Konversation teilzunehmen.

Mehr
3 Jahre 4 Monate her #110032 von helviobrito
helviobrito antwortete auf das Thema: How can I use a different logo for each survey, but without changing de template
Yes, I agree. I didn't think of copy the template for each survey. But I had a doubt it the logo name with the survey ID solution wouldn't affect all previous surveys, as you said, hotch. Thanks.

Bitte Anmelden um an der Konversation teilzunehmen.

Mehr
3 Jahre 4 Monate her #110033 von helviobrito
helviobrito antwortete auf das Thema: How can I use a different logo for each survey, but without changing de template
Plase, try again. Now the template is right.

Bitte Anmelden um an der Konversation teilzunehmen.

Mehr
3 Jahre 4 Monate her #110051 von tpartner
tpartner antwortete auf das Thema: How can I use a different logo for each survey, but without changing de template

But I had a doubt it the logo name with the survey ID solution wouldn't affect all previous surveys, as you said, hotch.

I made that suggestion before you said you had other surveys that you don't want affected.


If you want to insert a logo only for survey ID 181521, you can add this to the end of template.js. This will insert the defined image before your survey description.

$(document).ready(function(){
	// Image URL
	var imagePath = 'http://www.google.com/logos/2011/thai_elephant_day11-hp.jpg';
 
	// Insert the image
	if($('input#sid').val() == 181521) {
		$('td.survey-description').prepend('<img class="logo-image" src="'+imagePath+'" />');
	}
});


.

Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

Bitte Anmelden um an der Konversation teilzunehmen.

Mehr
3 Jahre 4 Monate her #110065 von helviobrito
helviobrito antwortete auf das Thema: How can I use a different logo for each survey, but without changing de template
Thanks, tpartner. I'll try this solution and report the result to you.

Bitte Anmelden um an der Konversation teilzunehmen.

Jetzt loslegen!

Melden Sie sich jetzt an, und erstellen Sie in wenigen Minuten Ihre erste Umfrage.

Account einrichten