<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>Getting Started</title>
<meta name="viewport" content="width=device-width">
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<style type="text/css">
body {
font-family: "Poppins",sans-serif;
font-size: 1rem;
padding: 0;
line-height: 1.5;
color: #212529;
margin: 0;
}
*{
box-sizing:border-box;
}
/* ~~ Top Navigation Bar ~~ */
#navigation-container {
display: flex;
justify-content: space-between;
padding:10px;
align-items:center;
}
.navigation-bar {
width: 100%;
}
.navigation-bar img{
float:left;
}
.navigation-bar ul {
margin-top: 20px;
display:flex;
flex-wrap:wrap;
justify-content:center;
}
.navigation-bar li {
list-style-type: none;
padding:10px 15px;
}
.navigation-bar li a {
color: #0067f4;
font-size: 16px;
font-weight: 400;
vertical-align: text-top;
text-decoration: none;
}
.navigation-bar li a:hover{
text-decoration:underline;
}
p {
line-height: 1.5em;
}
a {
color: #0067f4;
}
h1 {
font-size: 13pt;
}
h2 {
font-size: 13pt;
}
h3 {
font-size: 10pt;
}
h1,
h2 {
-moz-border-radius: 4px;
-webkit-border-radius: 4px;
background-color: #3399ff;
padding:10px;
color: #FFFFFF;
}
ul.toc li {
list-style-type: none;
}
code {
font-family: "Courier New", courier, serif;
}
.content {
max-width:850px;
margin:0 auto;
padding:0 15px;
}
.indent {
padding-left: 10px;
}
.copyright_section {
background: #E9E9E9;
display: flex;
justify-content: space-between;
align-items:center;
padding:10px;
margin-top:40px;
}
li > span {
margin-left: 5px;
}
.social_icon {
display: flex;
justify-content: flex-end;
flex: 1;
}
.social_icon li:first-child a img {
margin-left: 0;
}
.social_icon li a img {
margin-left: 8px;
transition: 0.5s;
width: 32px;
}
.social_icon li {
list-style: none;
}
@media only screen and (max-width: 850px){
#navigation-container{
flex-direction:column;
}
iframe{
max-width:100%;
}
.copyright_section{
flex-direction:column;
justify-content:center;
}
}
</style>
</head>
<body>
<div class="navigation-bar">
<div id="navigation-container">
<a href="https://socialengine.com">
<img class="logo" src="application/modules/Core/externals/images/logo.png" alt="SocialEngine PHP" title="SocialEngine PHP" />
</a>
<ul>
<li><a href="https://community.socialengine.com/blogs">Knowledge Base</a></li>
<li><a href="https://sehosted.socialengine.com/clientarea.php">Client Dashboard</a></li>
<li><a href="https://sehosted.socialengine.com/submitticket.php">Support</a></li>
<li><a href="https://www.socialengine.com/hosting-providers/">Hosting</a></li>
</ul>
</div>
</div>
<div class="content">
<h1 id="Getting-Started">Getting Started</h1>
<p>This documentation describes how to get started with SocialEngine PHP.</p>
<br />
<h2 id="Requirements">Requirements</h2>
<div class="indent">
<h3 id="Minimum">Minimum</h3>
<ul>
<li>Apache-based VPS web server</li>
<li>Apache mod_rewrite (for SEO-friendly URLs)</li>
<li>MySQL 5.7</li>
<li>PHP 8.0</li>
<li>
PHP configuration options
<ul>
<li><span>magic_quotes_gpc</span><span>=</span><span>Off</span></li>
<li><span>safe_mode</span><span>=</span><span>Off</span></li>
</ul>
</li>
<li>
PHP extensions
<ul>
<li>GD2<span>(image processing)</span></li>
<li>cURL<span>(fetching URLs)</span></li>
<li>iconv<span>(required for non-English support)</span></li>
<li>IntlChar <span>(required for Unicode characters support for mobile apps)</span></li>
<li>Imagick <span>(ImageMagick) required for gif image support and mobile device image rotation</span></li>
<li>MySQLi</li>
</ul>
</li>
<li>PHP memory limit: 32M+</li>
<li>Sendmail</li>
<li>Disable mod_security/mod_security2</li>
<li>Disable open_basedir</li>
<li>OpenSSL ENABLED</li>
</ul>
<h3 id="Recommended">Recommended</h3>
<ul>
<li>Apache-based VPS or dedicated web server</li>
<li>PHP 8.0</li>
<li>MySQL 8 or newer</li>
<li>crontab</li>
<li>dom<span>(required for link previews)</span></li>
</ul>
<h3 id="Optional">Optional</h3>
<ul>
<li>memcached (speed boost)</li>
<li>
PHP extensions:
<ul>
<li>bcmath<span>(speed boost)</span></li>
<li>hash OR mhash<span>(required for Amazon S3 support)</span></li>
<li>json<span>(speed boost)</span></li>
<li>mbstring<span>(required for non-English support)</span></li>
<li>mysqli OR pdo_mysql<span>(more reliable SQL support)</span></li>
</ul>
</li>
</ul>
<h3 id="Optional-Requirements-for-Video-Plugin">Optional Requirements for Video Plugin</h3>
<ul>
<li>ffmpeg (for encoding video) - without ffmpeg, users can still post YouTube and Vimeo videos.</li>
</ul>
<h3 id="How-do-I-check-if-my-host-is-compatible-with-SocialEngine PHP">How do I check if my host is compatible with SocialEngine PHP?</h3>
<p>Most modern hosting providers are compatible with SocialEngine PHP, but if in doubt you can contact them directly and refer them to this page <a href="https://community.socialengine.com/blogs/597/130/requirements-v6-3-and-above">SocialEngine Requirements</a>.</p>
</div>
<br />
<h2 id="Installation">Installing SocialEngine</h2>
<div class="indent">
<h3 id="Installation-Video">Video</h3>
<p>
<iframe width="560" height="315" src="https://www.youtube.com/embed/P-gUEzsesjU" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen></iframe>
</p>
<h3 id="Installation-Instructions">Instructions</h3>
<p>Please follow the instructions below or refer to our knowledge base <a href="https://community.socialengine.com/blogs/597/4/installing-socialengine-php">Installation Instructions</a>.</p>
<ol>
<li>In order to install SocialEngine, you need four pieces of information. If you don't have any of these, please contact your hosting provider and ask them for assistance.
<ul>
<li>MySQL Server Address (often "localhost", "127.0.0.1", or the server IP address)</li>
<li>MySQL Database Name</li>
<li>MySQL Username</li>
<li>MySQL Password</li>
</ul>
</li>
<li>Download the SocialEngine PHP ZIP file and extract it to your computer.</li>
<li>Upload all of the files to your hosting account (it can exist either in the root HTML directory, or a subdirectory).
<ul>
<li>If you are using a Unix server (or Unix variant, like Linux, OS X, FreeBSD, etc.) you must set the permissions (CHMOD) of the following directories and files to 777:
<ul>
<li><code>/install/config/</code> (recursively; all directories and files contained within this must also be changed)</li>
<li><code>/temporary/</code> (recursively; all directories and files contained within this must also be changed)</li>
<li><code>/public/</code> (recursively; all directories and files contained within this must also be changed)</li>
<li><code>/application/themes/</code> (recursively; all directories and files contained within this should also be changed)</li>
<li><code>/application/packages/</code> (recursively; all directories and files contained within this should also be changed)</li>
<li><code>/application/languages/</code> (recursively; all directories and files contained within this must also be changed)</li>
<li><code>/application/settings/</code> (recursively; all files contained within this must also be changed)</li>
</ul>
</li>
</ul>
</li>
<li>Access the SocialEngine installer by accessing your website; the installer wizard will automatically begin.</li>
</ol>
<h3 id="Signing-In">Signing In</h3>
<p>Member and Admin accounts are unified in SocialEngine, so you as the site owner can use the same username and password to access the website. A user account with super-admin privileges is created for you during the installation process. Additional user accounts can be created via the signup process, and specific privileges can be assigned by you, the admin, after the account has been created.</p>
<p>To access the admin panel, please follow this tutorial at our knowledge base, <a href="https://community.socialengine.com/blogs/597/9/how-to-access-the-admin-panel" >Accessing the Admin Panel</a>.</p>
</div>
<br />
<h2 id="Plugin-Installation">Plugin Installation</h2>
<div class="indent">
<p>Plugin installation will function similar to the SocialEngine upgrade process.</p>
<h3 id="Plugin-Installation-Video">Video</h3>
<p>
<iframe width="560" height="315" src="https://www.youtube.com/embed/EvZV8VA49Fc" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen></iframe>
</p>
<h3 id="Plugin-Installation-Instructions">Instructions</h3>
<p>To install plugins, please follow the instructions below, or refer to our knowledge base <a href="https://community.socialengine.com/blogs/597/6/package-and-plugin-installation" >plugin installation tutorial</a>.</p>
<ol>
<li>Download each of the plugin TAR files you wish to install.</li>
<li>Log in to your SocialEngine site and access the Admin area.</li>
<li>Access the <em>Manage</em> menu and click on <em>Packages & Plugins</em>.</li>
<li>Click on the <em>Install New Packages</em> link, then on the <em>Add Packages</em> link.</li>
<li>Select the TAR files you download in step 1</li>
<li>Follow the step-by-step wizard to complete the installation of the plugin files.</li>
</ol>
</div>
<br />
<h2 id="Upgrading">Upgrading SocialEngine</h2>
<div class="indent">
<p>SocialEngine PHP supports upgrades via our package manager in the Admin panel. Please follow the instructions below or refer to our knowledge base <a href="https://community.socialengine.com/blogs/597/7/performing-upgrades">Performing Upgrades tutorial</a></p>
<h3 id="Upgrading-Video">Video</h3>
<p>
<iframe width="560" height="315" src="https://www.youtube.com/embed/wt5ogBYYfto" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen></iframe>
</p>
<h4 id="Upgrading-Instructions">Instructions</h4>
<ol>
<li>Download the latest Core Upgrade available from your <a href="https://sehosted.socialengine.com/" target="_blank">SocialEngine Client area</a>.</li>
<li>Log in to your SocialEngine site and access the Admin area.</li>
<li>Access the <em>Manage</em> menu and click on <em>Packages & Plugins</em>.</li>
<li>Click on the <em>Install New Packages</em> link, then on the <em>Add Packages</em> link.</li>
<li>Select the Core Upgrade file you download in step 1. After the file is uploaded, a <em>Continue</em> button will appear at the bottom of the page.
<br /><small>Note: if you have trouble uploading the files using the uploader tool, you can also upload the TAR file manually over FTP to the <code>/temporary/package/archive/</code> directory.</small></li>
<li>Follow the step-by-step wizard to complete the upgrade of the Core files.</li>
</ol>
</div>
<br />
<h2 id="Developers-Guide">Developers Guide</h2>
<div class="indent">
<h3 id="Tools">Tools</h3>
While the following are not necessary for modifying SocialEngine PHP, we recommend the following tools for your development environment.
<ul>
<li>Netbeans IDE ( <a class="external" href="https://netbeans.org/features/php/">https://netbeans.org/features/php/</a> )</li>
<li>PhpStorm ( <a class="external" href="https://www.jetbrains.com/phpstorm/">https://www.jetbrains.com/phpstorm/</a> )</li>
<li>Set SocialEngine to be in "Development" mode (see <code>Admin > Settings > General Settings</code>). This prevents the use of caching, while also enables error messages to be displayed to the front-end interface.</li>
</ul>
<h3 id="Structure">Structure</h3>
<p>SocialEngine is based on the Zend Framework, and is built in an MVC (Model-View-Controller) structure. It is also built with modularity in mind.</p>
The directory structure is as follows:
<ul>
<li><code>/application/</code><br />
This directory contains the majority of SocialEngine files.
<ul>
<li><code>/application/languages/</code><br />
See the section below on <a href="#Languages" class="wiki-page">Languages</a></li>
<li><code>/application/libraries/</code><br />
Third party PHP libraries are typically contained in here. For example, Zend Framework and CSS Scaffold both live in this directory, as does our extensions to Zend Framework (called Engine).</li>
<li><code>/application/modules/</code><br />
See the section below on <a href="#Plugins" class="wiki-page">Plugins</a></li>
<li><code>/application/settings/</code><br />
These files contain configurations that typically will not be modified after your initial installation. Things like your database username/password, cache settings, mail settings, etc. are stored in here.</li>
<li><code>/application/themes/</code><br />
See the section below on <a href="#Themes" class="wiki-page">Themes</a></li>
</ul>
</li>
<li><code>/development/</code><br />
Various tools that we have used during development are contained in this directory. You can mostly ignore these files.</li>
<li><code>/externals/</code><br />
Most of our images, javascript libraries, and flash applications that are used globally are retained in this directory. These should contain trusted (i.e. not user-uploaded) content.</li>
<li><code>/public/</code><br />
User-uploaded content is always contained in here. This directory should be both web-accessible and writable by the web server (chmod 777 recursively).</li>
<li><code>/temporary/</code><br />
Various temporary files, such as cache files, logs, session files, etc. are stored in this directory. It should not be web-accessible, but must be writable by the web server (chmod 777 recursively). We provide an ".htaccess" file to block access to this directory from the web browser, but if you are using a web server other than Apache, we recommend you configure the web server accordingly to prevent view access.</li>
</ul>
<h3 id="Plugins">Plugins</h3>
<p><code>/application/modules/*</code></p>
<p>Most of SocialEngine's functionality resides here. Each module contains within it the MVC structure, where the "Model", "views", and "controllers" directories correspond to the MVC paths. Please see our included skeleton module "HelloWorld" for more information on this.</p>
<h3 id="Languages">Languages</h3>
<p><code>/application/languages/*</code></p>
<p>Each language gets its own two-letter (or 5-character with localization support) directory in this subdirectory. The language files are in multiple CSV files, though they are concatenated into one large CSV file (in no particular order, except that "custom.csv" is the last). One important point to keep in mind is that duplicate keys override previously defined keys. So, for example, if you have a key "Turtles are fast!" in both core.csv and custom.csv, since custom.csv is loaded last, the value set to "Turtles run fast!" in custom.csv will be the one used.</p>
The CSV files have several requirements:
<ul>
<li>Each line has at minimum two columns, and can contain more for different pluralizations.</li>
<li>Each column is separated using a semicolon, and is enclosed in "double-quotes" if it contains any sort of white-space (we recommend wrapping your values in quotes in all cases just to be safe).</li>
<li>The first column is always going to be the <code>key</code>. This is the English word or phrase that exists in the view script, controller, or other portion of the code.</li>
<li>The second column is always going to be the default translation of the <code>key</code>.</li>
<li>If there is a subsequent columns after the second column, it will be for various pluralizations of the <code>key</code>.</li>
<li>Untranslated variables can be contained within a translation <code>key</code> and translations. Variable replacement is done using the PHP function <a href="https://php.net/sprintf" class="external">sprintf</a> , and so the same rules apply. When only one variable is being injected into a translation, typically "%s" is the placeholder for that variable. If multiple variables are being injected, you can use "%1$s", "%2$s", "%3$s" etc to put the variables in their proper positions for your translation.</li>
<li>If your translation has double-quotes in it, you must use two double-quotes. So as an example, the sentence 'He said "wow".' would appear in a CSV files as:<br />
<code>"He said ""wow"".";"He said ""wow""."</code></li>
</ul>
<h3 id="Themes">Themes</h3>
<p><code>/application/themes/*</code></p>
<p>We utilize a framework called "CSS Scaffold" which makes editing your community's theme a simple process. Each theme is stored in its own directory within <code>/applications/themes/</code>. A default theme is automatically loaded when you first install SocialEngine. Each theme contains two files: constants.css and theme.css.</p>
<p>At the top of constants.css, you'll find a series of global CSS settings (called "constants"). You can edit these to adjust the colors, fonts, and other styles throughout your entire community.</p>
<p>The other file, theme.css, contains more specific styles that are used throughout your community. Many of these styles inherit values from constants.css. If you want to override any of the default styles on your community, you can edit them here. If they aren't present in theme.css (and are being loaded from outside the theme itself), you can override them by adding new styles to the bottom of theme.css.</p>
<p>More information about how to work with CSS Scaffold is available here:
<a class="external" target="_blank" href="https://github.com/sunny/csscaffold">https://github.com/sunny/csscaffold</a> or
<a class="external" target="_blank" href="https://www.google.com/search?q=csscaffold">Google for CSScaffold</a> for videos and tutorials.
</p>
</div>
</div>
<div class="copyright_section">
<div>
<a href="https://socialengine.com">
<img class="logo" src="application/modules/Core/externals/images/logo.png" alt="SocialEngine PHP" title="SocialEngine PHP" />
</a>
</div>
<div>
<p>Copyright © 2007 - <script type="text/javascript">document.write(new Date().getFullYear())</script> SocialEngine</p>
</div>
<div>
<ul class="social_icon">
<li><a href="https://www.facebook.com/socialengine" target="_blank"><img src="application/modules/Core/externals/images/facebook.png" alt="Facebook"></a></li>
<li><a href="https://twitter.com/socialengine" target="_blank"><img src="application/modules/Core/externals/images/twitter.png" alt="Twitter"></a></li>
<li><a href="https://www.youtube.com/user/socialenginetv" target="_blank"><img src="application/modules/Core/externals/images/youtube.png" alt="YouTube"></a></li>
<li><a href="https://www.linkedin.com/company/socialengine" target="_blank"><img src="application/modules/Core/externals/images/linkedin.png" alt="Linkedin"></a></li>
</ul>
</div>
</div>
</body>
</html>