Can't use templates to override smartpocket theme #417

Open
opened 2026-10-04 23:57:15 +02:00 by adam · 3 comments
Owner

I encountered this problem back in v2.7.2 and tried again with the latest v2.8.0. Not a big deal, but it bugs (ha) me.

I am unable to use templates to override the smartpocket theme. When I do, I get strange results like this:

img_6007

If I make the same changes directly to the .tpl files in the smartpocket directory, everything is fine. I'd prefer to use templates though so my customizations aren't lost during upgrades (and that's what the templates are for after all).

Operating system: Linux
PHP: 5.6.11-1ubuntu3.1 (Show info) [2016-03-09 19:27:37]
MySQL: 5.6.28-0ubuntu0.15.10.1 [2016-03-09 19:27:37]
Graphics Library: External ImageMagick 6.8.9-9

I encountered this problem back in v2.7.2 and tried again with the latest v2.8.0. Not a big deal, but it bugs (ha) me. I am unable to use templates to override the smartpocket theme. When I do, I get strange results like this: ![img_6007](https://cloud.githubusercontent.com/assets/11047158/13655475/a4ed85f6-e62d-11e5-88fe-7a6be1dfa992.PNG) If I make the same changes directly to the .tpl files in the smartpocket directory, everything is fine. I'd prefer to use templates though so my customizations aren't lost during upgrades (and that's what the templates are for after all). Operating system: Linux PHP: 5.6.11-1ubuntu3.1 (Show info) [2016-03-09 19:27:37] MySQL: 5.6.28-0ubuntu0.15.10.1 [2016-03-09 19:27:37] Graphics Library: External ImageMagick 6.8.9-9 <!-- github-sync-id:139745677 -->
Author
Owner

I don't really see that as a bug since mobile theme is very specific and is handle differently; if i'm not wrong, you can have only one enabled where as several regular themes can be enabled.
You just have to build a custom mobile theme, child of Smartpocket

I don't really see that as a bug since mobile theme is very specific and is handle differently; if i'm not wrong, you can have only one enabled where as several regular themes can be enabled. You just have to build a custom mobile theme, child of Smartpocket <!-- github-comment-id:194735619 -->
Author
Owner

Ok, that's fine, but maybe mobile themes should be hidden from the dropdown on the templates page then so people don't try to override them. I'll go the child theme route I guess.

Ok, that's fine, but maybe mobile themes should be hidden from the dropdown on the templates page then so people don't try to override them. I'll go the child theme route I guess. <!-- github-comment-id:194987530 -->
Author
Owner

FYI, creating a child theme of smartpocket has helped me work around the problem for now. Thanks for the suggestion.

FYI, creating a child theme of smartpocket has helped me work around the problem for now. Thanks for the suggestion. <!-- github-comment-id:196000609 -->
Sign in to join this conversation.
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: adam/Piwigo#417