Thread Like Summary
Gizmo, temp
Total Likes: 2
Original Post (Thread Starter)
#323378 11/01/2019 2:07 PM
by DCPhil
DCPhil
When a user logs in, how can I take them straight to the Active Threads page, or straight to a particular Forum?
Liked Replies
#323383 Nov 4th a 01:32 PM
by DCPhil
DCPhil
Thank you Gizmo for pointing me in the right direction. I'll play around a little and see what I can come up with.
1 member likes this
#323379 Nov 3rd a 01:22 AM
by Gizmo
Gizmo
The login routine hands off the start page via the function "start_page" in the libs/html.inc.php file. This is completely untested, but I believe you'll want to adjust:
Code
		if ($start_view == "lists") {
			$main = "myhome&type=lists";
		} else {
			$main = "cfrm";
		}

The only "start view" options currently in UBB.threads is the forum summary (cfrm/Traditional Forum View) or "Follow Lists" (lists); these can be selected via "Edit Preferences", whereby their value is processed in the start_page function above.

I believe you could just build an additional elseif to inject additional pages into the start_page function, such as:
Code
		if ($start_view == "lists") {
			$main = "myhome&type=lists";
		} elseif ($start_view == "faq") {
			$main = "faq";
		} else {
			$main = "cfrm";
		}

And you'd also have to edit the display preferences template (templates/default/editdisplay.tpl) and language file (languages/english/editdisplay.php) to add any additional pages.
Code
{* Starting View: Watchlist or Forums *}
<label for="start_view">{$lang.DEFAULT_START}</label>
<br>
<select name="start_view" class="form-select" id="start_view">
<option value="lists" {$list_selected}>{$lang.FAV_LIST}</option>
<option value="cfrm" {$cfrm_selected}>{$lang.FAV_CFRM}</option>
</select>
<br><br>

It'll take some playing around (you'll need to add additional selected lines in the editdisplay script to handle logic that doesn't currently exist, as an example) but its entirely possible with time and testing.

We've discussed adding to this feature in future builds of UBB.threads, but currently don't have any concrete timeframes at hand.
1 member likes this
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
JAISP
JAISP
PA
Posts: 449
Joined: February 2008
Forum Statistics
Forums63
Topics37,573
Posts293,925
Members13,849
Most Online5,166
Sep 15th, 2019
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,833
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2024 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20221218)