The vB Geek

Go Back   The vB Geek > vB Geek Modifications > Tutorials

Tutorials Tutorials and articles on using vB Geek stuff.

Advertisement
This is an HTML example. Isn't it just wonderful?!?!
  Learn how to remove ads

Comment
 
Tutorial Tools Display Modes
Custom Fields
Custom Fields
Published by The Geek
06-05-2006
Default Showing the results!


Step 3
Displaying the values of your custom fields

Make sure you have the custom_fields.php module registered.

go to admincp->gars->modules
Check the bottom section (Registered modules) to see if you have Custom Fields there.
If not, then add it by clicking Register New Module and adding the following settings:
PHP Code:
titleCustom Fields
file
custom_fields.php
templates
GARS_custom_containerGARS_custom_row,GARS_custom_date,GARS_custom_input,GARS_custom_text,GARS_custom_textarea,GARS_custom_thumbnail 
Then click Save.

This will make the custom fields module available to your module sets.

Step 4
Add Custom Fields to your module sets

Edit a module set making sure you are on the showthread page.
Scroll to the bottom of the page and in the left selection box, choose Custom Fields, then the position you want to place it.
Click Save and the Custom Fields module will be in position.
Edit the Custom Fields module settings page by clicking it's name (or by selecting edit from the drop down menu next to its name).


Here you can edit the title for the module box when it displays. You can also select which Custom Fields display along with an optional caption.
You can also overwrite the templates GARS uses to display the custom fields. Leave the template settings blank for the default.

Viola!
result.JPG
Whoop there it is...
Tutorial for
GARS

Contents

Tutorial Tools
Show Printable Version  Email this Page 

<<  <    (Page 2 of 2)    > >>
  #1  
By benj on 08-20-2006, 04:00 PM
Default

when making a custom template for a field.whats the varible for the value of the field ?
Reply With Quote
  #2  
By The Geek on 08-21-2006, 08:41 AM
Default

Sorry, you lost me
Reply With Quote
  #3  
By benj on 08-21-2006, 09:56 AM
Default

when adding a custom field to the custom module it offers you the option to use a template ? how do thouse templates work ?
Reply With Quote
  #4  
By The Geek on 08-21-2006, 11:36 AM
Default

What it does is allow you to override the default template for displaying the item or hosing the module.

That gives you the ability to do something far cooler then simply showing the text results. The standard results for that module are displayed in GARS_custom_row.
Reply With Quote
  #5  
By beduino on 10-15-2006, 05:00 AM
Default very good

this tutorial is very clear and useful,
but my first tentative fails...when i will display in my personal module set - he don't appears!
what i do wrong?
tks
beduino
Reply With Quote
  #6  
By The Geek on 10-15-2006, 05:56 AM
Default

If the custom fields appear when creating/editing a thread but do not appear when viewing a thread... the most common culprit is your Custom Fields module settings.

Edit the module set for the type in question.
On the showthread page of the module set, click the Custom Field module (if the module isnt there, you need to add it)
Tick each field you want to display.

Save it and bob should be your uncle.

HTHs
Reply With Quote
  #7  
By beduino on 10-15-2006, 12:56 PM
Exclamation it helps!

Well,
I'm learning the use of GARS.
In fact the 'custom fields' is to author, and no to comments of viewers and users. IMHO this mod is one of better licences I have !
All the best,
Beduino
ps. a lot of questions will be come
Reply With Quote
  #8  
By Julian on 11-02-2006, 06:59 PM
Default

I have another challange: I want to display the Value of the custom-field inside of another template. Well, to be clear: Behind the picture displayed should be a link and a part of the link is the custom-field.

The custom-field is named " test " and the content of one of the posts is "12345". Now I want to have a link in the postbit which is built up like this:

www.abcde.de/index.php&test=12345&somethingelse

I´d like to get this in the way of:
Quote:
<a href="www.abcde.de/index.php&test="+"$table[test]&somethingelse" >$vbphrase[blabla]</a>
Is this possible?

Best wishes, Julian!
Reply With Quote
  #9  
By The Geek on 11-04-2006, 01:10 AM
Default

It should be fine. instead of $table[ test ], try $post[gars1] (where gars1 is the field name)

HTHs
Reply With Quote
Comment

Tutorial Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Tutorial Tutorial Starter Category Comments Last Post
Custom Fields powerful_rogue Geek Article and Review System 8 01-10-2008 02:21 PM
Custom Fields Damir Geek Article and Review System 27 10-13-2006 04:38 PM
cant see custom fields wildo69 Geek Article and Review System 14 09-05-2006 07:00 AM
Custom Fields utw-Mephisto Geek Article and Review System 3 07-14-2006 06:59 AM
Upload Custom Submission Avatars and custom fields question. Praetorian Geek Article and Review System 1 06-14-2006 01:50 PM


All times are GMT. The time now is 07:27 PM.


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.

Tutorial powered by GARS 2.1.9 ©2005-2006