|
| |||||||
| Mod Requests Have a suggestion for a mod? Post it here. You may not always receive an answer, but phpLD devs and mod developers do regularly visit this forum. If you MUST get something done, you may need to opt for paid help. |
![]() |
| | topic widgets |
| | #1 |
| Supporter Join Date: Oct 2005 Posts: 540 | hi, i would like to have the main categories in footer. but not on main page. anyone an idea ? (vers. 2.0) thanks. __________________ many thanks. thompson. |
| |
| | #2 |
| Join Date: Sep 2005 Posts: 677 | i think i can do this for you, do you want me to test itand then post the code, or do you want me to do it on your site for you? either way it is just as easy __________________ Please check your sig links |
| |
| | #3 |
| Supporter Join Date: Oct 2005 Posts: 540 | i wanna do it by myself. if you like, please post the code. __________________ many thanks. thompson. |
| |
| | #4 |
| Supporter Join Date: Oct 2005 Posts: 540 | *push* __________________ many thanks. thompson. |
| |
| | #5 |
| Supporter Moderator Join Date: Sep 2005 Location: Vancouver, BC, Canada Posts: 1,184 | You can try this: 1. Edit main.php by adding the following code towards the end just before the $tpl->assign('category', $path[count($path) - 1]); line: Code: Content visible to registered users only. Code: Content visible to registered users only. Code: Content visible to registered users only. __________________ Dan █ phpLD Mods :: phpLD_Vault █ Webmaster Resources Directory █ phpLD_Vault Support IMPORTANT NOTE: phpLD_Vault Support not handled in this forum AND not via PM here. Click on link above for support. NO exceptions! |
| |
| | #6 |
| Supporter Join Date: Oct 2005 Posts: 540 | i did the changes in index.php an then i get an error: Fatal error: Call to a member function on a non-object in /www/htdocs/w005f2ae/index.php on line 155 $row['TSUBCATS'] = $rs2->GetRows(); i this an error for an older version i had (RC 5.2) i think i have the version before Rev. 76 how can i update to version 2.0 ? (i modded a lot of files.) thanks for that work and thanks for helping me. __________________ many thanks. thompson. |
| |
| | #7 |
| Supporter Moderator Join Date: Sep 2005 Location: Vancouver, BC, Canada Posts: 1,184 | Can you send me your index.php file. __________________ Dan █ phpLD Mods :: phpLD_Vault █ Webmaster Resources Directory █ phpLD_Vault Support IMPORTANT NOTE: phpLD_Vault Support not handled in this forum AND not via PM here. Click on link above for support. NO exceptions! |
| |
| | #8 |
| Supporter Join Date: Oct 2005 Posts: 540 | you got pm. __________________ many thanks. thompson. |
| |
| | #9 |
| Supporter Join Date: Dec 2005 Posts: 484 | Hi, I've just attempted this mod to see how it would look. One problem I am having is that the categories display in a single column even though I have set for 3 coulmn display. I have tried it on an unaffected phpld install with no template edits and still the same. Any suggestions on why this could be? Perhaps it's missing the 'column display' code. I also took out the <center> tags just to check. Any thoughts appreciated. p.s. I have tried this in v2 but it also works in v303 which is my main install. Thanks |
| |
| | #10 |
| Supporter Moderator Join Date: Sep 2005 Location: Vancouver, BC, Canada Posts: 1,184 | I revised the footer.tpl code to match what was finally done - this was handled in large part via PM. __________________ Dan █ phpLD Mods :: phpLD_Vault █ Webmaster Resources Directory █ phpLD_Vault Support IMPORTANT NOTE: phpLD_Vault Support not handled in this forum AND not via PM here. Click on link above for support. NO exceptions! |
| |
| | #11 |
| Supporter Join Date: Dec 2005 Posts: 484 | I see the design has changed for practicality of post subject. Is there anyway to keep the previous footer code yet have it follow the column structure like on index.php? What I'm really trying to do is call the top categories to a totally new page I've created. thanks |
| |
| | #12 |
| Supporter Moderator Join Date: Sep 2005 Location: Vancouver, BC, Canada Posts: 1,184 | In the original code, try removing the <h3>/</h3> tags. __________________ Dan █ phpLD Mods :: phpLD_Vault █ Webmaster Resources Directory █ phpLD_Vault Support IMPORTANT NOTE: phpLD_Vault Support not handled in this forum AND not via PM here. Click on link above for support. NO exceptions! |
| |
| | #13 |
| Supporter Join Date: Dec 2005 Posts: 484 | Hi VSDan I managed to find resolution The 'Calculate the number of categories per row' was the missing culprit.I also had to follow your example and place 't' before 'categs'. This also had to be done for the 'categs' codes in the very last {if...} statement line. Code: Content visible to registered users only. ![]() For anyone finding this in future and for whatever purposes you wish to use this discussion for, the above code is taken from main.tpl. Cheers Net. |
| |
| | #14 |
| Join Date: Jan 2006 Posts: 404 | Hi did any one use this ..if yes then plz show me __________________ Please check your signature links. They appear to be broken. |
| |
| | #15 |
| Join Date: Oct 2005 Location: Polar Regions Posts: 252 | I am getting this same error. How was it finally corrected? I simply copied and pasted the code from VSDan's post, excepting the part where the forum automatically created the hyperlink. BTW, I am using the latest release of phpLD2. __________________ Free PHP Link Directory 3.xx templates - Why settle for screenshots and thumbnails when you can test drive them? My Mods 4 lifetime links on seperate IPs for $5 Last edited by David; 08-18-2009 at 06:37 PM. |
| |
| | #16 |
| Join Date: Aug 2006 Posts: 118 | Anyone get this code working for 3.06. Im not getting any errors, but rather than having all the categories listed in the footer. I just want the top level categories listed, from left to right. I have 18 top level cats in all. |
| |
| | #17 |
| Supporter Join Date: May 2006 Posts: 1,279 | No luck here on 3.06 Final, I get this error when implimenting to the footer.tpl Fatal error: Smarty error: [in footer.tpl line 39]: syntax error: mismatched tag {/if}. expected {/foreach} (opened line 38). (Smarty_Compiler.class.php, line 2289) in /home/fastline/public_html/libs/smarty/Smarty.class.php on line 1095 |
| |
| | #18 |
| Join Date: Sep 2005 Location: Pembroke Pines, FL Posts: 222 | If I understand correctly, you can do what I do. Create a file called footer2.tpl and assign it to any php file you do not want to show the normal categories for. Just replace the last line of those files with footer2.tpl instead of footer.tpl __________________ Michael Dippel http://hobbyline.com - http://regionaldirectory.biz/ (running Beta 3) - http://daviefla.biz - http://directorylist.info |
| |
| | #19 |
| Join Date: Aug 2006 Posts: 118 | Mmm what im really after is just the top level categories in the footer in all pages, APART from the frontpage (cause there already there)..so the code above just needs to be modified to only show top level cats, but im lost on coding. |
| |
| | #20 |
| Supporter Join Date: Feb 2006 Location: As far from you as humanly possible! Posts: 2,860 | Code: Content visible to registered users only. $rs = $db->Execute("SELECT * FROM `{$tables['category']['name']}` WHERE `STATUS` = 2 AND PARENT_ID = ".$db->qstr($id)." ORDER BY `TITLE`"); to this: $rs = $db->Execute("SELECT * FROM `{$tables['category']['name']}` WHERE `STATUS` = 2 AND PARENT_ID = 0 ORDER BY `TITLE`"); |
| |