What is the difference, i cannot figure out my typo

I am really bad with messing up singular or plural, when it comes to programming and lately i been wasting my time in figuring out what and where i did wrong and i really hate myself, but now a think has come up, where my code doesn’t work but if i copy it from tutorial i am following, it work and i cannot find the difference. Following is my code

    	<helloworld_index_index>
    	<block type="page/html" name="root" output="toHtml"
    		 template="magentotutorial/helloworld/simple_page.phtml" />
    		 	 <block type="customer/form_register" name="customer_form_register"
    		 	 template="customer/form/register.phtml" />
    	</block>
    	</helloworld_index_index>

and following is tutorial code

    	<helloworld_index_index>
        <block type="page/html" name="root" output="toHtml" template="magentotutorial/helloworld/simple_page.phtml">
            <block type="customer/form_register" name="customer_form_register" 
            	template="customer/form/register.phtml" />
        </block>
    </helloworld_index_index>

Now i cannot figure out what is wrong, maybe i am gone blind. Can anyone help, any advice in keeping typos away and making sure of singular and purals etc.

The only differences I can see are an added line break in your code:

<block type="page/html" name="root" output="toHtml"
    		 template="magentotutorial/helloworld/simple_page.phtml" />

and the absence of a closing / in the tutorial code at the same line.

<block type="page/html" name="root" output="toHtml" template="magentotutorial/helloworld/simple_page.phtml">

Both examples seem to have two opening <block> tags, but only one closing </block>.

Aha - one of them is self-closing in the second example? (I’ve no idea what I’m looking at; I’m just fairly adept at spotting typos. )

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.