Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
navigation at top and bottom of discussionpage
jackmaessen
✭✭✭
I was looking how i could place the "pager" with which you can navigate between pages if the discussion list is too long for 1 page, also get on top of the page (default is only at bottom).
I copied this line
<?php echo $this->Pager->ToString('more');?>
which is situated in applications/vanilla/views/discussion/index.php just below this line (also in index.php)
<?php $this->FireEvent('BeforeDiscussion'); ?>
so the part of the code in index.php now looks like this:
I hope this is useful for people who also want the pager as well on top as on the bottom.
You can see an example here at my site: http://www.webprofis.nl/index.php?p=/discussion/64/signature-mogelijk
Tagged:
6
Comments
Interesting. In my opinion, this is a poor way to implement it. I would implement this by adding this function to my theme hooks file:
That said, you could also add copy that view file to your custom theme and make any necessary changes there. Both of these approaches have the advantage of not getting wiped out when the core files are updated.
Search first
Check out the Documentation! We are always looking for new content and pull requests.
Click on insightful, awesome, and funny reactions to thank community volunteers for their valuable posts.
@jackmaessen your site looks weird in Safari, the content is bellow the panel , do you have adds ? that is the only thing I can figure coz I use add block. There is a huge blank space beside the panel.
❌ ✊ ♥. ¸. ••. ¸♥¸. ••. ¸♥ ✊ ❌
oke @ vrijvlinder; i just looked the site with safari but i could'nt see strange things. Can you show me a snapshot of it what you see when you use Safari? Because, i can't see strange things when i use Safari...
@ hgtonight: that's true what you say. If the core files are being updated, i have to put it back again. So i agree with you that your solution is much better. I will use it form now on. Thank you hgtonight.
BTW: @ vrijvlinder: your nickname looks like a Dutch name. Are you native dutch?
@jackmaessen here is a screenshot . I am on a mac are you ?
Niet van Nederlands, de naam is Nederlands dat ik omhoog maakte, het vrije vlinder
❌ ✊ ♥. ¸. ••. ¸♥¸. ••. ¸♥ ✊ ❌
here is the pic
❌ ✊ ♥. ¸. ••. ¸♥¸. ••. ¸♥ ✊ ❌
Thnaks vrijvlinder for the snapshot. This is really strange. I am using Windows OS but i also looked with Safari browser and everything looks normal. So why Mac with Safari is displaying this, i don't know. But it looks like as the right column is breaking out of the wrapper. So i will have a look at ot. Unfortunately i can not test it with mac OS but i am surprised that it is displayed not correctly on a mac...
here are a few possibilities
http://browsershots.org/
http://www.smashingmagazine.com/2011/08/07/a-dozen-cross-browser-testing-tools/
I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.
I think I know why, it is because the width is not static . If you open the browser window to the width of the screen the forum looks ok. But if you make the window smaller, the content gets pushed down, what should happen , is there should be a cutoff point where if you close it more it does not push it.
It looks like the theme was meant to be flexible, responsive, but somewhere a static width of pixels was added instead of a percentage.
If you look at this forum , when you make the window narrower, the left panel goes away, but if you continue to make it smaller , it adjusts to the size automatically. That is responsiveness to the width of the window for the sake of devices.
Your forum theme, I believe was intended to do the same thing. Did you edit the css ?
If you did you need to either make it all static widths, or all percentages for the head body content panel and foot.
❌ ✊ ♥. ¸. ••. ¸♥¸. ••. ¸♥ ✊ ❌
yes you were right vrijvlinder. A couple of days i did decrease the width of the left column. I gave it a static width of 320px. And ofcourse, it was not flexible anymore. But like i said, it looked good in every browser on windows but i did not test it on a mac, and yes for some reason, Safari on mac displayed it in a different way. But i am very thankful to you that you made attention to me on that. Thanks a lot.
http://www.webprofis.nl
@jackmaessen Yes that was one of the ones I noticed here is some that I made note of for you to try see if this helps, go though the code and find these parts and adjust the percentages as best you can. Let me know if this helped.
❌ ✊ ♥. ¸. ••. ¸♥¸. ••. ¸♥ ✊ ❌
@vrijvlinder; thanks for the css. I did almost the same like you are displaying above. I noticed: the container is width 1170 px. I set the left column (Panel span4) on 25%. That means that the right column can be set on 75% but there is a margin between them of 20px. So i calculated: 20 px of 1170 px = 1.7% So i have to decrease the 75% of the right column (.Content.span8) with at least 1.7%.
And for safety i set it on 70%. And i tested in the browser test peregrine gave me and it now looks good in Safari on Mac as well as in the other browsers
Awesome glad it worked !
❌ ✊ ♥. ¸. ••. ¸♥¸. ••. ¸♥ ✊ ❌