Quote Username in Oxwall Status Update Box

You might be a little bit surprised at the sequence at which articles are being published here, a bit weird right? Over the last few days, I have been working to correct that, so from now onward the articles here will follow a steady sequence: This is to make sure that our readers don’t miss any of our updates.

This version of our Oxwall custom code modification we see us modify the default placeholder text in the update status box. Now your users will see something like What’s happening {$userName}?  ( {$UserName} will be automatically replaced by the user’s name) instead of What’s happening?, if you used facebook before 2012 you will understand what I’m saying.
In place of this:

 You will have something like this:

Amazing right? Here we go….

 Step #1.

  • Backup and edit this file /ow_plugins/newsfeed/components/update_status.php from your cpanel or code editor.
  •  Find and replace this code

$field->setInvitation( OW::getLanguage()->text(‘newsfeed’, ‘status_field_invintation’) );

  • with

$userName = BOL_UserService::getInstance()->getDisplayName(OW::getUser()->getId()); $field->setInvitation( OW::getLanguage()->text(‘newsfeed’, ‘status_field_invintation’,array(‘userName’=>$userName)) );

Step #2.

  • Logon to your admin dashboard
  • Go to language settings
  • Change the text value for this key status_field_invintation, to locate the key value, simply search for “What’s happening?” (without qoute).
  • Change What’s happening? to What’s happening {$userName}?
  • Save your changes and enjoy!

Leave a Reply