phpFox 1.6, 2 and 3
The AVChat Module for phpFox 2 & 3 (and the Plugin for 1.6) handles the integration between your phpFox web site and our AVChat software.
Here's what it will do:
| phpFox 1.6 Plugin | phpFox 2.0 & 3.0 Module | |
|---|---|---|
| user name integration | yes | yes |
| gender integration | yes | yes |
| profile url integration | yes | yes |
| profile image integration | yes | yes |
| placement of video chat within the web site (user and admin interface) | yes | yes |
| allow for different features for different phpFox user groups (by editing external config file). | Manually by editing external .php file and editing php code. | Directly from the admin area of phpFox. |
| Display in the web site who's in the video chat | no | yes |
If you cannot find the answer you’re looking for here, we encourage you to try our FAQ or forums. There's also more documentation regarding AVChat in the documentation area for the main standalone version.
All the specific documentation regarding phpFox is on this page so if you're looking for something specific just hit Ctrl+F on your browser.
Here are the phpFox related topics we will cover on this page:
- 1. Installing AVChat integration kit for phpFox 1.6, 2.0 and 3.0
- 2. Accessing the AVChat admin interface in phpFox
- 3. Location of AVChat files in a phpFox installation
- 4. Opening up the video chat in a pop up instead of in line in the web site
- 5. Placing ads around the video chat
- 6. phpFox's user roles and limiting features for specific user roles
- 7. Allowing visitors to join the video chat
- 8. Changing the looks of AVChat to better fit your phpFox web site
- 9. Displaying who's in the video chat on your web site in phpFox 2 and 3
1. Installing AVChat integration kit for phpFox 1.6, 2.0 and 3.0
First you have to download 2 archives from the client/trial area on avchathq.com to your computer. These 2 archives are:
- AVChat 3.0.zip (contains media server files for Red5/FMIS/Wowza and AVChat Standalone)
- avchat3_phpfox_all.zip (contains the 2 integration kits: one for phpFox 1.6 and one for 2.0)
Extract the 2 archives somewhere on your computer to have all the files handy! We will use files from both archives!
After installation, the first time you will log in the video chat you will be asked or a license key. It's in your client/trial area.
1.1 Setting up the avchat30 application on the media server
First you need to install the avchat30 application on your media server. If you don't know what a media server is check out the requirements. If you already have a media server (Red5, FMIS, FMIS hosting, Wowza) here's what you need to do:
| Red5 0.8 installed on a dedicated or VPS server |
Wowza installed on a dedicated or VPS server |
1. Upload the avchat30 folder from the AVChat 3.0.zip/Files to upload to your media server (Red5 0.8) folder to the webapps folder of your Red5 0.8 installation (C:\Program Files\Red5\webapps on Win, /opt/red5/webapps/ on Linux). 2. Linux only: Chmod the new avchat30 folder to 777. 3. Restart the Red5 server You're done, move to Part 1.2 below |
1. Upload the applications, lib and conf folders from the AVChat 3.0.zip/Files to upload to your media server (Wowza) folder to the root folder of your Wowza Media Server installation (C:\Program Files\Wowza Media Systems\Wowza Media Server Pro 1.7.2\ on Windows). 2. Restart the Wowza server You're done, move to Part 1.2 below |
| FMIS installed on a dedicated or VPS server |
FMIS hosting from http://influxis.com |
1. Upload the avchat30 folder from the AVChat 3.0.zip/Files to upload to your media server (FMS) folder to the applications folder of your FMIS installation (C:\Program Files\Macromedia\Flash Media Server\applications on Windows, /opt/macromedia/fms/applications/ on Linux). 2. Linux only: Chmod the new avchat30 folder to 777. You're done, move to Part 1.2 below |
While logged in your Influxis.com account: 1) Go to File Manager: Done. Your connection string used in Part 2 will look like: rtmp://123.rtmphost.com/avchat30/_definst_ where 123.rtmphost.com is shown at the top of your Influxis.com account. |
Now that we've got that out of the way, let's move on to installing the AVChat integration kit(s) for phpFox.
1.2 Installing the AVChat Plugin for phpFox 1.6
1.2.1 Installing the AVChat Plugin for phpFox 1.6
- Connect to your web site hosting account using FTP
- Copy the videochat folder from phpfox_1.6.x/plugins/ to [your site]/plugins/
- Chmod the [your site]/plugins/videochat/uploadedFiles folder to 777 (otherwise the upload function might not work)
- Create a new folder tokens ([your site]/plugins/videochat/tokens) and CHMOD it to 777 (otherwise we might have token generation issues later on)
- Edit [your site]/plugins/videochat/avc_settings.php in a text editor and set the value of
$avconfig['connectionstring'] like this:
$avconfig['connectionstring']='rtmp://myFMSserver.com/avchat30/_definst_';1.2.2 Creating a link for users to access the video chat on phpFox 1.6
This file: [your site]/design/templates/[your template(ours was default)]/public/_template.html is the main template for your website front end. In it we will have to add a link to the video chat.
- Log on to your web site via FTP and open _template.html a in a text editor
- And add this line of HTML code to it:
We've added it right after this line:
<td><a {if $aCurrUser}href="javascript:void(0);" onClick="popUp2('{url link='public.plugins.videochat'}videochat.php', '800','580','yes','100','100', 'chat');"{else}href="{url link=public.account}"{/if}>VIDEO CHAT</a></td><td>|</td>
{Menu::MainMenu location="header" template="MainHeader"}
You can take a look at our example _template.html file (phpfox_1.6.x\design\templates\default\public\_template.html) to see where we placed it.
- Save the file and upload it back to the web server.
- A link to the video chat to show up in the top right menu of your web site.
1.2.3 Creating a link for admins to access the phpFox 1.6 admin area
This file: [your site]/design/templates/[your template(ours was default)]/admin/frames/left.html represents the left side of your phpFox admin area. In it we will have to add a link to the admin interface of the video chat.
- Log on to your web site via FTP and open left.html a in a text editor
- Add these lines to it:
<table style="width:100%;cursor:pointer;" class="header" cellspacing="0" cellpadding="4" onclick="SwitchMenu('sub50,'hidetext50')">
<tr>
<td style="font-size:8pt;">
<img src="design/pic/admin/spacer.gif" alt="" width="8" height="8" class="sqr" style="vertical-align:middle;" />
<span style="vertical-align:middle;"><b>FLASH VIDEO CHAT ADMIN</b></span>
</td>
<td style="font-size:7pt;text-align:right;">
<span class="cur" id="hidetext50">[-]</span>
</td>
</tr>
</table>
<div class="submenu" id="sub50">
<ul class="navlist">
<li><a href="javascript:void(0);" onClick="popUp2('{url link='public.plugins.videochat'}videochat-admin.php', '800','580','yes','100','100', 'chat');" target="main"><img src="design/pic/admin/spacer.gif" alt="" width="8" height="8" class="sqr2" style="vertical-align:middle;" /> ENTER FLASH VIDEO CHAT as ADMIN</a></li>
</ul>
</div><br />
We've added it right before this line:
{if $bRemoveBrand}
You can take a look at our example left.html file (phpfox_1.6.x\design\templates\default\admin\frames\left.html) and see where and how we placed it.
- A link to the video chat's admin interface will now show up in the in the top left side of your phpFox admin area.
1.3 Installing the AVChat Module for phpFox 2.0 and 3.0
- Copy include and module folders (from avchat3_phpfox_all.zip\phpfox_2.0.x OR avchat3_phpfox_all.zip\phpfox_3.0.x depending on your phpFox version) to the root of your phpFox installation
- phpFox 3 only: copy from the AVChat3.0.zip unzipped archive the contents of the Files to upload to your website folder into [your site]/module/avchat3/include/plugin/ .
- Chmod the [your site]/module/avchat3/include/plugin/uploadedFiles folder to 777 (otherwise the upload function might not work)
- Create a new folder tokens ([your site]/module/avchat3/include/plugin/tokens) and CHMOD it to 777 (otherwise we might have token generation issues later on)
- Edit [your site]/module/avchat3/include/plugin/avc_settings.php in a text editor and set the value of
$avconfig['connectionstring'] like this:
$avconfig['connectionstring']='rtmp://myFMSserver.com/avchat30/_definst_';- Now login as admin in the phpFox admin area
- Go to Extensions->Product->Import Products and you will be prompted to install AVChat3 Plugin for phpFox
- Click on Install
DONE!!!
You will now find a link to the AVChat 3 Module for phpFox in the main menu!
2. Accessing the AVChat admin interface in phpFox
If you want to log in as hidden, kick/ban users, close/delete rooms, view users IP's and a lot of other stuff that makes you feel like GOD you will have to use the AVChat admin interface, here's how to access it:
On phpFox 1.6:
...
On phpFox 2:
From the front end of the web site:
- go to CHAT (link in the main menu). The AVChat admin interface will automatically load if you have access to it.
From the AdminCP:
- go to Modules -> AVChat3:
On phpFox 3:
From the front end of the web site:
- go to CHAT (link in the main menu). The AVChat admin interface will automatically load if you have access to it.
3. Location of AVChat files in a phpFox installation
On phpFox 1.6:
[your site]/plugins/videochat/
On phpFox 2.0 and 3.0:
[your site]/module/avchat3/include/plugin/
4. Opening up the video chat in a pop up
phpFox 1.6 and 2:
We're still working on this tutorial.
phpFox 3:
- From Admin CP click on Settings -> Manage Settings:
- Click on General AVChat 3 Settings
- Under Open Method select popup:
- Click on Submit at the bottom of the page
5. Placing ads around the video chat
We're still working on this tutorial.
6. phpFox's user roles and limiting features for specific user roles
Each user in phpFox belongs to a user group.
phpFox 1.6 ships with 6 user groups:
Normal,Guest,Staff and Admin user groups are built-in phpFox and can not be removed
Gold and VIP are 2 custom user groups with which phpFox ships, and they can be removed/replaced or new ones can be added .To control the features for each one of them you need to edit this file:
[your site]/plugins/videochat/integration.php .And you'll have to know a little bit of php. Here are the default permissions for the Normal user level:
//Normal Account permissions
if ($getuserinfo["type"] == 3){
$avconfig['freeVideoTime'] = 0;
$avconfig['createRoomsEnabled'] = 1;
}phpFox 2 and 3:
phpFox ships with 4 default user groups that can not be removed: Administrators, Registered User, Guest and Staff.
To manage user group settings (screenshots from phpFox3):
- first log into your AdminCP
- Go to Users -> Manage User Groups (under User Group Manager):
- Click the arrow in front of the user group you want to change AVChat permissions for
- Click on Manage User Settings:
- Click AVChat3
The permissions for AVChat 3 will load up, here's how they look on phpFox2:
And here's how they look on phpFox3:
Pretty neat huh? :)
Change the permissions for that specific user group and click SAVE.
7. Allowing visitors to join the video chat
On phpFox 1.6 edit [your site]/plugins/videochat/integration.php and at the bottom set $avconfig["showLoginError"] = 0; .
On phpFox 2.0 and 3 edit [your site]/module/avchat3/include/plugin/integration.php and at the bottom set $avconfig["showLoginError"] = 0; .
8. Changing the looks of AVChat to better fit your phpFox web site
Changing the design & looks of AVChat is explained in detail in the documentation for the standalone version.
phpFox 1.6:
When working with the phpFox 1.6 Plugin keep in mind that AVChat is installed in [your site]/plugins/videochat/, so all the files you need to edit (like style.css for fonts and colors, avc_settings.php for the background image) are there.
The files that contains the embed code for the AVChat Flash .swf file (the ones you need to edit in order to change the size or background color of AVChat in phpFox) are:
- [your site]/plugins/videochat/videochat.php (user interface)
- [your site]/plugins/videochat/videochat-admin.php (admin interface)
phpFox 2.0 and 3.0:
When working with the phpFox 2 Module keep in mind that AVChat is installed in [your site]/module/avchat3/include/plugin/ , so all the files you need to edit (like style.css for fonts and colors, avc_settings.php for the background image) are there.
The files that contains the embed code for the AVChat Flash .swf files (the ones you need to edit in order to change the size or background color of AVChat in phpFox) are:
- module\avchat3\template\controller\index.html.php user interface
- module\avchat3\template\controller\admincp\index.html.php admin interface
9. Displaying who's in the video chat on your phpFox 2 and 3 web site
For phpFox 2 and 3 we have this great tutorial that shows you how to display on every page of your web site who is in the video chat, their profile picture and a link to their profile:
- Login as admin and go to Admin CP
- Go to Extension -> Module -> Add Component
- Complete the form:
- Product: Select AVChat3 plugin for phpFox
- Module: Select AVChat3
- Component: chatters
- Type: Select Block
- Active: Yes
- Press Submit

- Got to CMS >> Blocks >> Add New Block
- Complete the form (see Image 2):
- Product: Select AVChat3 plugin for phpFox
- Module: Select AVChat3
- Title: You can choose the title. We choose: Online Chatters
- Type: Select PHP Block File
- Controller: Here you can choose the page to display the Who's chatting module. We wanted to display the module on the member's dashboard: -- core.index-member
- Component: The component we created in Step 1:-- chatters
- Placement: We choose on the right side: Block 1
- Can drag and drop: It's up to you
- Active: Yes
- Allow access: We allowed all user groups.
- Press Submit.

- After completing these steps, go to Your site >> Dashboard. You should see the "Who's chatting" block on the right of your site:

Here's the Who's Chatting Block for phpFox 3 in action:
This module uses the external users list generated by AVChat, so you need to login as a user in the video chat trough the front end of Joomla! before the Who's Chatting Module will start showing who's online.












