Login     Sign up
Search bar
Jcow Master (@falcone)
Join date: Sep 2nd 2010
Community posts: 917
View Profile
Send Message

page.tpl.php blue theme

old code:
[code]
<td>
<table cellpadding="0" cellspacing="0">
<form action="<?=url('search/listing')?>" method="post" name="search_form">
<tr>
<td valign="top">
<input type="text" id="search_box" name="title" value="" name="search_box" />
</td>
<td>
<input type="submit" value="find" id="search_button" style="display:none" />
</td>
<td>
<input type="image" src="<?php echo uhome().'/themes/blue/search_button.gif';?>" />
</tr>
</form>
</table>
</td>
[/code]

new one:

[code]
<? if ($client['id']){ echo '
<td>
<table cellpadding="0" cellspacing="0">
<form action="'.url('search/listing').'" method="post" name="search_form">
<tr>
<td valign="top">
<input type="text" id="search_box" name="title" value="" name="search_box" />
</td>
<td>
<input type="submit" value="find" id="search_button" style="display:none" />
</td>
<td>
<input type="image" src="'.uhome().'/themes/blue/search_button.gif'.'" />
</tr>
</form>
</table>
</td>';}
else {
echo '<td width="660px"></td>';
}
?>
[/code]

just replace old code by new code.

174 months ago
AL (@switch48)
Join date: Sep 1st 2010
Community posts: 450
View Profile
Send Message

Wow I must of been half asleep and doing something wrong because yesterday when I tried I just couldn't get it to work ,
But today after a good nights sleep hey presto It works..lol

Cheers Falcone

174 months ago
jacky loon (@jack41)
Join date: Nov 9th 2010
Community posts: 87
View Profile
Send Message

yes works in blue theme. but how to replace this code in facebook theme?

172 months ago
AL (@switch48)
Join date: Sep 1st 2010
Community posts: 450
View Profile
Send Message

should be same thing in page.tpl.php facebook theme

172 months ago
andy (@andy)
Join date: Nov 26th 2010
Community posts: 12
View Profile
Send Message

you change just !$client['id']

!$client['id']= not logged in
$client['id'] = logged in

for me it works

172 months ago
Prev 1 2