PDA

View Full Version : Help me figure out how to edit the forum template


Scabrous Birdseed
01-06-2009, 22:30:33
I'm going INSANE(ish) over the "postbit" template in Vbulletin. Going by the way the other templates (threadbit for the thread listing, forumbit for the forum lists) have been set up this should be the individual posts in a thread, but nothing I edit in it seems to make any difference at all.

Any idea how this works?

Funko
02-06-2009, 08:14:22
Ah. Yes, you're right it is that template... but...

The issue is that we're using postbit_legacy template because we want the old style poster details at the left type layout.

Luckily the article I found telling me how to remove postcounts actually had that detail on it or I'd still be beating my head too.

Nav
02-06-2009, 08:16:03
Something went wrong. It seems vb was trying to insert a new record for an already existing database element. This might be a bug and not your fault - but it might relate to your original template being based on 3.6

INSERT INTO template
(styleid, title, template, template_un, dateline, username, version, product)
VALUES
(15,
'albumbit',
'<tr>\r\n $template_hook[albumbit_start]\r\n <td class=\\\"alt1\\\" valign=\\\"middle\\\" align=\\\"center\\\">\r\n \".(($album[\'coverthumburl\']) ? (\"\r\n <a href=\\\"album.php?\" . $GLOBALS[\'vbulletin\']->session->vars[\'sessionurl\'] . \"albumid=$album[albumid]\\\"><img src=\\\"$album[coverthumburl]\\\" border=\\\"0\\\" alt=\\\"$vbphrase[picture]\\\" $album[coverdimensions] /></a>\r\n \") : (\"\r\n &nbsp;\r\n \")).\"\r\n </td>\r\n <td class=\\\"alt1\\\" valign=\\\"middle\\\">\r\n \".(($show[\'moderated\']) ? (\"<img class=\\\"inlineimg\\\" src=\\\"$stylevar[imgdir_misc]/moderated_small.gif\\\" alt=\\\"\" . construct_phrase(\"$vbphrase[x_moderated_pictures]\", \"$album[moderatedcount]\") . \"\\\" style=\\\"float:$stylevar[right]\\\" />\") : (\"\")).\"\r\n <a href=\\\"album.php?\" . $GLOBALS[\'vbulletin\']->session->vars[\'sessionurl\'] . \"albumid=$album[albumid]\\\"><strong>$album[title_html]</strong></a>\r\n <div class=\\\"smallfont\\\">\r\n $album[description_html]\r\n \".(($show[\'personalalbum\']) ? (\"<span class=\\\"shade\\\">$albumtype</span>\") : (\"\")).\"\r\n </div>\r\n </td>\r\n <td class=\\\"alt1\\\" valign=\\\"middle\\\" align=\\\"center\\\">$album[picturecount]</td>\r\n <td class=\\\"alt1\\\" valign=\\\"middle\\\" nowrap=\\\"nowrap\\\">\r\n \".(($album[\'lastpicturedate\']) ? (\"\r\n $album[picturedate] \".((!$show[\'detailedtime\']) ? (\"<span class=\\\"time\\\">$album[picturetime]</span>\") : (\"\")).\"\r\n \") : (\"\r\n $vbphrase[none]\r\n \")).\"\r\n </td>\r\n $template_hook[albumbit_end]\r\n</tr>',
'<tr>\r\n $template_hook[albumbit_start]\r\n <td class=\"alt1\" valign=\"middle\" align=\"center\">\r\n <if condition=\"$album[\'coverthumburl\']\">\r\n <a href=\"album.php?$session[sessionurl]albumid=$album[albumid]\"><img src=\"$album[coverthumburl]\" border=\"0\" alt=\"$vbphrase[picture]\" $album[coverdimensions] /></a>\r\n <else />\r\n &nbsp;\r\n </if>\r\n </td>\r\n <td class=\"alt1\" valign=\"middle\">\r\n <if condition=\"$show[\'moderated\']\"><img class=\"inlineimg\" src=\"$stylevar[imgdir_misc]/moderated_small.gif\" alt=\"<phrase 1=\"$album[moderatedcount]\">$vbphrase[x_moderated_pictures]</phrase>\" style=\"float:$stylevar[right]\" /></if>\r\n <a href=\"album.php?$session[sessionurl]albumid=$album[albumid]\"><strong>$album[title_html]</strong></a>\r\n <div class=\"smallfont\">\r\n $album[description_html]\r\n <if condition=\"$show[\'personalalbum\']\"><span class=\"shade\">$albumtype</span></if>\r\n </div>\r\n </td>\r\n <td class=\"alt1\" valign=\"middle\" align=\"center\">$album[picturecount]</td>\r\n <td class=\"alt1\" valign=\"middle\" nowrap=\"nowrap\">\r\n <if condition=\"$album[\'lastpicturedate\']\">\r\n $album[picturedate] <if condition=\"!$show[\'detailedtime\']\"><span class=\"time\">$album[picturetime]</span></if>\r\n <else />\r\n $vbphrase[none]\r\n </if>\r\n </td>\r\n $template_hook[albumbit_end]\r\n</tr>',
1243893819,
'Scabrous Birdseed',
'3.8.2',
'vbulletin');

Duplicate entry 'albumbit-15-template' for key 2

Venom
02-06-2009, 11:04:36
Use a hammer and some dynamite. That'll fix anything.

Funko
02-06-2009, 11:06:26
It's how you cured your erectile dysfunction right?

King_Ghidra
02-06-2009, 12:29:25
also works for breach births

King_Ghidra
02-06-2009, 12:30:09
and lost hamsters

Lurker
02-06-2009, 12:38:54
Fixes constipation for sure.

Venom
02-06-2009, 12:53:29
Clears gonnorhea right up.

Scabrous Birdseed
02-06-2009, 16:47:32
Right, I've worked quite a bit now on the "Invisible test style" template. If I send you a set of images for all the buttons I think it's practically done, or do you have any critiques? I moved the controls into the top bar, added lines between posts, made signatures smaller and looser...

Scabrous Birdseed
02-06-2009, 18:40:23
Oh, and I have absolutely no idea what nav is on about. What template do I need to redo?

Scabrous Birdseed
02-06-2009, 22:07:04
Right, almost all the images are done. Can I send them to one of you folks for inclusion?

Funko
03-06-2009, 08:27:43
Yes, but I can only upload them from home.

Funko
03-06-2009, 08:28:20
If at all possible could you zip them into their correct parent directories? buttons/statusicon etc.

Scabrous Birdseed
03-06-2009, 08:38:09
Does it really matter? I'll just point all the references to the same directory.

Funko
03-06-2009, 08:48:05
As long as you include ALL the images, that's fine. Otherwise I have been taking a copy of the image directories and overwriting any that are replaced.

Scabrous Birdseed
03-06-2009, 09:00:16
Okay, okay, I'll do that. I think mine are missing some icons from the PM system and the "closed thread" icon, which is never going to happen here anyway.

Drekkus
03-06-2009, 09:58:34
Something went wrong. It seems vb was trying to insert a new record for an already existing database element. This might be a bug and not your fault - but it might relate to your original template being based on 3.6

INSERT INTO template
(styleid, title, template, template_un, dateline, username, version, product)
VALUES
(15,
'albumbit',
'<tr>\r\n $template_hook[albumbit_start]\r\n <td class=\\\"alt1\\\" valign=\\\"middle\\\" align=\\\"center\\\">\r\n \".(($album[\'coverthumburl\']) ? (\"\r\n <a href=\\\"album.php?\" . $GLOBALS[\'vbulletin\']->session->vars[\'sessionurl\'] . \"albumid=$album[albumid]\\\"><img src=\\\"$album[coverthumburl]\\\" border=\\\"0\\\" alt=\\\"$vbphrase[picture]\\\" $album[coverdimensions] /></a>\r\n \") : (\"\r\n &nbsp;\r\n \")).\"\r\n </td>\r\n <td class=\\\"alt1\\\" valign=\\\"middle\\\">\r\n \".(($show[\'moderated\']) ? (\"<img class=\\\"inlineimg\\\" src=\\\"$stylevar[imgdir_misc]/moderated_small.gif\\\" alt=\\\"\" . construct_phrase(\"$vbphrase[x_moderated_pictures]\", \"$album[moderatedcount]\") . \"\\\" style=\\\"float:$stylevar[right]\\\" />\") : (\"\")).\"\r\n <a href=\\\"album.php?\" . $GLOBALS[\'vbulletin\']->session->vars[\'sessionurl\'] . \"albumid=$album[albumid]\\\"><strong>$album[title_html]</strong></a>\r\n <div class=\\\"smallfont\\\">\r\n $album[description_html]\r\n \".(($show[\'personalalbum\']) ? (\"<span class=\\\"shade\\\">$albumtype</span>\") : (\"\")).\"\r\n </div>\r\n </td>\r\n <td class=\\\"alt1\\\" valign=\\\"middle\\\" align=\\\"center\\\">$album[picturecount]</td>\r\n <td class=\\\"alt1\\\" valign=\\\"middle\\\" nowrap=\\\"nowrap\\\">\r\n \".(($album[\'lastpicturedate\']) ? (\"\r\n $album[picturedate] \".((!$show[\'detailedtime\']) ? (\"<span class=\\\"time\\\">$album[picturetime]</span>\") : (\"\")).\"\r\n \") : (\"\r\n $vbphrase[none]\r\n \")).\"\r\n </td>\r\n $template_hook[albumbit_end]\r\n</tr>',
'<tr>\r\n $template_hook[albumbit_start]\r\n <td class=\"alt1\" valign=\"middle\" align=\"center\">\r\n <if condition=\"$album[\'coverthumburl\']\">\r\n <a href=\"album.php?$session[sessionurl]albumid=$album[albumid]\"><img src=\"$album[coverthumburl]\" border=\"0\" alt=\"$vbphrase[picture]\" $album[coverdimensions] /></a>\r\n <else />\r\n &nbsp;\r\n </if>\r\n </td>\r\n <td class=\"alt1\" valign=\"middle\">\r\n <if condition=\"$show[\'moderated\']\"><img class=\"inlineimg\" src=\"$stylevar[imgdir_misc]/moderated_small.gif\" alt=\"<phrase 1=\"$album[moderatedcount]\">$vbphrase[x_moderated_pictures]</phrase>\" style=\"float:$stylevar[right]\" /></if>\r\n <a href=\"album.php?$session[sessionurl]albumid=$album[albumid]\"><strong>$album[title_html]</strong></a>\r\n <div class=\"smallfont\">\r\n $album[description_html]\r\n <if condition=\"$show[\'personalalbum\']\"><span class=\"shade\">$albumtype</span></if>\r\n </div>\r\n </td>\r\n <td class=\"alt1\" valign=\"middle\" align=\"center\">$album[picturecount]</td>\r\n <td class=\"alt1\" valign=\"middle\" nowrap=\"nowrap\">\r\n <if condition=\"$album[\'lastpicturedate\']\">\r\n $album[picturedate] <if condition=\"!$show[\'detailedtime\']\"><span class=\"time\">$album[picturetime]</span></if>\r\n <else />\r\n $vbphrase[none]\r\n </if>\r\n </td>\r\n $template_hook[albumbit_end]\r\n</tr>',
1243893819,
'Scabrous Birdseed',
'3.8.2',
'vbulletin');

Duplicate entry 'albumbit-15-template' for key 2
i have the distinct feeling there's a bracket missing in there somewhere