Example #1
0
/**
 * Show the guestbook
 * This function is provided as compatibility for v9 guestbook widget
 * 
 * @param string  $id              The guestbook id
 * @param string  $filepath        The folder where the comments must be stored
 * @param string  $email           The email to notify the new comments
 * @param boolean $captcha         true to show the captcha
 * @param boolean $direct_approval true to directly approve comments
 * 
 * @return void
 */
function showGuestBook($id, $filepath, $email, $captcha = true, $direct_approval = true)
{
    global $imSettings;
    $gb = new ImTopic("gb" . $id);
    $gb->loadXML($filepath);
    $gb->showSummary(false);
    $gb->showForm(false, $captcha, !$direct_approval, $email, "guestbook", $imSettings['general']['url'] . "/admin/guestbook.php?id=" . $id);
    $gb->showComments(false);
}
Example #2
0
"<?php 
        echo $post == @$_GET['post'] ? " selected" : "";
        ?>
><?php 
        echo $imSettings['blog']['posts'][$post]['title'];
        ?>
</option>
<?php 
    }
    ?>
			</select>
<?php 
}
if (isset($_GET['category']) && isset($_GET['post'])) {
    $data = $imSettings['blog'];
    $topic = new ImTopic($data['file_prefix'] . 'pc' . $_GET['post'], "../");
    $topic->setPostUrl('blog.php?category=' . $_GET['category'] . '&post=' . $_GET['post']);
    switch ($data['sendmode']) {
        case "file":
            $topic->loadXML($data['folder']);
            break;
    }
    if (count($topic->comments->getAll())) {
        $topic->showSummary($data['comment_type'] != "comment", TRUE);
    }
    $topic->showAdminComments($data['comment_type'] != "comment", $data['comments_order']);
}
?>
		</div>
	</div>
</div>
Example #3
0
        echo $gbid == $id ? " selected" : "";
        ?>
><?php 
        echo $gb['pagetitle'] . " - " . (strlen($gb['celltitle']) ? $gb['celltitle'] : $gbid);
        ?>
</option>
<?php 
    }
    ?>
			</select>
<?php 
}
$gb = false;
if (strlen($id)) {
    $data = $imSettings['guestbooks'][$id];
    $gb = new ImTopic($id, "../");
    $gb->setPostUrl('guestbook.php?id=' . $id);
    switch ($data['sendmode']) {
        case "file":
            $gb->loadXML($data['folder']);
            break;
        case "db":
            $gb->loadDb($data['host'], $data['user'], $data['password'], $data['database'], $data['table']);
            break;
    }
    if ($gb->hasComments()) {
        $gb->showAdminSummary($data['rating'], TRUE);
    }
}
?>
		<div style="clear: both;"></div>
Example #4
0
/*
|-------------------------------------------------------------------------------------------
|	GUESTBOOK SETTINGS
|-------------------------------------------------------------------------------------------
*/
$imSettings['guestbooks'] = array('x5gb41' => array('id' => 'x5gb41', 'pagetitle' => 'Gastenboek', 'celltitle' => '', 'rating' => TRUE, 'order' => 'desc', 'sendmode' => 'file', 'folder' => '/home/kevin/public_html/kevinsplace/database//home/kevin/database'));
/*
|-------------------------------------------------------------------------------------------
|	Dynamic Objects SETTINGS
|-------------------------------------------------------------------------------------------
*/
$imSettings['dynamicobjects'] = array();
/*
|-------------------------------
|	EMAIL SETTINGS
|-------------------------------
*/
$ImMailer->emailType = 'phpmailer';
$ImMailer->exposeWsx5 = true;
$ImMailer->header = '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">' . "\n" . '<html>' . "\n" . '<head>' . "\n" . '<meta http-equiv="content-type" content="text/html; charset=utf-8">' . "\n" . '<meta name="generator" content="Incomedia WebSite X5 v12 - www.websitex5.com">' . "\n" . '</head>' . "\n" . '<body bgcolor="#708090" style="background-color: #708090;">' . "\n\t" . '<table border="0" cellpadding="0" align="center" cellspacing="0" style="padding: 0; margin: 0 auto; width: 700px;">' . "\n\t" . '<tr><td id="imEmailContent" style="min-height: 300px; padding: 10px; font: normal normal normal 9pt Tahoma; color: #000000; background-color: #FFFFFF; text-align: left; text-decoration: none;  width: 700px;border-style: solid; border-color: #808080; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 0; border-bottom: none; border-left-width: 1px;background-color: #FFFFFF" width="700px">' . "\n\t\t";
$ImMailer->footer = "\n\t" . '</td></tr>' . "\n\t" . '<tr><td id="imEmailFooter" style="font: normal normal normal 7pt Tahoma; color: #000000; background-color: transparent; text-align: center; text-decoration: none;  width: 700px;border-style: solid; border-color: #808080; border-top-width: 0; border-top: none; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; padding: 10px; background-color: #FFFFFF" width="700px">' . "\n\t\t" . 'Deze e-mail bevat informatie die enkel voor de hierboven genoemde geadresseerde bedoeld is. <br>Als u deze e-mail onbedoeld hebt ontvangen, licht de afzender hier dan a.u.b. onmiddellijk over in en verwijder de e-mail vervolgens zonder hem te kopiƫren.' . "\n\t" . '</td></tr>' . "\n\t" . '</table>' . "\n" . '</body>' . "\n" . '</html>';
$ImMailer->bodyBackground = '#FFFFFF';
$ImMailer->bodyBackgroundEven = '#FFFFFF';
$ImMailer->bodyBackgroundOdd = '#F0F0F0';
$ImMailer->bodyBackgroundBorder = '#CDCDCD';
$ImMailer->bodySeparatorBorderColor = '#000000';
$ImMailer->emailBackground = '#708090';
$ImMailer->emailContentStyle = 'font: normal normal normal 9pt Tahoma; color: #000000; background-color: #FFFFFF; text-align: left; text-decoration: none; ';
$ImMailer->emailContentFontFamily = 'font-family: Tahoma;';
ImTopic::$captcha_code = "\t\t<div class=\"x5captcha-wrap\">\n\t\t\t<label>Controlewoord:</label><br />\n\t\t\t<input type=\"text\" class=\"imCpt\" name=\"imCpt\" maxlength=\"5\" />\n\t\t</div>\n";
// End of file x5settings.php
Example #5
0
        ?>
</option>
<?php 
    }
    ?>
					</select>
				</div>
<?php 
}
?>

<?php 
$topic = false;
if (isset($_GET['category']) && isset($_GET['post'])) {
    $data = $imSettings['blog'];
    $topic = new ImTopic($data['file_prefix'] . 'pc' . $_GET['post'], "../");
    $topic->setPostUrl('blog.php?category=' . $_GET['category'] . '&post=' . $_GET['post']);
    switch ($data['sendmode']) {
        case "file":
            $topic->loadXML($data['folder']);
            break;
        case "db":
            $topic->loadDb($data['dbhost'], $data['dbuser'], $data['dbpassword'], $data['dbname'], $data['dbtable']);
            break;
    }
    if ($topic->hasComments()) {
        $topic->showAdminSummary($data['comment_type'] != "comment");
    }
}
?>
				<div style="clear: both;"></div>
Example #6
0
        echo $gb['pagetitle'] . " - " . (strlen($gb['celltitle']) ? $gb['celltitle'] : $gbid);
        ?>
</option>
<?php 
    }
    ?>
				</select>
<?php 
}
if ($id != "") {
    // Show the comments of a guestbook
    ?>
  			<div class="imBlogPostComment">
 <?php 
    $data = $imSettings['guestbooks'][$id];
    $gb = new ImTopic($id, "../");
    $gb->setPostUrl('guestbook.php?id=' . $id);
    switch ($data['sendmode']) {
        case "file":
            $gb->loadXML($data['folder']);
            break;
    }
    if (count($gb->comments->getAll())) {
        $gb->showSummary($data['rating'], TRUE);
    }
    $gb->showAdminComments($data['rating'], $data['order']);
}
?>
			</div>
		</div>
	</div>