• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

XF 1.2 Another BB Code question

#1
Hi Folks,

Working in a test environment to work out all the bugs on transferring over from vbulletin 4 CMS. On a couple of my articles I have the following BB code to display images for articles that were in the CMS;

View attachment 185398

the # in the brackets being the attachment ID.

How would I go about writing a new BB code to display those images as thumbnails in my current posts?


Also, would there happen to be a BB code "pack" for some of vb4's bb code formatting that is not native to XF? Some other examples;

[HR][/HR] Horizontal line
[TR][/TR]
[TD][/TD] (Tables)
 
#3
Thats better than I was - but my formatting is awfully funky now with tons of spacing. No support for table within a table perhaps?;

TableSpacing.jpg

Here is what the text is;

[TABLE]
[TR]
[TD]General ATC200 Specifications[TABLE]
[TR]
[TD]Production Years :[/TD]
[TD]1981-1983[/TD]
[/TR]
[TR]
[TD]Engine type :[/TD]
[TD]4 Stroke, Air cooled[/TD]
[/TR]
[TR]
[TD]Displacement :[/TD]
[TD]192 cc[/TD]
[/TR]
[TR]
[TD]Bore x Stroke :[/TD]
[TD]65 x 57.8 mm[/TD]
[/TR]
[TR]
[TD]Compression ratio :[/TD]
[TD]7.8 to 1[/TD]
[/TR]
[TR]
[TD]Compression :[/TD]
[TD]142 - 170 psi[/TD]
[/TR]
[TR]
[TD]Transmission :[/TD]
[TD] 5 speed[/TD]
[/TR]
[TR]
[TD]Clutch Type :[/TD]
[TD] Semi-auto[/TD]
[/TR]
[TR]
[TD]Oil Capacity :[/TD]
[TD] 1.43 Qt[/TD]
[/TR]
[TR]
[TD]Carburetion :[/TD]
[TD] 22 mm Keihin[/TD]
[/TR]
[TR]
[TD]Starting system :[/TD]
[TD]Recoil Starter[/TD]
[/TR]
[TR]
[TD]Fuel capacity :[/TD]
[TD]2.3 Gal , 0.4 Gal res.[/TD]
[/TR]
[TR]
[TD]Wheelbase :[/TD]
[TD]46.9 in.[/TD]
[/TR]
[TR]
[TD]Overall Length :[/TD]
[TD]72.4 in.[/TD]
[/TR]
[TR]
[TD]Overall Width :[/TD]
[TD]42.5 in.[/TD]
[/TR]
[TR]
[TD]Ground Clearance :[/TD]
[TD]4.9 in.[/TD]
[/TR]
[TR]
[TD]Seat Height :[/TD]
[TD]27.2 in.[/TD]
[/TR]
[TR]
[TD]Front Tires :[/TD]
[TD]25 x 12 x 9[/TD]
[/TR]
[TR]
[TD]Rear Tires :[/TD]
[TD]25 x 12 x 9[/TD]
[/TR]
[TR]
[TD]Front Suspension :[/TD]
[TD]none[/TD]
[/TR]
[TR]
[TD]Rear Suspension :[/TD]
[TD]none[/TD]
[/TR]
[TR]
[TD]Front Brake :[/TD]
[TD]lever + cable operated drum[/TD]
[/TR]
[TR]
[TD]Rear Brake :[/TD]
[TD]pedal operated Drum[/TD]
[/TR]
[TR]
[TD]Final Drive :[/TD]
[TD]chain[/TD]
[/TR]
[TR]
[TD]Dry Weight :[/TD]
[TD]299.9 lbs[/TD]
[/TR]
[TR]
[TD]MSRP :[/TD]
[TD]$1,298.00[/TD]
[/TR]
[/TABLE]
[/TD]
[TD] View attachment 91347 [/TD]
[/TR]
[/TABLE]
 
#5
Hmmm...I see.

Any easy way to find and replace or some similar operation those tables I have constructed on pages to take the spacing out? Have probably 50 posts with those in there...
 

Brogan

XenForo moderator
Staff member
#6
There is no easy way.
I use Excel and the concatenation function to create the strings for my tables.

There are other table BB Codes available in the RM which may prove more suitable.
 
#7
I'll check them out, but this will probably be a manual job that can be done over time atleast.

Any ideas on the image code I posted above, how I would make that work?
 
#9
Well I had pasted the code itself and I guess it tried to parse it. Basially, in the posts that were imported from my vb4 cms, I have code that looks like;

(attach=config) attachmentid#only(/attach) (Using brackets though, obviously)

Previously, it would display the image in the vb4 CMS with this code as a thumbnail of varying different sizes and then pull the light box once it was clicked on.

In Xenforo, it displays it only as a hyperlink. I'd like to display it as a thumbnail instead, knowing I don't really have the option to make it a different thumbnail size from image to image, like I did in vb4.