MemHT Portal is a Free PHP CMS and Blog
It permit the creation and the management online of websites with few and easy steps.
It's completely customizable, expandable and suitable for all needs.
A2Hosting
Moderators: Moderators
Forum RSS feedReply
Small change to myblog template - link to comment
AuthorText
eholten
Junior Member

Posts: 24
Contributes: 26

Gender: _NEUTRAL_
Online: No
Date: 06/04/2010 16:43
Small change to myblog template - link to comment
#post23881
MemHT version: 4.0.1

I'm looking for the code to link to the comments in the myblog template.

The actual code for the latest comment in the template is
code
<?php
                                        $result = $dblink->get_list("SELECT name,text FROM memht_comments WHERE moderate=0 ORDER BY id DESC LIMIT 5");
                                        foreach ($result as $row) {
                                                $name = outCode($row['name']);
                                                $text = outCode($row['text']);
                                                                                               
                                                echo "<div style='padding:2px 0;'><img src='templates/".$siteConfig['template']."/images/page_white.gif' border='0' alt='Bullet'> <span style='vertical-align: top;'>$name: <i>".trimString($text,25,1)."</i></a></span></div>\n";
                                        }

                                        ?>


I can't see that the comments table have a link, just the id. This is something I started on though.

code
<?php
                                        $result = $dblink->get_list("SELECT name,text,id FROM memht_comments WHERE moderate=0 ORDER BY id DESC LIMIT 5");
                                        foreach ($result as $row) {
                                                $name = outCode($row['name']);
                                                $text = outCode($row['text']);
                                                $linkid = outCode($row['id']);
                                                                                               
                                                echo "<div style='padding:2px 0;'><img src='templates/".$siteConfig['template']."/images/page_white.gif' border='0' alt='Bullet'> <span style='vertical-align: top;'>$name: <i>".trimString($text,25,1)."</i></a></span></div>\n";
                                        }
                                        ?>

What I want is just to add the link to the comment if possible.
Delete Edit Quote
 
Reply
Tags Cloud
Twitter updates...
Help MemHT Portal
Navigator
Users Block
Hi Guest
IP: 38.107.179.232

Username
Password
MemHT Wiki
Language
MemHT Portal is a free software released under the GNU/GPL License by Miltenovik Manojlo