Prestashop cache won't clean - prestashop

Currently I'm working with the newest prestashop version (1.7.x) and the theme called Leo Fashion Store. I'm trying to edit CSS file, however, as soon as I make the edit, changes won't show. It does show immediately after saving the new file but it disappears quickly. It seems the system is taking only cached files.
Caching has been fully disabled through "Performance" settings but it still takes the cached files instead of directly from the main CSS file.
Are there any solutions?

I sometimes use Leo Themes and got the same issue, you should solve it by save again all the theme profiles. You can find the profiles in backoffice under "AP Pagebuilder" menu voice. Hope it helps.
Simone
PS: This is more a comment than an answer but I still cannot comment because of low ranking

Theme CSS files are being compressed in a unique minfied CSS (usually stored in theme dir under assets/css/theme-xxxx.css) - See the "Smart CSS cache" option in the Perfomance Page and make sure it is disabled , or just disable/re-enable it to regenerate the compressed file after your modification.
If this does not help, make sure that there is no CDN or server-level cache that can serve stale date and also make sure that the theme don't use its own dedicated cache for CSS (never seen this in PS 1.7 , though)

To clear the cache, also delete (manually or with a file manager) the /var/cache/ directory.
it would be easier to understand if you gave us your website address.

Related

Yoast SEO meta description not saving

I generate a Focus Keyphrase and Meta Description in Yoast SEO meta box for my Home Page. But when I exit the editor, if I go back to the Home Page, the Focus Keyphrase and Meta Description have disappeared.
Does anyone know how I can keep them?
Thanks
I spent easily 5 hours trying to track down and fix an issue with Yoast meta fields not saving properly. The only real clue I had was this console error:
Uncaught TypeError: Cannot read properties of undefined (reading 'registerPlugin') at window.wpseoScriptData.window.wpseoScriptData.featuredImage.i.registerPlugin (post-edit.js)
Based on this Yoast Github issue, it appears that the needed YoastSEO javascript app is not there when it's being called in /wp-content/plugins/wordpress-seo/js/dist/post-edit.js when the page is loading, and Yoast javascript app is not actually there, so it bonks.
So there may be something somewhere that is dequeuing the needed javascript that builds the YoastSEO object. One thing to check is to search your code base (excluding the Yoast plugin itself) for instances of wpseo, yoast, etc. If you find some code that is dequeuing/removing something, that might be it. If you have a plugin with results, deactivate if you can and check if that fixes anything.
I also noticed that the SEO Analysis drawer never loads and has the loading spinner running indefinitely. The javascript that controls the setting fields seems to work, but when you save it doesn't actually save, it just goes into the void.
All that said... I wasn't able to figure out what was wrong, but I did get it to start working again. Here's what worked for me...
After reading through a lot of different issue threads, I stumbled across some issues around security plugins blocking parts of the install process. I have my Wordfence settings dialed up pretty strict, so I deactivated it per recommendations while we go through re-installing Yoast.
After making sure that your security plugin(s) are deactivated, then deactivate and uninstall Yoast. Apparently you don't need to remove the plugin data, just uninstall. (This is also a good time to update other plugins if you haven't already).
Once you reinstall Yoast, you should have a button available to reindex the "indexables" that you need to click. It might be on the Dashboard, I don't remember. If you don't see it, you might go to Search Appearance > General > Rewrite tables > Force rewrite titles and Enable that, then save changes. I'm not 100% positive, but it seemed like after I did that, there was a panel in the General settings Dashboard or something, that said something along the lines of "Looks like some settings have changed, you should re-index your indexables now" with a button to start the process.
I also had to turn "Show SEO settings for Posts/Pages?" back on under Search Appearance > Content types. After I reinstalled, those were disabled. So maybe that helped Yoast know to load the javascript properly.
I'm not super familiar with Yoast, as you can probably tell, but after doing all this, it's working.
I believe you can also trigger the reindexing process from the CLI if you want, and that it's recommended if you have a large site with over 10k posts or whatnot.
Hope all this helps!

BigCommerce Stencil language files not working

I've enabled stencil themes for my store, and am trying to use "Cornerstone" as my theme. However, the whole reason for opting in and trying out new stencil themes is their built in support for multiple languages. I need my store to at least be available in Swedish, and if possible, English as well.
I've followed the documentation adding a "sv.json" file to the langs folder, and uploaded the modified theme to my store and applied it. No changes. I've ensured my browser is setting the "Accept-Language" header to "sv".
https://stencil.bigcommerce.com/docs/the-schema
I've also tried modifying the default en.json file, but I still can't see any changes in my store...and that seems a bit strange to me?
What am I missing, is this feature not really implemented yet, or am I screwing something up with the "upload zipped theme to store admin and apply"?
https://support.bigcommerce.com/articles/Public/Custom-Theme-Upload
Any pointers are very appreciated!

Search string in code in Shopify Liquid

I am looking for a particular div in the Shopify Liquid files of a large-ish site I am new to and that I did not build. However, I have to check the files one by one to find if the div is there, which is unefficient. The PHPStorm editor has the ctrl+shift+F option to search the file arborescence for a specific string in any file. Does Shopify have an equivalent, and what is it?
Not to be confused with:
Adding a search bar on a Shopify site
Searching Shopify store admin (I need to look at the Liquid code, not the store)
Tried already:
Googled 'shopify equivalent of phpstorm ctrl+shift+F'
Googled 'shopify keyboard shortcuts'
Googled 'shopify find in path'
Googled 'shopify search code'
Found no relevant result.
I'm afraid I have never seen such feature on the Shopify Editor. What I usually do, however, if you're not working with the theme locally already is:
Export the theme via Download Theme File
Download the .zip and extract it.
Open it with your favourite Editor (I personally use Sublime)
Use Find in Folder or your text-editor equivalent to search for the string on the whole theme.
Sadly, there's no better workflow as of now. You should consider however, setting up your theme locally so you can take advantage of version control and a more organized workflow that could help maintenance and new updates on that site.
2 options:
1) download locally (many devs work locally now using theme kit or another tool)
unzip theme and do a search either with text editor or with file manager
2) you can also use screaming frog to scan sites in detail - may be more useful though in cases where the div is not actually technically in theme but say in a metafield or added by an app.

Wrong image path updating from prestashop 1.4 to 1.6

After two intense days of messing with Prestashop, I'm facing a problem, and my numerous searches gave nothing.
I have to update a prestashop ver. 1.4 to 1.6. Once I updated, product images won't show :
the website is looking for a path like this src="http://siteurl.com/86-home_default/arbre-a-chat-amelia.jpg...
But on our server, files are using another structure : http://siteurl.com/img/p/8/6/ etc...
I tried with and without "legacy mode" (I can't modify php safe mode). There's no sign of any "move" option in prestashop 1.6 admin, and tricks to made this button appear (on 1.5) won't work.
Is there any way to edit how images are found? After trying to update from scratch again and again, is this safer to "just" update to 1.5.x, and then 1.6?
I'm sorry if there is only few elements here, but any help is much appreciated and I'll do my best to explain missing points if needed.
I had got the same problem but updating from 1.4 to 1.5. My problem was that the new template of 1.5 uses images in this way *_default (home_default, small_default, etc). When I updated the images weren't shown because the path referenced was wrong. The solution for me was add "_default" in Preferences -> Images to every image type and then click in Regenerate images.
Somehow urls were broken, maybe from too much legacy mode switching... Neither friendly URL desactivation or image regeneration worked.
Managed to "workaround" this by copying an old backup on wamp, in order to have safe_mode off... Then, this "move images" button was here, and totally functionnal, with image regeneration and all I needed (I don't know why I haven't thought about it earlier...).
Thanks for your support !

Multiple photo upload using struts1

We happened to get requirement to upload the multiple files ( like the gmail attachments ) using struts 1.3.5 and Ajax.
I happened to go thorough lot of resources but no luck.
Can someone shed light on this possibly by suggesting or pointing to some useful resources.
I was also looking for a multiple file upload solution for my struts2 application. Since ajax form submit do not support image submission the only option to use was a hidden iframe strategy. However, i found this wonderful plugin which uploads multiple files withour reloading the page and also shows a cool progress bar. The best thing about this plugin is that it doesn't uses flash and works on IE too. I strongly recommend using this plugin
Donot use taglibrary defined file upload for uploading. You can still use
common- fileupload to handle file upload. By doing this you can dynamically
add one more input type file element below the current input type upload using
javascript. I doubt if there is any way to do this using pure struts 1.3.5 :) .