TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

Members
  • Total Members: 3,965
  • Latest: boruko
Stats
  • Total Posts: 195,976
  • Total Topics: 21,319
  • Online today: 602
  • Online ever: 8,223 (February 19, 2025, 04:35:35 AM)
Users Online
  • Users: 0
  • Guests: 243
  • Total: 243

Google bot and Spiders mod for SMF1.1rc3 - default theme

Started by dozzer, December 07, 2006, 10:11:07 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

dozzer

Hi all,

How do I add some code to the users online lock with regards to the googlebot & spiders mod for SMF ?

Any ideas?

See attached file  - there should be a "Spiders : <number>" as well as what is displayed.

Lesmond

Open tportalblocks.template.php

find
$online = ssi_whosOnline('array');
   echo $bullet.$txt['tp-users'].': '.$online['num_users'];
   echo '<br />'.$bullet.$txt['tp-guests'].': '.$online['guests'];
           echo '<br />'.$bullet.$txt['tp-total'].': '.$online['total_users'].'<hr />
';


change to
$online = ssi_whosOnline('array');
   echo $bullet.$txt['tp-users'].': '.$online['num_users'];
   echo '<br />'.$bullet.$txt['tp-guests'].': '.$online['guests'];
       echo '<br />'.$bullet.$txt['Spiders'].': '.$online['num_spiders'];
   echo '<br />'.$bullet.$txt['tp-total'].': '.$online['total_users'].'<hr />
';


open tportal.english.php
find at the end
?>

add above it
$txt['Spiders'] = 'Spiders';

spiders will show up in the block of users online


dozzer

Quote from: Lesmond on December 07, 2006, 10:27:30 PM
Open tportalblocks.template.php

find
$online = ssi_whosOnline('array');
   echo $bullet.$txt['tp-users'].': '.$online['num_users'];
   echo '<br />'.$bullet.$txt['tp-guests'].': '.$online['guests'];
          echo '<br />'.$bullet.$txt['tp-total'].': '.$online['total_users'].'<hr />
';


change to
$online = ssi_whosOnline('array');
   echo $bullet.$txt['tp-users'].': '.$online['num_users'];
   echo '<br />'.$bullet.$txt['tp-guests'].': '.$online['guests'];
       echo '<br />'.$bullet.$txt['Spiders'].': '.$online['num_spiders'];
   echo '<br />'.$bullet.$txt['tp-total'].': '.$online['total_users'].'<hr />
';


open tportal.english.php
find at the end
?>

add above it
$txt['Spiders'] = 'Spiders';

spiders will show up in the block of users online



WOW -  your a star!!  thanks mate.

Nokonium

You can also add buddies in a similar fashion


Ã,  Ã,  Ã,  Ã,  Ã,  Ã,  Ã,  Ã,  echo $bullet.$txt['tp-users'].': '.$online['num_users'];
echo '<br />'.$bullet.$txt['tp-buddies'].': '.$online['buddies'];
echo '<br />'.$bullet.$txt['tp-guests'].': '.$online['guests'];
echo '<br />'.$bullet.$txt['tp-spiders'].': '.$online['num_spiders'];
echo '<br />'.$bullet.$txt['tp-total'].': '.$online['total_users'].'<hr />
<div style="width: 100%; ' , $online['num_users']>14 ? 'height: 23ex;overflow: auto;' : '' ,'">';


//spiders and buddies
$txt['tp-spiders'] = 'Spiders';
$txt['tp-buddies'] = 'Buddies';

Lesmond

would you believe now I cant get it to work :idiot2: I have just updated to smf 1.1 and tp 9.7
spiders text don't show up in the list, but I have changed tportal.english.php do I need to modify another file?

Users: 1
Guests: 1
: 5
Total: 7

rebelrose


Lesmond


G6Cad

The language strings missing from the Tportal.english.php file

//spiders and buddies
$txt['tp-spiders'] = 'Spiders';
$txt['tp-buddies'] = 'Buddies';


Add the language strings in there in the bottom right before the ?> ans the text will show up in the blocks again.

Lesmond

Thanks G6 :) I cant read my own instructions :idiot2: I was putting the code in Who.english.php and not Tportal.english.php ???

PowerPyx

hm strange - upgrading from 1.1rc3 / tp 0.96 to 1.1 / tp 0.97 and my googlebot & spider mod still works fine o.O - didn't need to change anything.

This website is proudly hosted on Crocweb Cloud Website Hosting.