Previous Thread
Next Thread
Print Thread
Rate Thread
#212867 11/07/2001 10:46 AM
Joined: Apr 2001
Posts: 27
Journeyman
Journeyman
Offline
Joined: Apr 2001
Posts: 27
I read a lot of templates here and that UBBThreads 6.0 is going to use them. In general I know what a template is. But what does this mean for this board concretely? Is there (simplified) a HTML File (Template) which is parsed and some parts are replaced by the content from the database? Then you are able to redesign the HTML-Template File and you have a completely different layout?

By the way: What do you think about the PHP-Code? Usually the PHP code (or similar the ASP-Code) I saw or wrote looked like this:

<!-- HTML Code -->
<?
// PHP Code
?>
<!-- HTML Code -->

and so on. The PHP code of UBBThread is very Perl like: Rick used print and/or echo to output HTML. The above version is maybe better if you first designed your page with a html editor and include some PHP later. The second if (as in Rick's case) you'll transfer Perl code or maybe if there's more (PHP-)Code then HTML-output.

It was just something what surprised me, when I first looked into the code. []https://www.ubbdev.com/threads/php/images/icons/wink.gif[/]

Sponsored Links
hPm #212868 11/07/2001 11:01 AM
Joined: May 1999
Posts: 3,039
Guru
Guru
Offline
Joined: May 1999
Posts: 3,039
I'll tackle your second question first. If you break into HTML mode in a php file then you have to break back into PHP mode to include a variable or something so a simple line would look like this:

<HTML><BODY bgcolor="<? echo "$config[bgcolor]"; ?>">

That get's kind of confusing[]https://www.ubbdev.com/threads/php/images/icons/wink.gif[/].

I can't say for sure how templates will work exactly yet because I haven't started them yet, but basically for each script you'll have a template associated with it. Some scripts might have a couple of templates because of the need to repeat a layout, like showflat for each post. But all HTML be moved out of the php scripts so changing the look will just require modifying one of the templates.


UBB.threads Developer
Sally #212869 11/07/2001 11:33 AM
Joined: Apr 2001
Posts: 27
Journeyman
Journeyman
Offline
Joined: Apr 2001
Posts: 27
you can use
..bgcolor="<?=$config[bgcolor]?>">

But it's not a big deal.

Seems like you'll have a lot of work with the template thing!


Another Questions:
Where should we post feature requests?

hPm #212870 11/07/2001 12:02 PM
Joined: Jan 2000
Posts: 5,073
Admin Emeritus
Admin Emeritus
Joined: Jan 2000
Posts: 5,073
You can post feature requests here or on Community.


UBB.classic: Love it or hate it, it was mine.

Link Copied to Clipboard
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
badfrog
badfrog
somewhere on the coast of Maine
Posts: 94
Joined: March 2007
Forum Statistics
Forums63
Topics37,575
Posts293,930
Members13,823
Most Online6,139
Sep 21st, 2024
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
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2025 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.1
(Snapshot build 20240918)