Magento theme problem - templates

I tried creating a new theme in Magento by creating the following folders:
/app/design/frontend/interface/default
/skin/frontend/interface/default
I copied into these folders the entire content of the base/default folders (in both skin and design).
I enabled the theme bu putting "interface" in "current package name" for a website and expected it to look like the theme I had copied, but for some reason, nothing in the head is loaded. No css, js, ...
I checked and all my xml/css/js files are all there though ... What might the problem be?
The .phtml files are all being loaded.
EDIT:
I also noticed that selecting "base" as default package does not work either, but if you select "default", then it does load the base theme phtml files with some base and soem default css ...
EDIT2
Fixed, not sure where the error was ...

Did you refresh the caches?
On development stations its good practice to disable all Magento caches, until everything works, because sometimes it's really easy to forget to refresh them.

Magento have a structure, its better to put your custom magento theme design folder into app/design/frontend/default/themename this is PHTML path and for CSS and JS you can put the folder in skin/frontend/default/themename
After that just delete the cache and enable the theme from either admin > system > configuration > design or from admin > system > design and select you custom magento theme

Related

Implementing themes in Django (Custom templates by users)

I want to implement the feature for admins to set custom templates. Like they can place themes or templates in a particular folder relative to the home folder.
Each theme may have a folder and some config or preview for example(optional).
1) First I need to figure out how to set custom templates dir for an app.
2) Then I can probably do listdir and get all the folders and then give the admin an option to select the dir.
3) A setting list to specify additonal template folders by users.
1 is the problem.
The main question I want answer for is how to set custom template dir which can be modified anytime.
I found out that askbot (the SO clone) implements this kinda theming where you can place themes in subfolders a folder and the admin can select the folder which he/she wants the templates.
I am new to Django. I guess you can do it using jinja templating.
http://jinja.pocoo.org/
Add a common styling to one html page(base.html)
and then extend the base html to whichever pages u want using extends-- check out template inheritance in the above link
Also you can get some cool templates in bootstrap.. checkout their template section. https://www.w3schools.com/bootstrap/bootstrap_templates.asp
Good luck!

How to set different theme for different store in opencart in multistore installation?

I have installed multi-store in my open cart installation. I want to set different theme for my two different stores. I have copied the /catalog/view/theme/default folder and renamed it to mytheme. But still this mytheme is not added to store theme drop down option.
Can any one please explain, how it will possible ?
Default theme has these files in admin folder, you need to create these file for your new theme.
admin/controller/extension/theme/theme_default.php
admin/language/en-gb/extension/theme/theme_default.php
admin/view/template/extension/theme/theme_default.tpl
Don't forget to edit them and replace theme_default with mytheme, for example:
class ControllerExtensionThemeThemeDefault extends Controller {
edit it to:
class ControllerExtensionMytheme extends Controller {
After create above files go to Extensions/Extensions and select Themes from deopdown menu, here you must see your theme setting, now you can enable it.
When you enable it, you can assign it to your store from system/settings

How to hide the template name?

this is my local site: drupaltest1/
When I/anyother developer inspect my site they can recognize which theme I am using. I want to hide the theme being displayed on inspect elements an display the site name in the path. I searched google, but no luck. Anyone please help in achieving this.
Thanks in advance
You could change the name of the theme to your sitename.
in sites/all/themes/ copy your theme folder and rename the folder
then replace the theme name in .info file and use find/replace in template.php and any other theme specific files as well. (notepad++ search in files works well)
upload and enable the new theme in Drupal
If you are not using a custom theme for your site, be sure to check the licensing/copyright to ensure renaming it isn't a violation - and updates may have issues so you could remove the project info and/or packing script info.
If you can create a sub-theme, then you would be able to hide those info(s) from being inspected your site pages.
Please reply if this helped you.
https://www.drupal.org/node/1010576
https://www.drupal.org/node/225125

Joomla 3 Template override a plugin

I could not find any info on overriding a Joomla plugin in my template.
Some forums claimed there was no plugin override, and the Joomla documentation (being the menacing forest that it is) either has nothing on the subject, or the page is hard to find.
So how can we override the output of a Joomla plugin in the same was we override the output of com_content or mod_contact?
I have found a way to do this:
Navigate to <joomla_homefolder>/administrator/language/<your_language>/
Search for the plugin's corresponding language file.
Copy the file name, EXCLUDING the language prefix (ie en-GB.) and the .ini suffix.
In your template create a folder named html (a common practice for template overrides).
In the html folder create a subfolder and name with the language file name as you copied it in step 3.
Navigate to the tmpl subfolder in the plugin's path: <joomla_homefolder>/plugins/<plugin_type>/<plugin_name>/tmpl
Copy the view file you wish to override into the folder you've created in step 5.
Modify the copied file to override the plugins output.
For example -
To change the page navigation buttons - modify the output of <joomla_homefolder>/plugins/content/pagenavigation:
Go into <joomla_homefolder>/administrator/language/en-GB/ and find the file named en-GB.plg_content_pagenavigation.ini.
From the filename copy only plg_content_pagenavigation.
Create a folder named html (If it does not exist already) in your theme, inside it create a subfolder and name it plg_content_pagenavigation.
Copy the view file <joomla_homefolder>/plugins/content/pagenavigation/tmpl/default.php into the plg_content_pagenavigation folder you just created.
Modify the file.
Note: I have tried it only with Joomla 3.1.
The method may not work with some plugins.
Good Luck.
In joomla 3 you can override plugins output only, that's why the origin plugin must be implemented with a tmpl.
The naming convention of the folder in you [template]/html is
plg_[type*]_[pluginElement]
Template overridden native joomla plugins is only the pagenavigation.
type* : obviously there's no sense to be other than content but if it's custom plugin no one can stop you.
On a Joomla 3.1 install, I am using the Simple Image Gallery plugin and I felt the need to override it in order to add extra functionality to each thumbnail of the gallery.
I copied all of the contents of <joomla_homefolder>/plugins/content/jw_sig/jw_sig/tmpl/ into the folder <joomla_homefolder>/templates/protostar/html/jw_sig/ and I was then able to modify both the default.php file for output modifications, and the accompanying template.css file for styling modifications. This successfully overrides the plugin's output without risking issues during future updates.
Of course, this will not work with all plugins, but it offers another alternative if you have a plugin that was nice enough to be developed with a tmpl folder.
No you can't override the same way because there is not tmpl folder because plugins really should not be rendering though of course a lot do. You probably need to clone the plugin and make a the layout your want possibly using a jlayout to make it easier to manage.
Elin's answer is not quite correct for Joomla 2.5-3.x. Some plugins do render screen output and have /tmpl folders that you may be able to override. See http://docs.joomla.org/Layout_Overrides_in_Joomla
In some cases you may need to create alternative views within the plugin /tmpl folder. For example, some of the simple, newer custom content components that use JForms let you add fields to com_content articles and select a view template for each field. Then overrides for com_content are generated dynamically to display the custom fields. Each field type can be displayed in the component area through plugins, or in a module, or within the template code, but it will use the /tmpl file you selected for the field in the CCK component. If there is a way to override the different field views from within the template folder, it must require an arcane menu structure I haven't been able to discover.

Changing Django built in admin style sheet

I wish to change the built in blue colours for the admin pages.
I used Firebug in Mozilla to try and find the colours around different style sheets I found in the Django.1-3 folder, but none seem to come up.
In what directories would I find the .css files for pages that have the header dark blue colour and the light blue table captions colour?
What actions must I take in order for the changes to work(eg. move folder to main project folder)?
https://docs.djangoproject.com/en/1.3/howto/deployment/modwsgi/#serving-the-admin-files
The admin files live in (django/contrib/admin/static/admin) of the Django distribution.
You have the source. You can change these files.
One common approach is to (1) copy the static admin files to a separate directory that your web server can use, (2) configure your web server to serve these files, and (3) change your settings.py to reflect this new location for your admin media.
https://docs.djangoproject.com/en/1.3/ref/settings/#admin-media-prefix
No template changes are made.
Nothing needs to be moved into your "main project folder" (whatever that might be).