2005-05-14, 11:26 PM
Pages: 1 2
2005-05-15, 04:47 AM
Hmm, this will require a bit of code in showthread if you plan on adding the work Location: cause what if they havn't entered where they live Anyway, I believe, to get the england part, adding $post[fid2] to the postbit template should work.
2005-05-15, 07:34 AM
And what if i wanted to Location to be for example with red color ? how to add the color ?
2005-05-15, 08:14 AM
Cheers dude i've got somthing to work
its 1 btw for the location info
Cheers again your a great help mate 10/10 again
its 1 btw for the location info
Cheers again your a great help mate 10/10 again
2005-05-15, 10:39 AM
i think you could do something like
in showthread.php then in the postbit template if you add $location, it will only show it if its set
if($post['fid1'])
{
$post['fid1'] = htmlspecialchars($post['fid1']);
$location = "Location: " . $post['fid1'];
}
else
{
$location = "";
}
in showthread.php then in the postbit template if you add $location, it will only show it if its set
2005-05-15, 12:36 PM
no need
just got to postbit template and add this
FIND
$lang->postbit_status $onlinestatus$replink<br />
UNDER ADD
<font color= "red">Location: $post[fid1]<font>
EXAMPLE - Location: England
if you want only the location info to be red and not the location title
do
Location:<font color= "red">$post[fid1]<font>
EXAMPLE - Location: England
Cheers to K776 for his good info that solved this for me
Cheers bud
just got to postbit template and add this
FIND
$lang->postbit_status $onlinestatus$replink<br />
UNDER ADD
<font color= "red">Location: $post[fid1]<font>
EXAMPLE - Location: England
if you want only the location info to be red and not the location title
do
Location:<font color= "red">$post[fid1]<font>
EXAMPLE - Location: England
Cheers to K776 for his good info that solved this for me
Cheers bud
2005-05-15, 01:07 PM
HTML will not be filtered out then and users will be able to enter HTML in to the field and it will be displayed.
As Dempsey said, you will need to add some code. Add it to the makepostbit function in inc/functions_post.php
Chris
As Dempsey said, you will need to add some code. Add it to the makepostbit function in inc/functions_post.php
Chris
2005-05-15, 01:14 PM
and also by adding the code to the makepostbit function you can only show the 'Location:' text if the location is set
2005-05-15, 03:50 PM
ahhhh i see. will have a play
2005-06-04, 07:45 PM
Thought I would post exactly what worked for me on http://www.agroots.com/forum
An example thread can be found at http://www.agroots.com/forum/tid4pid9#pid9 where the first post does not have a Location (as of this post) and the 2nd post has a location.
If the user has a location entered, it will show it - otherwise it won't show anything.
Find this code in inc/functions_post.php (Line 392)
And add this code right after it:
Then in the postbit template, add:
$location
right after:
$lang->postbit_status $onlinestatus$replink<br />
An example thread can be found at http://www.agroots.com/forum/tid4pid9#pid9 where the first post does not have a Location (as of this post) and the 2nd post has a location.
If the user has a location entered, it will show it - otherwise it won't show anything.
Find this code in inc/functions_post.php (Line 392)
if($usergroup['image'] != "")
{
$usergroupimage = "<img src=\"".$usergroup['image']."\" border=\"0\" alt=\"".$usergroup['title']."\">";
}
And add this code right after it:
//Adds Location to the profile in thread view
if($post['fid1']!="")
{
$post['fid1'] = htmlspecialchars($post['fid1']);
$location= "Location: " . $post['fid1'] . "<br />";
}
else
{
$location = "";
}
Then in the postbit template, add:
$location
right after:
$lang->postbit_status $onlinestatus$replink<br />
Pages: 1 2