You want your social network to run as fast as possible. There are a number of ways you can increase performance by reducing page sizes and database connections. This article covers a number of tips to improve your page load times.
The amount of HTML that is returned to your website visitors determines the overall page size. Caching a website that runs a social network is not ideal due to the changing content that can happen all the time. So, you want to reduce the size of other HTML that is included but not essential.
In WPS Pro->Shortcodes, every shortcode can include a set of styles to alter layout. If switched on globally (towards the bottom of every shortcode set of options is a link to switch it on and off), CSS will be inserted for every WP Symposium Pro shortcode used on a page, including the overhead of a database call to get the styles stored. If you are not using them, switch global styles off.
You can use styles on an individual shortcode by adding styles=”1″ to that shortcode.
As an alternative, use HTML in your page (via the Text tab on the editor) to layout your shortcodes.
Note that before and after are not included in styles and will still display if used on the shortcode.
Some themes, especially those that include a lot of features, and fancy page design plugins, include a lot of HTML and CSS within the page which can dramatically increase the size of your page. Consider trying different themes to get a balance between functionality and overall page size.
The more widgets you include, the more HTML/CSS will be returned. Use widgets intelligently and where needed, not “just because you can”. Plugins exist to include widgets on certain pages, or even different sidebars on different pages to make them more selective.
Ensure images are optimised for being used online. Re-size them accordingly with image applications or online for free.
Keep your page sizes smaller by using pagination. Switch this on via WPS Pro->Shortcodes. Look in Forums->[wps-forum] and switch pagination on under “For both styles…” and “For single topic view…”.
Limit item lists
When choosing how many friends, recent users, activity, forum posts, etc to show (often in widgets) keep the number displayed to a useful number without going over the top. Less content equals smaller page size.
As mentioned, the more that is going on within a page, especially in a social network, the more database calls that are made. Some are especially complicated when groups, friendships, security, visibility and so on have to be checked like on the activity page.
If you want to reduce the number of database connections, make pages on your site specific and not crowded with lots of shortcodes in the page and/or widgets. When adding a feature to a page or widget, always think, do your users really need it or are you adding it “just because you can”?
Do you need an A to Z at the top of the page? This adds more work, so switch it off via WPS Pro->Shortcodes->Directory. The same applies to friendship status on the directory. Do you need to show this on the directory? If not, switch it off in the same set of options.
As with page load, reduce the work being done on the page by enabling pagination. Switch this on via WPS Pro->Shortcodes. Look in Forums->[wps-forum] and switch pagination on under “For both styles…” and “For single topic view…”.
With all shortcodes you can set many options, use them wisely to reduce the number of connections that might be made.
As administrator you might think it’s a good thing to use “Default Friends” feature to automatically become friends with every new user. Are you sure you need to? This will slow you experience of your own website (if you log in as the administrator) as all the applicable features are having to check your friendship status with more and more users. If you really need to, consider using a normal user account for when you are “using” your social network.
Often the holy grail of website performance, when looking to host you can choose between shared hosting, cloud hosting, dedicated server, and then options for all those!
When choosing your host consider the following:
- Will then install WordPress for you with a database and PHP? Access to phpMyAdmin will always come in handly. Do they keep PHP and Apache (for the database) updated?
- How do they score performance wise? Server reliability and uptime scores can be checked with some “Googling”. They should have at least 99.5% uptime score. Less than 99% is not acceptable.
- What is there support like? You often pay a little more for a company with good support, but when you need it you’ll be glad! If you confident you can handle all problems yourself, then maybe it’s not so important, but consider it carefully.
- Database performance. A social network demands a lot of it’s database. If your social network is big, you’ll need to be able to server multiple concurrent connections.
- Memory. Is this automatically managed or can you reserve memory for your site? Golden rule of memory is that more is always better, it will help with performance, database, everything really.
- Location can make a difference – if your target audience is, for example, in Europe, don’t host in the US or all website traffic has to travel across the Atlantic every time, it all adds up.
- Reviews….. Do your homework. Perhaps you’ve shortlisted a few companies, or perhaps you want to see what other people are doing. Google it! But do consider when reading a review which site you are reading it on. Are they impartial? We they just unlucky? Is it recent or out of date? Be careful of anecdotal information.
Ask around, fire off some emails to website admins asking who they host with and are they happy?
And to answer that straight away (we are not affiliated in any way, just for information) we currently have a dedicated server with 1and1 in the US. The WP Symposium Pro Codex Admin Guide at www.wpspro.com is on shared hosting with UK2 in the UK.