{"id":1066,"date":"2007-04-22T15:34:38","date_gmt":"2007-04-22T23:34:38","guid":{"rendered":"http:\/\/www.krunk4ever.com\/blog\/?p=1066"},"modified":"2007-10-08T18:22:13","modified_gmt":"2007-10-09T02:22:13","slug":"ajaxian-theme-misalignment","status":"publish","type":"post","link":"https:\/\/www.krunk4ever.com\/blog\/2007\/04\/22\/ajaxian-theme-misalignment\/","title":{"rendered":"Ajaxian Theme Misalignment"},"content":{"rendered":"<p>I had begin noticing some weird alignment issue with Gallery&#8217;s Ajaxian Theme. On page 2 onwards of any album, the bottom next and last button links would be shifted a bit lower than it&#8217;s desired location:<br \/>\n<a href=\"http:\/\/gallery.krunk4ever.com\/v\/misc\/ajaxian_page1.png.html\"><img decoding=\"async\" src=\"http:\/\/gallery.krunk4ever.com\/d\/12958-6\/ajaxian_page1.png\" alt=\"ajaxian theme - misalignment\" \/><\/a><a href=\"http:\/\/gallery.krunk4ever.com\/v\/misc\/ajaxian_page2.png.html\"><img decoding=\"async\" src=\"http:\/\/gallery.krunk4ever.com\/d\/12961-6\/ajaxian_page2.png\" alt=\"ajaxian theme - misalignment\" \/><\/a><\/p>\n<p>I started a thread on Gallery&#8217;s forum: <a href=\"http:\/\/gallery.menalto.com\/node\/63698\">ajaxian theme and mis-alignment of next\/last on page 2 onwards<\/a> and pointed out that the top links look okay, while the bottom didn&#8217;t. I also noted the fact that source wise, the top had them in reverse order, where it wrote out the next\/last links first, before writing out the first\/previous:<\/p>\n<p><strong>top<\/strong>:<br \/>\n<code>&lt;div class=\"next-and-last\"&gt;...&lt;\/div&gt;<br \/>\n&lt;div class=\"first-and-previous\"&gt;...&lt;\/div&gt;<\/code><\/p>\n<p><strong>bottom<\/strong>:<br \/>\n<code>&lt;div class=\"first-and-previous\"&gt;...&lt;\/div&gt;<br \/>\n&lt;div class=\"next-and-last\"&gt;...&lt;\/div&gt;<\/code><\/p>\n<p>I thought maybe if I can reverse the order of those statements, this might be fixed. I decided to see if I could figure this out. Looking at the style sheet (\/themes\/ajaxian\/theme.css), it appears this is how the blocks are defined:<\/p>\n<p><code>.next-and-last {<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;float: right;<br \/>\n}<br \/>\n.next-and-last.no-previous {<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;float: none;<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;text-align: right;<br \/>\n}<\/code><\/p>\n<p>I started playing with the .next-and-last style, but didn&#8217;t really get anywhere unless I manually set it to be shifted up x-pixels.<\/p>\n<p>I then found \/modules\/core\/templates\/blocks\/Navigator.tpl, which actually uses this class and it just appears to be something simple that returns first-and-previous or next-and-last block.<\/p>\n<p>Then I found \/themes\/ajaxian\/templates\/album.tpl, which actually calls the Navigator.<\/p>\n<p>On the top, it showed:<br \/>\n<code>{g->block type=\"core.Navigator\" navigator=$theme.navigator reverseOrder=true}<\/code><\/p>\n<p>but the bottom only shows:<br \/>\n<code>{g->block type=\"core.Navigator\" navigator=$theme.navigator}<\/code><\/p>\n<p>I added the <strong>reverseOrder=true<\/strong> to the bottom, and that fixed it.<\/p>\n<p>Enjoy!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I had begin noticing some weird alignment issue with Gallery&#8217;s Ajaxian Theme. On page 2 onwards of any album, the bottom next and last button links would be shifted a bit lower than it&#8217;s desired location: I started a thread on Gallery&#8217;s forum: ajaxian theme and mis-alignment of next\/last on page 2 onwards and pointed &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/www.krunk4ever.com\/blog\/2007\/04\/22\/ajaxian-theme-misalignment\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Ajaxian Theme Misalignment&#8221;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[11],"tags":[],"_links":{"self":[{"href":"https:\/\/www.krunk4ever.com\/blog\/wp-json\/wp\/v2\/posts\/1066"}],"collection":[{"href":"https:\/\/www.krunk4ever.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.krunk4ever.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.krunk4ever.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.krunk4ever.com\/blog\/wp-json\/wp\/v2\/comments?post=1066"}],"version-history":[{"count":0,"href":"https:\/\/www.krunk4ever.com\/blog\/wp-json\/wp\/v2\/posts\/1066\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.krunk4ever.com\/blog\/wp-json\/wp\/v2\/media?parent=1066"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.krunk4ever.com\/blog\/wp-json\/wp\/v2\/categories?post=1066"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.krunk4ever.com\/blog\/wp-json\/wp\/v2\/tags?post=1066"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}