SimplePortal
Customization => Custom Coding => Topic started by: Aw06 on April 02, 2010, 10:55:56 PM
-
Just updated, all articles seem to be showing the read more link ....
-
Yes! With 2.3.2 SP added the [cutoff] tag! :)
-
Yes! With 2.3.2 SP added the [cutoff] tag! :)
Yeah, but it's cutting off every article, even ones lesser than the cut off amount ?? need to fix
-
You mean the three dots? I don't think having that even when the full content is displayed is an issue. But if it is for you, I could provide the edits to change it for you.
-
You mean the three dots? I don't think having that even when the full content is displayed is an issue. But if it is for you, I could provide the edits to change it for you.
yeah, would love not to show it .. tell me how thanks 8)
-
Sources/PortalArticles.php
if (($cutoff = $smcFunc['strpos']($row['body'], '')) !== false)
$row['body'] = $smcFunc['substr']($row['body'], 0, $cutoff);
elseif (!empty($modSettings['articlelength']) && $smcFunc['strlen']($row['body']) > $modSettings['articlelength'])
$row['body'] = $smcFunc['substr']($row['body'], 0, $modSettings['articlelength']);
$row['body'] = parse_bbc($row['body'], $row['smileys_enabled'], $row['id_message']) . '<a href="' . $scripturl . '?topic=' . $row['id_topic'] . '.0" title="' . $row['subject'] . '">...</a>';
if (($cutoff = $smcFunc['strpos']($row['body'], '')) !== false)
{
$row['body'] = $smcFunc['substr']($row['body'], 0, $cutoff);
$cutoff = true;
}
elseif (!empty($modSettings['articlelength']) && $smcFunc['strlen']($row['body']) > $modSettings['articlelength'])
{
$row['body'] = $smcFunc['substr']($row['body'], 0, $modSettings['articlelength']);
$cutoff = true;
}
$row['body'] = parse_bbc($row['body'], $row['smileys_enabled'], $row['id_message']) . (!empty($cutoff) ? '<a href="' . $scripturl . '?topic=' . $row['id_topic'] . '.0" title="' . $row['subject'] . '">...</a>' : '');
-
Thanks ... edits made :nervous-happy:
-
Hey sinan, this is what sent me in loop with the errors...
You Had Find
if (($cutoff = $smcFunc['strpos']($row['body'], '')) !== false)
But it's actually
[nobbc]if (($cutoff = $smcFunc['strpos']($row['body'], '[cutoff]')) !== false)[/nobbc]
So because the bbc hid the cutoff tag i pasted that into the file.
-
Right. Glad that you could find it. ;)