The vB Geek

Go Back   The vB Geek > vB Geek Products > Geek Article and Review System

Geek Article and Review System GARS is the mega popular system for turning forums into articles, tutorials, or even reviews.

Advertisement
  Learn how to remove ads

Reply
 
Thread Tools Display Modes
  #1  
Old 09-23-2006, 05:22 PM
Asasi Asasi is offline
Junior Member
 
Join Date: Jun 2006
Posts: 25
Geek Article and Review System License Holder 
Default [Custom Field] How to hide when blank?

Hi!
I have added a custom filed [text] and show that on postbit!
But my problem is hide and show that!
Its field is not required. so it maybe left blank "NULL". How can I use something like <if> tag that couse when this field is blank not show and when it Inputed by thred starter show?

thanks
Reply With Quote
  #2  
Old 09-24-2006, 09:30 AM
The Geek's Avatar
The Geek The Geek is offline
Senior Member
 
Join Date: Aug 2005
Posts: 6,717
Geek Article and Review System License Holder GeekMart License Holder Geek Auto-Linker Pro License Holder Geek Advertising Banner License Holder Geek Gazette License Holder 
Default

Do you mean something like this:

<if condition="$post['gars5']">my value is $post[gars5]</if>
Reply With Quote
  #3  
Old 09-26-2006, 12:41 PM
Asasi Asasi is offline
Junior Member
 
Join Date: Jun 2006
Posts: 25
Geek Article and Review System License Holder 
Default

Yes!
It will show "my value is $post[gars5]" If its field is not blank?
Reply With Quote
  #4  
Old 09-26-2006, 06:42 PM
The Geek's Avatar
The Geek The Geek is offline
Senior Member
 
Join Date: Aug 2005
Posts: 6,717
Geek Article and Review System License Holder GeekMart License Holder Geek Auto-Linker Pro License Holder Geek Advertising Banner License Holder Geek Gazette License Holder 
Default

Yup
Reply With Quote
  #5  
Old 09-28-2006, 06:49 AM
Asasi Asasi is offline
Junior Member
 
Join Date: Jun 2006
Posts: 25
Geek Article and Review System License Holder 
Default

Good but a problem!
I added a text field and using that for a url. now when I use this code:
Code:
<a href="$thread[gars7]"><img border="0" src="$stylevar[imgdir_misc]/sub.png"><br>Download $post[title]</a>
(in gars_pb template) its not working and url changed to thread url!
But if i use this code in gars_threadbit it worked correctly!
whats the problem u think?

thanks a lot
Reply With Quote
  #6  
Old 09-28-2006, 07:02 AM
Asasi Asasi is offline
Junior Member
 
Join Date: Jun 2006
Posts: 25
Geek Article and Review System License Holder 
Default

I think I have to use "$post" in post related templates and "$thread" in thread related templates!
But not working anymore. I think some days ago I used this but now I cant!
And what is different with "$post[gars5]" and "$post['gars5']" !
what do ' around the gars5 ?
Reply With Quote
  #7  
Old 09-28-2006, 09:56 AM
The Geek's Avatar
The Geek The Geek is offline
Senior Member
 
Join Date: Aug 2005
Posts: 6,717
Geek Article and Review System License Holder GeekMart License Holder Geek Auto-Linker Pro License Holder Geek Advertising Banner License Holder Geek Gazette License Holder 
Default

In the threadbit templates, you need to use $thread[gars5] and in the postbit templates, use $post[gars5]

You only use $post['gars5'] (with the apostraphes) if it is in a conditional statement like <if condition="$post['gars5']"><strong>$post[gars5]</if>

HTHs
Reply With Quote
  #8  
Old 09-28-2006, 10:11 AM
Asasi Asasi is offline
Junior Member
 
Join Date: Jun 2006
Posts: 25
Geek Article and Review System License Holder 
Default

Quote:
Originally Posted by The Geek
In the threadbit templates, you need to use $thread[gars5] and in the postbit templates, use $post[gars5]

You only use $post['gars5'] (with the apostraphes) if it is in a conditional statement like <if condition="$post['gars5']"><strong>$post[gars5]</if>

HTHs
lets try!
thanks

Last edited by Asasi; 09-28-2006 at 10:16 AM..
Reply With Quote
  #9  
Old 09-30-2006, 06:21 PM
Asasi Asasi is offline
Junior Member
 
Join Date: Jun 2006
Posts: 25
Geek Article and Review System License Holder 
Default

I did this but not working.
see! I have field no=7 ... I wnat to add a text like "aaa" that linked to no.7 custom field. and this is in postbit
I have to edit "gars_pb" template and put this:
Code:
<a href="$post[gars7]">aaa</a>
where is incorrect?
Reply With Quote
  #10  
Old 09-30-2006, 11:37 PM
The Geek's Avatar
The Geek The Geek is offline
Senior Member
 
Join Date: Aug 2005
Posts: 6,717
Geek Article and Review System License Holder GeekMart License Holder Geek Auto-Linker Pro License Holder Geek Advertising Banner License Holder Geek Gazette License Holder 
Default

Does it appear in the custom fields module correctly?
Reply With Quote
Reply

Thread 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
Thread Thread Starter Forum Replies Last Post
Custom field layout help croft Geek Article and Review System 7 09-22-2007 06:05 AM
Adsense in Custom Field? soultrader Geek Article and Review System 1 10-10-2006 03:10 PM
Custom Field Problem soultrader Geek Article and Review System 2 10-03-2006 10:09 PM
Custom Field problem spadez Geek Article and Review System 1 09-24-2006 09:36 AM
Custom field or custom module? Richy Geek Article and Review System 6 06-07-2006 08:15 PM


All times are GMT. The time now is 12:42 PM.


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