UBB.Dev
Posted By: rajin90 required help of you all - 01/16/2014 1:44 AM
new member and new to UBB : purchased 7.5.5

i am looking for [[linkremoved]] like portal
i checked and found i need to create some CUSTOM ISLAND
few are available in Portal layout.

i created ISLAND and it not shows HEADER[main forum]
and it shows the content of thread too.
i know not much is done with ISLAND in JU but i liked the way they show with clear date and threads/posts of each forum without showcasing the content.

so how do i do that?
also can anyone provide code for LOGIN FORM?
Posted By: Gizmo Re: required help of you all - 01/16/2014 3:20 AM
I'm confused at what you're trying to accomplish, the site you linked to is a web portal that's just there as a placeholder page and has no resemblance to a UBB portal page.

If you want to make the portal itself a generic webpage it's pretty simple, just edit portal.tpl to reflect whatever design you're interested in having displayed.
Posted By: rajin90 Re: required help of you all - 01/16/2014 12:56 PM
admin i know its a placeholder and only show various threads of forums. but web-portal also using custom islands

also the main coloum containing all threads links whereas when itry to do main coloumn also show content in the thread
i tried to do it.

http://getreallolchat.com/ubb/

so i have to edit portal.tpl and can you help me with code/php ADMIN?

Posted By: Gizmo Re: required help of you all - 01/16/2014 2:05 PM
Well, it'd be a task of making PHP/HTML and just plugging it in; it'd be a lot of work to customize it... Easiest thing to look at would be the "External Code" on custom islands to which you could place into the portal file.
Posted By: rajin90 Re: required help of you all - 01/16/2014 6:13 PM
this is signed-up here admin.
any solution available here any similar code provided by anyone here?
Posted By: Gizmo Re: required help of you all - 01/16/2014 8:56 PM
Well, the system uses the Smarty Templating engine, so you'll need to escape coding accordingly; so when adding say the "Who's Online" box to the page one would enter (Taken from the "External Use" link on the Portal Layout screen):
Code
{php}
if (!defined('UBB_MAIN_PROGRAM')) define('UBB_MAIN_PROGRAM',1);
$style_side="";$tbopen="";$tbclose="";
echo "<table width=\"100%\">";
include("/home/user/public_html/forums/languages/english/portal_islands.php");
include("/home/user/public_html/forums/languages/english/generic.php");
include("/home/user/public_html/forums/cache/online_now.php");
echo "</table>";
{/php}

If you wanted to use a 2 cell table it'd be basic HTML:
Code
<table width=\"100%\">
<tr>
<td>Table Cell Alpha</td>
<td>Table Cell Bravo</td>
</tr>
</table>

You'd literally just add the coding into portal.tpl where you wanted it to display; for clients in the past I've completely removed the existing portal coding (since all it really does is display latest posts from forums you select) and added in tables and external use boxes in them where they'd be displayed (custom portal boxes make great little content areas).
Posted By: rajin90 Re: required help of you all - 01/16/2014 11:24 PM
thank you admin . now i understand how it works.
i can see i have to code a lot
Posted By: rajin90 Re: required help of you all - 01/16/2014 11:55 PM
How to show login form in portal?

so user can login and sign out from there
Posted By: Gizmo Re: required help of you all - 01/17/2014 12:41 AM
There isn't a login island that I'm aware of, you'd either have to create one or just include a link to the login page.
Posted By: rajin90 Re: required help of you all - 01/17/2014 1:25 AM
admin only this part is left
JU

Show Reminders and Forums at left side both are manually made links? if not then can u help me with this code?

Important Dates : i am sure is manually updated
Posted By: rajin90 Re: required help of you all - 01/20/2014 3:19 PM
how to use this Upcoming events Custom Island code in 7.5.5?

Code
/* PHP CODE HERE, IF NECESSARY */

# Change the next parameter to the maximum future events you want
$maxEvents = 10;
# Change to whichever column this Custom Island will be shown (for CSS)
$portalCol = 'left';

# -- Nothing changes below, unless you are non-n00bers ;)
$intTime = time();
$dateParts = getdate($intTime);
$dtYr = $dateParts['year'];

$q = "
SELECT ce.CALENDAR_EVENT_SUBJECT, ce.TOPIC_ID, t.POST_ID,
ce.CALENDAR_EVENT_DAY, ce.CALENDAR_EVENT_MONTH,
ce.CALENDAR_EVENT_YEAR, ce.CALENDAR_EVENT_BODY
FROM {$config['TABLE_PREFIX']}CALENDAR_EVENTS ce, {$config['TABLE_PREFIX']}TOPICS t
WHERE ce.CALENDAR_EVENT_TYPE='public'
AND ce.CALENDAR_EVENT_RECURRING = 'never'
AND ce.CALENDAR_EVENT_YEAR >= $dtYr
AND ce.TOPIC_ID=t.TOPIC_ID
";
$r = $dbh->do_query($q);
$ceList = array();
while (list($ceSubject, $topicID, $postID, $ceDay, $ceMon, $ceYr) = $dbh->fetch_array($r)) {
$ceTime = mktime(0,0,0,$ceMon,$ceDay,$ceYr);
if ($ceTime >= $intTime) {
$ceList[$ceTime]['Subject'] = $ceSubject;
$ceList[$ceTime]['postID'] = $postID;
}
}

# Create the list
$i=0;
sort($ceList);
foreach ($ceList as $ce) {
$cssExt = ($i++&1) ? '2' : '1';
$cssClass = 'class="' . $portalCol . 'alt-' . $cssExt .'"';
if ($i == 1) {
$htmlList .= "<a href=\"{$config['FULL_URL']}/ubbthreads.php?ubb=showflat&Number={$ce['postID']}\">{$ce['Subject']}</a>";
} else {
$htmlList .= "</td></tr><tr><td $cssClass>";
$htmlList .= "<a href=\"{$config['FULL_URL']}/ubbthreads.php?ubb=showflat&Number={$ce['postID']}\">{$ce['Subject']}</a>";
}
}

/* DO NOT CHANGE THE LINE BELOW */
$body = <<<EOF

$htmlList

EOF;
/* DO NOT CHANGE THE LINE ABOVE */
Posted By: Gizmo Re: required help of you all - 01/21/2014 5:52 AM
Well, you'd add it as a custom island then you'd use the external use code as i mentioned above to put it into a page.
© UBB.Developers