Info
- 17 posts
- 4 voices
- Started 2 years ago by Ashfame
- Latest reply from Ashfame
- This topic is resolved
Need to fix a couple of things in theme
-
- Posted 2 years ago #
Hello!
I am working on a bbPress theme which can be seen at http://bbpress.ashfame.com/
I have a problem that when I click the "Add new" link on the front page, the page is broken in markup (also returns invalid markup - http://bbpress.ashfame.com/?new=1 )
Which template file does it use to generate?
And the login code doesn't spit out the code in the sidebar when on register page ( http://bbpress.ashfame.com/register.php ) or on lost password page ( http://bbpress.ashfame.com/bb-login.php ) -
- Posted 2 years ago #
The new post template is stored under
post-form.php.register.phpandbb-login.phpare seperate pages that only includeheader.phpandfooter.php, so you'd need to include the sidebar either manually or in the header or footer respectively. Hope that helps! -
- Posted 2 years ago #
I fixed the second & third issue but I am still stuck at the first one.
Looking at the markup I found<select name="forum_id" id="forum-id"">is being generated by bbPress codebut the same works in default theme flawlessly so this isn't the cause. Can I have the complete lookup order for file required to generate the "Add new" page. -
- Posted 2 years ago #
Hmm... as far as I can work out, (at least with pretty links on) a forum link redirects to
forum.phpwhich invokespost_form()towards the end of the page. That's found infunctions.bb-template.php(underbb-includes) and as well as running the respective pre/during/post actions, it loads thepost-form.phptemplate from the theme's directory.Could you post your theme's
post-form.phphere? -
- Posted 2 years ago #
<?php bb_new_topic_link(); ?>the code to add new.The first one I know is in front-page.php
you have
<?php if ( $forums ) : ?>
then the Latest Discussion
then Forum
<?php endif; // bb_forums() ?>
Then Views
and the part you're missing
<?php else : // $forums ?> <div class="bbcrumb"><a href="<?php bb_uri(); ?>"><?php bb_option('name'); ?></a> » <?php _e('Add New Topic'); ?></div> <?php post_form(); endif; // $forums ?> -
- Posted 2 years ago #
@kawauso
Mine post-form.php is exactly the same as that of Kakumei.
I can trace the problem to an unclosed anchor tag<a>which is inbbcrumbDIV.
http://validator.w3.org/check?uri=http%3A%2F%2Fbbpress.ashfame.com%2F%3Fnew%3D1&charset=(detect+automatically)&doctype=Inline&group=1&ss=1#line-86
Where does this code comes from? I mean which file?Username:demo
Password:demo@gerikg
I don't get any of what you are trying to tel me. Probably you misunderstood my question. -
- Posted 2 years ago #
Maybe you can hardcode the URL like this http://domain/forum.php?id=9#postform
-
- Posted 2 years ago #
ashfame,
Is this what you're trying to generate? http://bbpress.org/forums/?new=1
Then continue reading.
The template file is front-page.php that does the "new?=1"
look at line 84-88
http://trac.bbpress.org/browser/trunk/bb-templates/kakumei/front-page.php -
- Posted 2 years ago #
@gerikg he's trying to fix an additional
<a>with no closing tag in the new post form, not generate a link to it :) -
- Posted 2 years ago #
@ashfame have a look at the bottom of
front-page.php, it should read<div class="bbcrumb"><a href="<?php bb_uri(); ?>"><?php bb_option('name'); ?></a> » <?php _e('Add New Topic'); ?></div>. Your code seems to have somehow dropped everything between the last two PHP snippets and the trailing</div>too. That's not being returned by the breadcrumb function though at least, so it should be easier to fix :) if it doesn't work with your template's front-page.php deleted/renamed though, there might be something wrong with your core files. -
- Posted 2 years ago #
Kawauso, you just said the same thing I did.
If hes trying to generate this page (go to the link and look) http://bbpress.org/forums/?new=1
then he's missing the bottom half of the front-page.php
that is why I said look at :
look at line 84-88
http://trac.bbpress.org/browser/trunk/bb-templates/kakumei/front-page.phpthe same line you just brought up.
-
- Posted 2 years ago #
Sorry about that! :)
-
- Posted 2 years ago #
Replacing a line from Kakumei did the job. may be I accidentally removed that closing div tag. anyways. thanks for your help so far.
Also I want to fix an IE thing.
The sizes of input type text of login are not equal in IE even though I have defined their size="20" -
- Posted 2 years ago #
Any idea about the IE issue? http://bbpress.org/forums/topic/need-to-fix-a-couple-of-things-in-theme#post-57347
-
- Posted 2 years ago #
It's IE, I'm not suprised. Try setting the width using CSS rather than the size attribute.
form.login input { width: 100px; }in the stylesheet -
- Posted 2 years ago #
Using CSS, I managed to do it with little weirdness. God, kill IE asap ;)
Thanks buddy! -
You must log in to post.