svg file don't show in WordPress - wordpress

I want to upload an svg file to a WordPress site but unfortunately, after uploading to the server, this file turns into an empty svg file with a size of 22 bytes, and there is no code or script in the uploaded file.
I also used plugins like safe svg, but it didn't work. Can anyone guide me to solve this problem?

Related

Insert css files to localhost

For some reason, I could not get my files to load in my localhost. Trying different path solution but my error is still same. You can see from pictures my file-tree, where is index.file and css.folder with files. Any sugestions what to type in to get my css files load. Thanks

PhpStorm Sync Less and CSS File

I have a folder structure like in the following picture. The less node.js I would compile with. I am calling the compiled CSS file in the meta-tag section.
When a change is made in the less file, the CSS file is automatically loaded on to the server I want to be.
Summary : If style.less changes in style.css to upload to the server.
Thanks for your help.
I solved the problem. Tools->Deployment->Options -> Upload external changes chose.

Atom Remote Sync - Upload compiled CSS file when saving Less file?

I'm a new user of GitHub's Atom and I installed the less-autocompile package to automatically compile my Less files to CSS. I'm wondering if there's a way I can upload my compiled CSS file to my remote server when saving my Less file.
Right now I'm using Atom's Remote Sync package to upload my files through FTP on save.
When I save changes to my Less file, the actual Less file gets uploaded to my server but what I would like to achieve is that when saving my Less file, the compiled CSS file gets uploaded to my remote server as well.
Right now I have to save the CSS file manually so it gets uploaded, this is breaking my workflow.
Does anyone know how to achieve this?
Thank you!

WordPress : Media Library broken images

When I upload image to WordPress, they randomly appear as broken links.
I can drop the files on the Media Library or Select the files and some files are always shown as broken.
I can delete the files and re-upload the same group and different images in the group can show as broken.
I'm sure it's nothing to with the images as they sometimes appear as broken and then sometimes don't.
Locally the upload works fine, this problem started happening on the live hosting - I thought it could be something to do with permissions but then wouldn't it show all the images as broken and not show random images as broken.
I don't get an error but a broken image icon. If I click the broken link it case me to the Attachment Details page. Sometimes the image does appear here sometimes it doesn't.
Some things to look for:
1) check if there is an .htaccess file in the wp-content/uploads folder or wherever you keep your images (make sure you have the option to see hidden files--I think they're available by default when you're using an FTP client but if you're in the File Manager of your CPanel then you have to enable this option, either before entering file manager or from settings when you're in the file manager depending on your host). If there is an htaccess file, you'll want to back it up and then research more about this before you make any changes to it. https://codex.wordpress.org/htaccess_for_subdirectories
2) if you had tried to move your default image directory using wp-config.php make sure that has been set up properly
3) check folder and file permissions settings. it's best to do this in an FTP client because if you need to change the permissions, it can do it recursively and include all subdirectories and files within them instead of having to go through into each folder and change the permissions.
http://www.wpbeginner.com/wp-tutorials/how-to-fix-image-upload-issue-in-wordpress/

external CSS sheet not loading to hosting

I'm having trouble making my CSS external stylesheet work in my actual hosting. It all works fine when I open the files from my Finder (I'm using a mac), but the stylesheet does not seem to load to my server properly. All other html files load fine and are visible when you visit my website in any browser,this is my website and the File Manager on my cPanel indicates that the CSS folder and external stylesheet file have been successfully uploaded for enough time that the style features should display. I tried clearing my browsing history and reopening my browser.
My link tag is and I have tried it using aswell as with just "css/socialpolarities.css". I've checked to make sure the spelling is right on the path and corresponds to the actual file.
Is the answer to just put all the style files in the public_html folder and then just change the path on all my html files? Or am I missing something?
I'm also using LiquidWeb if that means anything
The file css/socialpolarities.css seems to exist, but is void of content.
try looking at your local file to make sure it is indeed the one with the css code, then upload it to the same folder and override the original one.
You may have had an upload error.
I got it! The problem was actually that I needed to put the css file in the home directory, for some strange reason. My path from my html files definitely specified that the css files were in a css directory so I'm not sure if it's something I did wrong or whether the cPanel just sucks. Regardless, it works so I won't mess with it. Now time to copy all of my webfont files into my home directory...this is going to be messy lol.
Check your permission. They should be 755. You can search about permissions on internet. I changed the permissions and it worked fine.

Resources