Local.xml change or only adding files? - magento

I found out, that frontend/base/default/template/bundle/catalog/product/view/type/bundle/option/select.phtml
does control the parts of my bundle-pages that I want to edit. So, alright I could edit this file directly but I learnt, that isn't recommended due to upgradability-problems.
So, what would I alternatively need to do? Do I just need to add a new file
frontend/my_package/default/template/bundle/catalog/product/view/type/bundle/option/select.phtml
like this and put all my stuff in there, or do I also need to reference something into my layout within local.xml? How would I do that?
Thanks

So yes simply make this file in your theme and then you can edit it to fit with your design.
The other option which is a bit more complex is to update the template via some layout xml and then this new template will be used and you can add it to the base folder with whatever new path you like. I would suggest that your changes are probably theme specific and so should be made by making the changes in your theme.

Related

How to add new UI to cocos2d-x library

I have a question about adding new UI widget (in my case its an EditBox but with UIEditView instead of UIEditBox). I make some changes to UIEditBox, named it UIEditView and put into UI folder. Add all the files to the new created group
Included it in CocosGUI.h, but still can not use it.
Here the default list
Both Classes in my UIEditView have unique names
Names of classes
So what wong? ;(
Thanks in advice
I can't see the entire class, but from what I can see if you just try to access ui::UIEditBox without cocos2d in front of it, it might work. If that's not the case make sure you have NS_CC_BEGIN or using namepace cocos2d in your header and cpp file.
Also you don't have to add your custom ui into the cocos ui folders, unless you want to push it back to to project. Otherwise I have a folder for CustomUI that I host on GitHub as a opensource project so others can use it. Just makes it easier to manage.
If this did not help can you please post more of your files, if you don't mind sharing, will make it easier to help you.

How to use hooks in CS-Cart for overriding footer.tpl file

I am new to cs-cart and
I am trying to use hooks in cs-cart. I had gone through some cs-cart website but not getting proper answer. Suppose if i want to override footer.tpl file with new content then how can i do it using hooks. Just tell me the steps what code to write in index.tpl file and where to keep new footer.tpl file.
I'd suggest you to check this brief guide: http://docs.cs-cart.com/hooks.
Assuming you're on a version 4.x.x:
You don't need to edit anything in index.tpl, just take note of the name of the hook you want to use (I suppose you want to use this one {hook name="index:footer"})
Write your new template and give it the name footer.[override/pre/post].tpl
Save this new .tpl file in themes/[your_theme_name]/templates/addons/my_changes/hooks/index (maybe you need to create such directories in your folders tree)
Make sure you have the "my changes" addon installed and active. You can check it through your admin area of the store.
And that's it, it should work.
Notes:
I've seen no standard "footer.tpl" file in version 4.x.x., so the above instructions work, but they only append content at the end of the page. Customization of such page area can be done via the layout and theme editor on the admin area of the store.
The naming algorithm mentioned on the documentation of cs-cart is for
version 3.x.x. Since version 4.x.x. the folders names have varied.
You should replace skins/[skin name]/[admin|customer] for
design/themes/[your_theme_name]/templates

Change button-image using overrides

I would like to change the image of the "Check out now" button in the cart view of VirtueMart. I know the image is located at joomla_root/components/com_virtuemart/assets/images/vmgeneral/backgrounds.png and that I could change it there.
But I fear that this change will be reverted once I update VirtueMart somewhen. I heared about overrides in Joomla, but I found no description how to use them for images.
Edit
The image seems to be used multiple times for different buttons. I want to change them all, so that's no problem - but I would like to avoid overriding every single file using this image.
The css-file for these buttons is located at components/com_virtuemart/assets/css/vmsite-ltr.css. Maybe it would be the best solution to override this file? This should change every button. But where do I have to locate the new css-file and the new image?
In each template there is a "template" override folder... Usually at:
/templates/yourtemplate/html/
You can simply add another folder inside it for the component you wish to work on like so:
/templates/template_name/html/com_component/view_name/view_file.php
You have to figure out which view in virtumart uses your background image... then find the php file in that view and copy the file entirely to the path where you created for you override
Basically the file at
/templates/template/html/com_virtumart/view_name/view_file.php
Will override the one in the normal place like:
/components/com_virtuemart/views/view/tmpl/whereve.php
So when you update virtumart and it overrites the normal install path... your override file won't be touched!
Hope that helps
MORE SPECIFICALLY SOMETHING LIKE:
yoursite.com/templates/your_template/html/com_virtuemart/productdetails/default.php

JOOMLA, Best way to make alternate layouts for articles?

I can't find a answer for this, I want to know what is the best way to have an alternative layouts for articles in Joomla.
If I understand you correctly you are looking for a way to create additional Alternative Layouts for articles. Under parameter tab "Article Options":
If that is the case, its very close to the other provided answers here. Its just that you got to rename the copied default.php file to something else. If you rename it to custom.php it will end up with the text "custom" like the image above.
Here goes my shot for a step by step:
Find the default layout file(s). You could use the ones provided by the com_content component. They can be found at components/com_content/views/article/tmpl. Copy both default.php and default_links.php.
Now you need to rename and copy the file(s) into a template. The target template can be any of the installed templates. Using beez_20 the new path for the copied file(s) should be templates/beez_20/html/com_content/article/custom.php and templates/beez_20/html/com_content/article/custom_links.php.
Goto to edit article using the backend. Expand the Article Options tab and find Alternative Layout. Select your new layout.
Your template might already provide a article override. If so, you might want to use the files of that template instead (instead of the ones in step 1). So if you are using beez_20, you could copy templates/beez_20/html/com_content/article/default.php and templates/beez_20/html/com_content/article/default_links.php.
Helpful links:
Using Joomla’s Template and Layout Override
Layout overrides in Joomla 1.6
The best way to do this would either to install another content component - such as k2 which is highly customizable. Or any other content component on JED.
Alternatively you could create a template override on the existing Joomla Template. This is preferable to editing the files directly in com_content component as the template overrides will never be overwritten whereas the core files will be in any Joomla Updates. I should add, hopefully unnecessarily that this requires Joomla 1.5, 1.6, 1.7, 2.5 or 3.0 (although this is still in beta as of present). So make sure you're not using 1.0.
To create an alternative layout for the built in articles component the best way to do it is probably to create a template over-ride.
See this article on docs.joomla.org on "How to override the output from the Joomla! core"
Creating an alternative for an article layout is pretty straight forward. You can achieve this by using the core layout override with your published template(s).
First you want to get/copy the core article layout file:
components/com_content/views/article/tmpl/default.php
Then place it into your published template:
templates/YOURTEMPLATE/html/com_content/article/default.php
If the template you are using doesn't have the html folder, then you will have to create that folder and each folder to make that path correct.
Once you have this in place, all you need to do is make changes to that default.php file you have just place in the template and that is it!

How can i make customized template for the front end by overriding the default one?

I am new to Pyrocms and reading the documentation I could not change fix my problem. I need my own template to be incorporated that is I want to change the default one provided. How can I do that. I really need a help.
Go into:
system/cms/themes/default/
This is the folder where you can find the default template of pyrocms. There you will see folders like "views, css, js, img" etc.
You can start by modifying views/layouts/default.html and views/partials/ folder.
Ofcourse if you need to change css and/or js you need to modify them too.
By the way this is the official pyrocms documentation for editing themes:
http://www.pyrocms.com/docs/manuals/designers

Resources