Support Forums

New layout.tpl

This is a discussion on New layout.tpl within the Modules / Plugins / Modifications forums, part of the Developer Forums category; Hi, I would like to have 2 logins layout for the menu. One for guest=layout.tpl and one for login=layout_connect.tpl I ...


Go Back   68 Classifieds Forums > Developer Forums > Modules / Plugins / Modifications

Reply
 
Thread Tools Display Modes
Old 08-11-2008, 05:54 PM   #1
Senior Member
 
hel68c's Avatar
 
Join Date: Jun 2008
Location: Canada, Quebec
Posts: 284
Rep Power: 15
hel68c is just really nice hel68c is just really nice
Default New layout.tpl

Hi,

I would like to have 2 logins layout for the menu.

One for guest=layout.tpl and one for login=layout_connect.tpl

I looked at login.php and add this at the last line
Quote:
if(isset($_POST['goto']) && $_POST['goto']<>"")
{
$class_tpl->display('layout.tpl');
}
else
{
$class_tpl->display('layout_connect.tpl');
}
I can see layout_connect for about 3 sec and then I'm forward with the forward.tpl. to the layout.tpl

Anybody have an idea where is my error?
__________________
Serge
HobbyClassified.com
V4.08 Developper, Module installed (CIV Scam Filter, Maffo Location System, Maffo News,Youtube, Seller Store)
hel68c is offline   Reply With Quote
Old 08-11-2008, 05:59 PM   #2
68 Classifieds Staff
 
Eric Barnes's Avatar
 
Join Date: Mar 2006
Location: Belmont, NC
Posts: 5,315
Rep Power: 125
Eric Barnes is a jewel in the rough
Default

What file do you have this in?
__________________
Eric Barnes
68 Classifieds Developer
Customer Area | Issue Tracker | Documentation | 68C Mods | 68 @ Twitter | My Modules
Eric Barnes is offline   Reply With Quote
Old 08-11-2008, 06:05 PM   #3
Senior Member
 
hel68c's Avatar
 
Join Date: Jun 2008
Location: Canada, Quebec
Posts: 284
Rep Power: 15
hel68c is just really nice hel68c is just really nice
Default

Not sure about your question.
__________________
Serge
HobbyClassified.com
V4.08 Developper, Module installed (CIV Scam Filter, Maffo Location System, Maffo News,Youtube, Seller Store)
hel68c is offline   Reply With Quote
Old 08-11-2008, 06:14 PM   #4
68 Classifieds Staff
 
Eric Barnes's Avatar
 
Join Date: Mar 2006
Location: Belmont, NC
Posts: 5,315
Rep Power: 125
Eric Barnes is a jewel in the rough
Default

Sorry disregard. I see you said login.php

At any rate that wouldn't work. Can you describe what your end goal is and maybe I can give you another option.
__________________
Eric Barnes
68 Classifieds Developer
Customer Area | Issue Tracker | Documentation | 68C Mods | 68 @ Twitter | My Modules
Eric Barnes is offline   Reply With Quote
Old 08-11-2008, 06:29 PM   #5
Senior Member
 
hel68c's Avatar
 
Join Date: Jun 2008
Location: Canada, Quebec
Posts: 284
Rep Power: 15
hel68c is just really nice hel68c is just really nice
Default

I have 2 tops menu one for guest and a one for login user.

If the user is not login I would like to display Menu-A

If is login I would like to display Menu-B.
__________________
Serge
HobbyClassified.com
V4.08 Developper, Module installed (CIV Scam Filter, Maffo Location System, Maffo News,Youtube, Seller Store)
hel68c is offline   Reply With Quote
Old 08-11-2008, 06:43 PM   #6
68 Classifieds Staff
 
Eric Barnes's Avatar
 
Join Date: Mar 2006
Location: Belmont, NC
Posts: 5,315
Rep Power: 125
Eric Barnes is a jewel in the rough
Default

In that case you could just edit the layout file:
Code:
{if $smarty.session.username<>''}
add include template for logged in users
{else}
add include for not logged in.
{/if}
__________________
Eric Barnes
68 Classifieds Developer
Customer Area | Issue Tracker | Documentation | 68C Mods | 68 @ Twitter | My Modules
Eric Barnes is offline   Reply With Quote
Old 08-11-2008, 06:44 PM   #7
68 Classifieds Staff
 
Eric Barnes's Avatar
 
Join Date: Mar 2006
Location: Belmont, NC
Posts: 5,315
Rep Power: 125
Eric Barnes is a jewel in the rough
Default

Here is an example of a template include:
{include file=viewlisting/listingextras.tpl}
__________________
Eric Barnes
68 Classifieds Developer
Customer Area | Issue Tracker | Documentation | 68C Mods | 68 @ Twitter | My Modules
Eric Barnes is offline   Reply With Quote
Old 08-11-2008, 07:46 PM   #8
Senior Member
 
hel68c's Avatar
 
Join Date: Jun 2008
Location: Canada, Quebec
Posts: 284
Rep Power: 15
hel68c is just really nice hel68c is just really nice
Default

Thank you Eric for the hint I'm gonna tuned it for myself.
__________________
Serge
HobbyClassified.com
V4.08 Developper, Module installed (CIV Scam Filter, Maffo Location System, Maffo News,Youtube, Seller Store)
hel68c is offline   Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Modifying the default template in v4. Mike-N-Tosh Templates, HTML, CSS, and Design Help 42 02-05-2009 05:29 PM
SORRY.. can be deleted... Fatih67 Technical Support 0 06-22-2008 03:31 PM
Error with Layout.tpl outlook Technical Support 6 05-15-2008 05:02 PM
Question about Padding in layout.tpl or style.css sleepy Templates, HTML, CSS, and Design Help 3 04-15-2006 09:17 AM


All times are GMT -4. The time now is 04:11 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0