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

Create various new base urls for use with Content Delivery Networks #1259

Closed
havenswift-hosting opened this issue Sep 22, 2016 · 10 comments
Closed
Assignees

Comments

@havenswift-hosting
Copy link

CubeCart should allow the configuration of multiple base URL's so that they can be adjusted by content management modules without the need to re-work an entire store theme.

It would be handy to be able to specify the following configurable items in the store admin area

"Base URL"
This already exists today via smarty {$STORE_URL}

"Base SKIN URL"
A new smarty variable that can be used to define the path to your store URL, base skin directory. Essentially a join of STORE_URL and /skins//

"Base Media URL"
A new smarty variable that can be used to define the path to your skins image directory. Essentially a join of STORE URL and an additional path.
example STORE_URL/skins//images/

"Base JS URL"
A new smarty variable that can be used to define the path to your skins JS directory. Essentially a join of STORE URL and an additional path.
example STORE_URL/skins//js/

"CubeCart JS Path"
A new smarty variable that can be used to define the path to the CubeCart "JS" directory. Essentially a join of STORE URL and an additional path.
example STORE_URL/js/

Having these items used in this way means it's possible to override them via a module and produce modules that can use content delivery networks.

@Noodleyman
Copy link

+1

@abrookbanks abrookbanks added this to the 6.1.0 milestone Oct 24, 2016
@abrookbanks abrookbanks self-assigned this Oct 24, 2016
@havenswift-hosting
Copy link
Author

Thanks for adding those and they can now be used in custom skins but it would be much better if they could also be used in the stock Foundation skin

@abrookbanks
Copy link
Member

They are available to use in any skin.

@havenswift-hosting
Copy link
Author

Yes, but without the Foundation skin being updated in the required places, the original requirement for this will not be able to be used with the Foundation skin. Custom skins based off an earlier version will obviously need to be separately updated

@abrookbanks
Copy link
Member

How does it need to be changed?

@Noodleyman
Copy link

Noodleyman commented Oct 25, 2016

Al, I think the point of this ticket may have been overlooked. The idea is to add configurable settings within the admin area which defines the paths, or allows the admin of the store to modify the paths of the "js" directory, "images" directory etc.

The point is, when using a CDN you want to replace your base URL's with those provided by the CDN, so your images come from their network rather than your server. Without being able to configure this on bulk within the admin area, the additional smarty variables are not actually that useful.

for example, say I wanted to load my images from the CDN. I would need to replace ALL of my image URL's with those of my CDN URL.

If my CDN was https://cdn.noodleman.co.uk/images
and for example, one image link was
https://www.noodleman.co.uk/images/noodleman.png

I would need to replace the link to the image on my store skin with:
https://cdn.noodleman.co.uk/images/noodleman.png

So, being able to define that all of my images can be found on "https://cdn.noodleman.co.uk/images" is the requirement. This would require the ability to configure the paths within the store admin area as well as have all the stock store skins updated to include the use of the new path settings.

Modules can then be used to override the URL's as required, and provide the other requirements needed for a CDN

abrookbanks added a commit that referenced this issue Oct 25, 2016
This reverts commit 230c0f7.
@abrookbanks
Copy link
Member

Oh I see. That's all new news to me. LOL

I have reverted this and reopened for looking at again in the future.

@abrookbanks abrookbanks reopened this Oct 25, 2016
@abrookbanks abrookbanks removed this from the 6.1.0 milestone Oct 25, 2016
@bhsmither
Copy link
Contributor

What are your thoughts on a solution for managing the rendered image derivatives? (The /images/cache/ contents, where the image links are actually pointing to?)

Will the CDN solution be able to upload the derivatives to the CDN repository?

@havenswift-hosting
Copy link
Author

As that is what CubeCart actually uses when displaying images, those will definitely be part of the CDN solution !

@bhsmither
Copy link
Contributor

So, what I see is at least a need for more hooks at FileManager->imagePath().

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

4 participants