How do I clear tmp folders?

More
2 months 4 days ago #157553 by MadhuraBL
MadhuraBL created the topic: How do I clear tmp folders?
How do I change the LimeSurvey logo? (not just for surveys, want to change the main LimeSurvey logo?)

Replaced logo.png file under limesurvey/styles/Sea_Green/images/ but does not change. The old logo is loaded from tmp/assets/
How do I clear tmp folder?

Thanks
Attachments:

Please Log in to join the conversation.

More
2 months 4 days ago #157554 by Joffm
Joffm replied the topic: How do I clear tmp folders?
I use Filezilla or FireFTP (Firefox) or other ftp clients.

Joffm

Please Log in to join the conversation.

More
2 months 4 days ago #157556 by MadhuraBL
MadhuraBL replied the topic: How do I clear tmp folders?
Hi Joffm, thanks for the quick response.
I meant, how do I clear the tmp files, do I just delete all the folders and files under /var/www/html/limesurvey/tmp folder?
Or keep the folder and delete only the files under those folder?
Example:
delete files under limesurvey/tmp/assets/ (keeping assets folder)
delete files under limesurvey/tmp/upload/cache (keeping cache folder)??

Thanks in advance

Please Log in to join the conversation.

More
2 months 3 days ago #157574 by Joffm
Joffm replied the topic: How do I clear tmp folders?
Hi,
keep the folders.

Some time ago there was reported a bug in a new version which did not install the asse -folder and gave - of course - an error message.

Probably you did not read this.
https://www.limesurvey.org/de/foren/installation-a-update-issues/107196-error-after-update-to-version-2-53-161004-tmp-assets-does-not-exist

So, asset folder has to exist.

Regards
Joffm

Please Log in to join the conversation.

More
2 months 3 days ago #157586 by tpartner
tpartner replied the topic: How do I clear tmp folders?
Also, ensure that you keep index.html in the assets folder.

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

Please Log in to join the conversation.

More
2 months 3 days ago #157600 by MadhuraBL
MadhuraBL replied the topic: How do I clear tmp folders?
Hi Joffm and tpartner, thanks for the answers.

However, the logo does not appear in few pages, and in someother pages, still the old logo shows up.

- renamed logo.png to logo.png_orig under limesurvey/styles/Sea_Green/images/
- copied new logo.png under limesurvey/styles/Sea_Green/images/
- Cleared all files under assets folder (keeping index.html)
- Refreshed admin page => no logo shown (right click and view image gives => Not Found
The requested URL /tmp/assets/6ec3b3d3/logo.png was not found on this server.)

- Refreshed 'Following survey available' page => Old logo shown

How do I fix this??

Thanks in advance

Please Log in to join the conversation.

More
2 months 3 days ago #157605 by LouisGac
LouisGac replied the topic: How do I clear tmp folders?
just increase the asset number version here:
github.com/LimeSurvey/LimeSurvey/blob/ma...nfig/version.php#L19

this will force the asset manager to republish everything.

Tip: any different number will work (inferior or superior), so try not to use the {current value +1}, else assets will not be updated with next comfortUpdate (that always increase it by 1)
The following user(s) said Thank You: tpartner

Please Log in to join the conversation.

More
2 months 3 days ago #157611 by tpartner
tpartner replied the topic: How do I clear tmp folders?
Hmm...maybe a link/button in the admin configuration screen to clear them would be worthwhile.

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

Please Log in to join the conversation.

More
2 months 1 day ago - 2 months 1 day ago #157673 by MadhuraBL
MadhuraBL replied the topic: How do I clear tmp folders?
Hi LouisGac, tried this too. No Luck!
changed the version number to '4321', cleared tmp (tmp/assets, tmp/cache) files (keeping index.html)

And when I go to the front page, iits still the old logo.
I am now wondering, is it the right place I am changing the logo?

Please refer screenshot of the page where I want to change the logo.

Thanks very much for the help.

PS: The logo is changed in the Admin page, but I want to change in the page that is in the screenshot
Attachments:
Last Edit: 2 months 1 day ago by MadhuraBL.

Please Log in to join the conversation.

More
2 months 1 day ago - 2 months 1 day ago #157684 by LouisGac
LouisGac replied the topic: How do I clear tmp folders?

tpartner wrote: Hmm...maybe a link/button in the admin configuration screen to clear them would be worthwhile.


Yes, I understand that point view that can appear logical: such a button is very easy to do. Here why I refuse to do it:

I think it would make an extra level of complexity and stress. People don't understand how asset manager works, so it would very quickly become a magic button: each time they'd face a problem they would try to go clean the assets as a superstition, and it would just be useless and stressful. The goal of an asset manager is that user completely forgets about it, and ignores its existence. If instead of the magical operation of "first clean the browser cache" when facing a bug, they must use a new superstition which is "clean the assets" when facing a bug: it's useless. No, you don't have to clean the assets:
www.yiiframework.com/wiki/148/understanding-assets/#hh4

Many newcomers ask: "What do we do with the assets folder?", and the answer is "Mostly nothing".



In limeSurvey specific case:

When using the template editor, assets are refreshed when the page is saved.
When using comfortUpdate, assets are refreshed.

So for normal users, assets are refreshed when they need it and they never have to worry about cleaning the assets cache, and they don't need to have a magical button to press as a superstition when they face a problem.

Advanced users editing a template via FTP should use debug mode, then the asset manager is not used. When they upload their working template to the live server: new fresh assets are created. If they go in the quick and dirty way by directly editing a template on a live server via FTP: then they need to know the trick of the asset number. But only those users in this very specific case need it.

So, we avoid that situation where each bug report or complaint in the forum receive a systematic first answer: "please press the magical button that we don't really understand but that maybe will magically solve your problem".
Last Edit: 2 months 1 day ago by LouisGac.

Please Log in to join the conversation.

More
2 months 1 day ago #157685 by LouisGac
LouisGac replied the topic: How do I clear tmp folders?
So, the problem of MadhuraBL is a perfect example of that: his problem is absolutely not related to the asset manager and starting by thinking about the asset manager just make the problem harder to solve. Forget about the asset manager.

MadhuraBL: to change the logo of your template, go to template editor, delete the file logo.png, then upload a new file called logo.png, and it would work like a charm.

PS: thanks to the asset manager, all your users will see the new logo, you don't have to ask them to clean their browser cache (same if you use CDN cache). But you don't need to know that information ;-)

Please Log in to join the conversation.

More
2 months 1 day ago #157696 by tpartner
tpartner replied the topic: How do I clear tmp folders?

LouisGac wrote: Here why I refuse to do it...

@LouisGac, thanks for giving your strong opinion but I'm afraid I have to disagree with it.

I think you would find that most advanced LS admins never use the template editor - they develop on their local machines and upload directly via FTP or SSH. I do not see this as "quick and dirty", I see it as efficient. So, for those folks (myself included), I see the "Clear Assets" button as useful, instead of having to monkey with the version.php file.

Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The following user(s) said Thank You: holch

Please Log in to join the conversation.

More
2 months 1 day ago #157700 by LouisGac
LouisGac replied the topic: How do I clear tmp folders?
well... if you upload your template via FTP, then you can edit the version file via FTP.

Please Log in to join the conversation.

More
2 months 1 day ago - 2 months 1 day ago #157702 by tpartner
tpartner replied the topic: How do I clear tmp folders?
Obviously this discussion is over.

Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Last Edit: 2 months 1 day ago by tpartner.
The following user(s) said Thank You: holch

Please Log in to join the conversation.

Start now!

Just create your account and start using Limesurvey today.

Register now