Index.template.php question

Started by PopLife, May 17, 2005, 05:00:52 AM

Previous topic - Next topic

PopLife

This is really a more PHP related question.



templateMenu()



How can I center this without bringing up a parse error?

Jerry

you could try...
echo '<div align="center">';
templateMenu();
echo '</div>';


- Jerry
Find me on:
Facebook
Twitter
PlanetSMF

"If all you look for is the negative in things, you will never see the positive."

PopLife

Fatal error: Call to undefined function: templatemenu() in /usr/export/www/hosting/luba/Sources/Load.php(1040) : eval()'d code on line 98

my mistake, it is "template_menu()"

I just tried that and the above error message is what I had returned


PopLife


xenovanis

Well, if it is template_menu() how comes your errormessage returnes a templatemenu()?

Bumping after an hour?  :-\
"Insanity: doing the same thing over and over again and expecting different results."

nokonium




Jerry

yes, just replace the templateMenu() with the correct template_menu() ;) I was sleepy when I did that, sorry I didn't catch it :)


- Jerry
Find me on:
Facebook
Twitter
PlanetSMF

"If all you look for is the negative in things, you will never see the positive."

PopLife

*sigh* I am still looking for an answer to my original question. I am not completly retarded, I know how to change back to template_menu(). All I wanted to know is how I can center the forum menu without receiving a parse error. Thankyou for trying to help anyway guys  ;D

Jerry

well as far as I can see the code I gave you shouldn't be giving you a parse error ;). What code do you have there now? if you change it back to template_menu(); it should work. . .


- Jerry
Find me on:
Facebook
Twitter
PlanetSMF

"If all you look for is the negative in things, you will never see the positive."

PopLife

Ok, right now, the menu is working just fine, I have the right name there, OK? But, i want it centered. I tried your code and it didn't seem to be working. I just put a- border: 1px solid navy;
in the style.css file, and now the style.css won't come up in admin when I get into the template menu (the page comes up, but the menu has been widened to full screen and the typing field has disappeared). Now what can I do???

forsakenlad

Roll back all your changes and replace the menu code with this:

echo '
<table border="0" cellspacing="0" cellpadding="0" align="center" valign="middle" height="35">
<tr>
<td>', template_menu(), '</td>
</tr>
</table>';
Eren "forsakenlad" Yaşarkurt
SMF Friend & Former Team Member

PopLife

I don't want to lose all of my changes. I have already done quite a bit.

bloc

Are this done on a copy of the default theme..or on another custom theme?

It would be great if you could just post the code you have a bit before and after the place where template_menu is called, too see how you current setup looks like.

Most times, in order to center things you need a "container" in form of a 100% "table" or "div" with "align=center", and then put your desired element inside another "div" or "table". Only this time aligning it left/right. This is to prevent the second "div" from inheriting the alignment, making everything centered inside that one too.

Advertisement: