Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Thumb SEO name #34

Closed
zlobec opened this issue Apr 11, 2018 · 15 comments
Closed

Thumb SEO name #34

zlobec opened this issue Apr 11, 2018 · 15 comments

Comments

@zlobec
Copy link

zlobec commented Apr 11, 2018

Hi,

the resized images get this pretty "un-SEO" name (eg. thumb__300_300_0_0_crop.png). Is there a way to give this files nice SEO names (eg. my-coffee-machine__300_300_0_0_crop.png )? From maybe the slugified ALT or Title value?

Regard,
Darjan

@AlexisWalravens
Copy link

Came here to ask exactly the same question:
Any news on this ?
It would be nice to have an option to either keep the original name in the file name or like @zlobec said, get the name from the title value.

Thanks,
Alexis

@kevinvermeulenn
Copy link

I want to have this too! :)

@zlobec
Copy link
Author

zlobec commented Aug 28, 2019

Would this help solve the case?
https://octobertricks.com/tricks/use-original-filename-thumbnail-name

@matteotrubini
Copy link
Collaborator

@zlobec it seems a good start. Can you submit a PR?

@zlobec
Copy link
Author

zlobec commented Aug 29, 2019

@matteotrubini I'll try over the weekend. Work comes first :D

@matteotrubini
Copy link
Collaborator

This plugin is being migrated to core (see #55), so we are trying to figure out what issues are still relevant to invite to reopen them in core.

Issues that will remain inactive in next 30 days will be closed.

@klaemo
Copy link

klaemo commented Aug 18, 2020

This would still be a nice to have for us.

@LukeTowers
Copy link
Contributor

@klaemo this will exist in the core when the PR is merged, filenames look like http://october.local/storage/app/resized/f26/844/3d0/original_filename_resized_f268443d0130367963d708e60ac40e8c2324ba4d.png for plugin, theme, and media sources, while File Model sources still retain the existing filename scheme for backwards compatibility.

@LukeTowers
Copy link
Contributor

@matteotrubini you can close this.

@klaemo
Copy link

klaemo commented Aug 18, 2020

@klaemo this will exist in the core when the PR is merged, filenames look like http://october.local/storage/app/resized/f26/844/3d0/original_filename_resized_f268443d0130367963d708e60ac40e8c2324ba4d.png for plugin, theme, and media sources, while File Model sources still retain the existing filename scheme for backwards compatibility.

That’s excellent! Thank you so much!

@matteotrubini
Copy link
Collaborator

@klaemo this will exist in the core when the PR is merged, filenames look like http://october.local/storage/app/resized/f26/844/3d0/original_filename_resized_f268443d0130367963d708e60ac40e8c2324ba4d.png for plugin, theme, and media sources, while File Model sources still retain the existing filename scheme for backwards compatibility.

IMHO filename composed in this way is too long on SEO perspective.

Suggestions:

  1. http://october.local/storage/app/resized/f26/844/3d0/original_filename.130367963d708e60ac40e8c2324ba4d.png
  2. use Base64Url::encode(pack('H*',$fileIdentifier)) to create the path/filename (from 40 hex digits to 28 alpha chars): http://october.local/storage/app/resized/8mh/EPQ/EwN/original_filename.nlj1wjmCsQOjCMkuk0.png
    ref. https://github.com/Spomky-Labs/base64url

If my suggestion would become relevant, its discussion should be moved to octobercms/october#5231

@LukeTowers
Copy link
Contributor

@matteotrubini I would have to see references that prove filename length actually affects SEO before I would consider that.

@zlobec
Copy link
Author

zlobec commented Aug 19, 2020

I also haven't yet found any exact information on image name length regarding SEO... There is no official length limitation... only a lot of referencing on "keyword stuffing".

I guess it should be constructed the same as any URL ... so the imposed 2,083 character limit, and "friendliness" / "readability" is highly implied.

@matteotrubini
Copy link
Collaborator

https://support.google.com/webmasters/answer/76329?hl=en

A site's URL structure should be as simple as possible. Consider organizing your content so that URLs are constructed logically and in a manner that is most intelligible to humans (when possible, readable words rather than long ID numbers).

avoiding irrilevant part, like "resized" in filename - my note

Consider using punctuation in your URLs. The URL http://www.example.com/green-dress.html is much more useful to us than http://www.example.com/greendress.html. We recommend that you use hyphens (-) instead of underscores (_) in your URLs.

https://ahrefs.com/blog/image-seo/

Google isn’t perfect—you should do everything in your power to help them understand your images.
That doesn’t mean keyword stuffing. Keep your filenames descriptive and straightforward.

Finally, if I use PageSpeed - Optimize Images filter I get an url semantically separated by dots, so I've some suspicious that dots can be a signal to identify the relevant part of the url (file extension can be - or are - less relevant, right?).

@LukeTowers
Copy link
Contributor

@matteotrubini from what I see there it seems like the current approach is fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants