Magento Forum

   
Page 1 of 3
Want to save time If only I knew this In the beginning Add your Hot timesaving Tip
 
Bill007
Sr. Member
 
Avatar
Total Posts:  179
Joined:  2008-01-15
New Zealand
 

Some hopefully important Tips that could save a lot of time I have reposted this as I felt I got Lost

Also any body who does fix something post it for all of our sakes and this forum will work so much better we are the beta testers lets do our bit and help get this open source project rocketing

For All of you that have yet to struggle and for those of who have struggled with wrapping you head around the template engine{ I have been one of those people} here are some handy hints from my perspective Oh and its great once you get it Nice one Magento

This info could have saved 3 hours alone the caching system works great in fact to great because any changes with this Cache system enabled will not show the changes in the layout .xml file that you have uploaded also hitting ctrl f5 does not clear the cache

Step One Turn off all Caching in your demo store >>system>>cache management
Step Two Disable all cache controls except Configuration
Step Three Check Mark Refresh Cache

SAVE SETTINGS

Now the Second bit I had trouble (could’ve save 5 hours here )with was where is MAIN.XML god I looked for ages, its mentioned through out all the wiki posts and old forum posts that were searched from the forum {catch 22 searching and getting info about the old file naming} <?php $ *{naughty Magento on the wiki post those should be updated straight away thats a red hearing}

So forget main.xml it lives no more what magento have done is clever but at the same confusing

If you Want to change the position of things for Example the newsletter widget on the home page take it from the default of the right hand column position over to the New left hand Column position

OK HERE IT IS

Go straight to app/design/frontend/your_interface/your_theme/layout/newsletter.xml

Here it is

Look below and find the code that looks like this <reference name="right"> there are two instance in Newsletter.xml

Now change the code to <reference name="left">

Upload and review your browser hit CTRL F5

I bet you see the changes

<layout version="0.1.0">

<!--
Default 
layoutloads most of the pages
-->

    <default>
        
        <!-- 
Mage_Newsletter -->
        <
reference name="right">
            <
block type="newsletter/subscribe" name="right.newsletter" template="newsletter/subscribe.phtml"/>
        </
reference>

    </default>

<!--
Customer account pagesrendered for all tabs in dashboard
-->

    <
customer_account>
        <!-- 
Mage_Newsletter -->
        <
reference name="customer_account_navigation">
            <
action method="addLink" translate="label"><name>newsletter</name><path>newsletter/manage/</path><label>Newsletter Subscriptions</label></action>
        </
reference>
    </
customer_account>

    <
customer_account_index>

        <
reference name="right">
            <
action method="unsetChild"><name>right.newsletter</name></action>
        </
reference>
    </
customer_account_index>
    
    <
newsletter_manage_index>
        <
update handle="customer_account"/>
        <
reference name="content">
            <
block type="customer/newsletter" name="customer_newsletter"/>
        </
reference>
    </
newsletter_manage_index>

</
layout>

I do hope this is useful

Magento I do Like what you are doing All round I think you will do real well your web presence is shaping up nicely

All so the webinars are real good

http://www.billbailey.co.nz Life is about People and the way we Treat them

 
Magento Community Magento Community
Magento Community
Magento Community
 
peach
Jr. Member
 
Total Posts:  22
Joined:  2008-01-11
 

nice writeup mate, I’m sure it will be helpful to many.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Bill007
Sr. Member
 
Avatar
Total Posts:  179
Joined:  2008-01-15
New Zealand
 

Here is a great Time saving Tip

you must Have Mozilla if not go get it and add the Web Developer Tools
Open Mozilla Browser

THEN GO >>Tools>>Web Developer>>CSS>>Edit CSS

Yo will see a new window panel at the foot of the Browser Pull it up till you can see whats going on

A standard Magento CSS file call out will look like this BELOW { Great these guys pulll all the CSS in thru the Head keeps the code down on the page SEO}

styles.css
reset.css
boxes.css
menue.css
clears.css
custom.css

the great thing here is you make Changes on the fly so its just a tempory changes choose the tab of the file you want to tweak and start making changes you will see immediate results if you like it copy and past the CSS code tweaks into the appropriate .CSS file if not refresh the browser and try again its great you will learn heaps about CSS this way

OK so if you want to muck with the header BG colors go to reset.css find

body {
background:url(../images/body_bg.gif) repeat-y 50% 0 #496778; <--------CHANGE THE COLOR HERE
color:#2f2f2f;
font:12px/1.55em arial, helvetica, sans-serif;
text-align:center;
}

How ever most changes will be done on boxes.css play around and find out what does what

If you dont Know CSS XHTML PHP save your time use an expert

Bill Bailey http://www.euphorish.com web design free downloads

 
Magento Community Magento Community
Magento Community
Magento Community
 
Bill007
Sr. Member
 
Avatar
Total Posts:  179
Joined:  2008-01-15
New Zealand
 

to get your favicon sorted

this link

http://www.magentocommerce.com/boards/viewthread/2812/

bill007

 
Magento Community Magento Community
Magento Community
Magento Community
 
Electric-dsctc
Member
 
Avatar
Total Posts:  35
Joined:  2008-01-21
 

Bill...excellent initiative !  I wish this post already existed when I started with magento… you wouldn’t believe the time I spend on simple stuff ....

Here is my tip : combining the top links or adding a new one .
I spend some time trying to do this but didn’t get to it because I never fully understand how it’s done.

You can see that you have on your page.xml , on the default handler something like this:

<block type="page/html_header" name="header" as="header">
     <
block type="page/html_toplinks" name="top.left.links" as="topLeftLinks"/>
     <
block type="page/html_toplinks" name="top.right.links" as="topRightLinks"/>
 
     <
block type="core/text_list" name="top.menu" as="topMenu"/>
</
block>

So there we have the header block and we are including on it two other blocks; top.left.links and top.right.links .
The important thing here is that those blocks are referenced in other xml layouts, such as in catalog.xml or checkout.xml , where the links are actually made .  I had a lot of trouble finding/understanding where it was actually made
This is in checkout.xml for example :

<reference name="top.right.links">
            <
block type="checkout/links" name="checkout_cart_link">
                <
action method="addCartLink"></action>
            </
block>
            <
block type="checkout/links" name="checkout_link">
                <
action method="addCheckoutLink"></action>
            </
block>
        </
reference>

So you see that there is an action called, with a method “addCheckoutLink” . Hm..wander what that does , right? rasberry
And you see that both blocks are in reference name “top.right.links “

If you want to merge the menus together, you should rename the reference on all the correspondent layouts (say catalog.xml , checkout.xml, etc...) from top.left.links and top.right.links to something like “top.links” or whatever you like.

So the first piece of code (the one on page.xml ) should be now

<block type="page/html_header" name="header" as="header">
         <
block type="page/html_toplinks" name="top.links" as="topLinks">
     </
block>
         <
block type="core/text_list" name="top.menu" as="topMenu">
         </
block>
</
block>

You see that one block is gone, because we are merging both.
And this changes on layout pages such as catalog.xml, or chekout.xml (this example)

<reference name="top.links">
            <
block type="checkout/links" name="checkout_cart_link">
                <
action method="addCartLink"></action>
            </
block>
            <
block type="checkout/links" name="checkout_link">
                <
action method="addCheckoutLink"></action>
            </
block>
        </
reference>
        <
reference name="right">
            <
block type="checkout/cart_sidebar" name="cart_sidebar" before="-" template="checkout/cart/sidebar.phtml"/>
        </
reference>

now, adding a link :
if you look at the code above you’ll see that the link is done with <action method="something"> ; there is a method called “addLink” , wich does.....a link, obviously .  tongue wink

<block type="page/html_toplinks" name="top.links" as="topLinks">
                    <
action method="addLink"><li/><a>href="{{baseUrl}}your/link/here"</a><labelHome </label></action>
</
block>

the {{baseUrl}} thing adds your site path.

Hope this helps...thanks to all the people that help me get to this!

 
Magento Community Magento Community
Magento Community
Magento Community
 
lotusseedsD
Mentor
 
Avatar
Total Posts:  1144
Joined:  2007-08-31
 
Bill007 - 23 January 2008 12:48 AM

Some hopefully important Tips that could save a lot of time I have reposted this as I felt I got Lost

This info could have saved 3 hours alone the caching system works great in fact to great because any changes with this Cache system enabled will not show the changes in the layout .xml file that you have uploaded also hitting ctrl f5 does not clear the cache

Step One Turn off all Caching in your demo store >>system>>cache management
Step Two Disable all cache controls except Configuration
Step Three Check Mark Refresh Cache

SAVE SETTINGS

Bill007 Thank you so much for posting this!!!!!

I wasted more than 5 hours couldn’t get my ‘topLeftLinks’ showed up because it’s no longer part of the ‘header’. It was working with 6.x version and I couldn’t find anything wrong . Just as I was about to post screenshots and codes for help, I saw your post.

Small detail like this often gets neglected.

Roy, how about adding a sub forum ‘Magento 101’? Helpful post like this one can be moved to the 101 forum as well as many other obvious/useful/helpful thing people tend to oversight.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Bill007
Sr. Member
 
Avatar
Total Posts:  179
Joined:  2008-01-15
New Zealand
 

Search Bar Position Change

I noticed people where wanting to change the search bar position here is how I did it

I move the search bar from the top of the header to above the left column navigation and resting in the top navigation its just an illusion

http://www.greenstone.maori.nz for an example

Find the code in app/design/frontend/your_interface/your_new_theme/layout/catalogsearch.xml
find the <reference name="header"> this is where we can change the position we do how ever need it to stay in the header as it will then show on every page

<default>
       
        <
reference name="header">
            <
block type="core/template" name="top.search" as="topSearch" template="catalogsearch/form.mini.phtml"/>
        </
reference>
    </default>

Ok a little css change to reposition the final resting place of the search bar and size
and to also move along your navigation Bar to accommodate the new search bar

Firstly find boxes.css in skin/frontend/your_interface/your_new_theme/css/boxes.css

/* Mini search */
.mini-search {
    position
:absolute;
    
top:0;
    
right:0;
    
width:300px;
    
height:30px;
    
padding:1px 20px 0 40px;
    
background:url(../images/mini_search_bg.gifno-repeat;
    
zoom:1;
    
}
.mini-search .input-text { width:212pxmargin-right:4px}

And change it to this

/* Mini search */
.mini-search {
    position
:absolute;
    
top:89px;
    
left:-15px;
    
width:225px;
    
height:30px;
    
padding:1px 20px 0 40px;
    
/*background:url(../images/mini_search_bg.gif) no-repeat;
    zoom:1;*/
    
}
.mini-search .input-text { width:132pxmargin-right:6px}

then we need to find the navigation go to skin/frontend/your_interface/your_new_theme/css/menu.css and find this

#nav { padding:0 20px; font-size:1.1em; z-index:999; }

and Change it to this

#nav { padding:0 250px; font-size:1.1em; z-index:999; }

Hope that helps wink

Bill007 http://www.euphorish.com web design

 
Magento Community Magento Community
Magento Community
Magento Community
 
Andrea, Argentina
Sr. Member
 
Total Posts:  164
Joined:  2007-12-05
Buenos Aires, Argentina
 

I wanted to change my mini-search from header to navigation bar but It did not work… The unique page you touch the code is app/design/frontend/your_interface/your_new_theme/layout/catalogsearch.xml?
Because, it seems to me that there should be another change to do at the navigation page, but don’t know which :(

Are you using the 7 version, aren’t you?

Thanks
Andrea

 
Magento Community Magento Community
Magento Community
Magento Community
 
Bill007
Sr. Member
 
Avatar
Total Posts:  179
Joined:  2008-01-15
New Zealand
 

and yes I am using the latest Version

Did you not see http://www.greenstone.maori.nz and the search bar positioning

Is this not what you are saying

It sound s like you need to disable your cache refer top of thread

Most of the positioning is thru CSS

Bill007

 
Magento Community Magento Community
Magento Community
Magento Community
 
Andrea, Argentina
Sr. Member
 
Total Posts:  164
Joined:  2007-12-05
Buenos Aires, Argentina
 

Bill007, i have followed all your steps, but it didn’t work. Now I am going to do it again. It is not a cache problem. And the other strange thing es that when I run on the “hints” I can view the search form at the correct place, but when disable the hints it disappears. It says something to you?

THanks
Andrea

PD: Sorry if I don’t write pretty well, I am from Argentina, only speak a bit of english smile

 
Magento Community Magento Community
Magento Community
Magento Community
 
Bill007
Sr. Member
 
Avatar
Total Posts:  179
Joined:  2008-01-15
New Zealand
 

Changing your CSS files on the fly

Mozilla does a great CSS Developer plug in that allows you to change the CSS on the Fly
I reccommend that you get it and start using you will learn CSS fast that way

https://addons.mozilla.org/en-US/firefox/addon/60 great CSS Developer plug

http://www.mozilla.com/en-US/ Mozilla Download if you dont have it

My CSS is all self taught so some of the theory anit there But I still have been using CSS for 6 years
and it is awesome change one small bit of code for a site wide change

http://www.euphorish.com/2007/07/02/html-css-article-overview-lay-out/ there is a great CSS book here called
THE CSS ANTHOLOGY 101 Essential Tips Tricks and Hacks

How to use Web Developer CSS

open your Mozilla Browser (forget winddoze browsers) locate

TOOLS>>Web Developer>>css>>edit css

Now at the bottom of the browser you should see a CSS panel

This will list all the CSS files called into that particular page of you store

select which files contents you need to change IE boxes.css menu.css etc

cut all the css out of boxes.css and watch what happens the page in the browser will render with no Style

refresh the browser and it all comes back

Bill007 http://www.euphorish.com Web and Design development

 
Magento Community Magento Community
Magento Community
Magento Community
 
JazzcatCB
Jr. Member
 
Total Posts:  24
Joined:  2008-02-06
 

Template Path Hints
If you’re having trouble locating templates and you want the path to templates to appear on each store page, you can turn on template path hints at Admin -> Configuration -> [select your store] -> Developer tab -> [enable Template Path Hints] (courtesy of ohminu)

 
Magento Community Magento Community
Magento Community
Magento Community
 
yman
Jr. Member
 
Total Posts:  2
Joined:  2008-02-16
 

Thanks a bunch Bill007 for this thread initiative!
And thanks JazzcatCB for pointing out where to enable the Template Path Hints! This makes getting to the content blocks so much easier.

Great stuff

yman

 
Magento Community Magento Community
Magento Community
Magento Community
 
Bill007
Sr. Member
 
Avatar
Total Posts:  179
Joined:  2008-01-15
New Zealand
 

FAST WAY TO INSTALL MAGENTO

I reckon that Magento is doing great

Magento is easy to install trouble free just read on

Forget about FTP ng 9000 files that is just begging for issues

Download the magento-latest-ver Tar.gz download to your desk top

Upload the magento-latest-ver Tar.gz download into your webservers webroot folder via FTP

Down load Putty http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html just download the first link putty.exe you come accross

Learn how to connect into your server thru it so easy if you already know your log in details

Learn how to navigate to it the root web folder my one is [~]# cd public_html enter

Learn how to Unzip a tar.gz file thru PUTTY SSH program easy to learn [~]# tar -xxzvf magento-0.8.16100.tar.gz enter

there you have it the directory structure will stay intact and the process is all over in 30 second it is Beautiful to watch dos in action

And I think this way as well PEAR is installed properly GIVING ACCESS to the upgrade facility magento is working on also very nice feature

Go to Browser type in url where the store is eg http://www.greenstone.maori.nz yours will be http://www.yoururl.com/magento

set the Magento config page up answer all questions Easy CHMOD EVERYTHING IT ASKES which is about 4-5 folders EG
[~]# chmod 777 app/etc do it thru PUTTY

If you need to get the files to reside in the webroot just shift them server side eg instead of public_html/magento which is what will happen after untaring the file move the directory out of the magento folder and into the public_html folder

Its all over in no time faster then the below scenario

I waited 12 hours to FTP this magento folder across !@!@##%^&$@!$^ and some files did not go they where skipped due to cancelled connections file up load limits yes you will have a file limit in place turned out mine was set to 2000 files and then it stopped massive headache also some folders where put but with no info in them so just a empty file with a name more headaches and so much time

Good luck Bill007 http://www.euphorish.com web Design and Development

I guarantee you will have no problems with new installations

 
Magento Community Magento Community
Magento Community
Magento Community
 
Bill007
Sr. Member
 
Avatar
Total Posts:  179
Joined:  2008-01-15
New Zealand
 

HOW TO TURN ON THE RATING SYSTEM

Go Backend http://www.yourdomain.com/index.php/admin

Go to Catalog >>Reviews and Ratings>>Manage ratings ---- [click on each Rating name to edit it and turn it on} eg Price Quality Value

Now you must confirm the store you want the rating to show in so English is mine so I must click on it select it will turn blue then go to Save rating do this for all the Values

Now go make a comment about one of your products and the rating module should appear after you have rated your self you will have to go Back and

Go to Catalog >>Reviews and Ratings>>Customer Reviews>>Pending Reviews ---- the rest should be obvious there is no code or anything like that to change

 
Magento Community Magento Community
Magento Community
Magento Community
 
coolfinn
Jr. Member
 
Total Posts:  11
Joined:  2007-10-29
 

hi - i have to say that this is a brillian section. the tips i got from here did indeed save me hours. especially the mozilla browser & plug in - edit CSS in real time saved me hours with dreamweaver. i am changing over from joomla to magento and cannot wait for the production version. i am not techie web developer by any stretch.

one thing that i wished i known earlier - CSS!

thanks again

my site is at http://www.finncool.co.uk/magento for any interested.

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
    Back to top
Page 1 of 3