Displaying a user's social media information
Style (PHP)


At the beginning, the test seems pretty weird but in any case, I usually prefer  

$var = (condition) ? val1 : val2;


over 

if(condition) {
    $var = val1;
} else {
    $var = val2;
}

You can replace

if(condition1) {
    if(condition2) {
        stuff();
    }
}


with

if(condition1 &amp;&amp; condition2) {
    stuff();
}



On top of that, the if(!$display_tweets || !$twitter_username) test would then be useless as it would correspond to the else case.


There's no point in closing php tags just before reopening them. Remove the ? &gt; &lt; ? php tags.


Style (HTML)


Do you really want to use the em markup inside the h2 one?


What you are actually doing/trying to do


The code at the beginning seems to be assuming that we have a least facebook or twitter (sometimes both).


If this is indeed the case, the
$width = ($facebook &amp;&amp; !$twitter_username || !$facebook &amp;&amp; $twitter_username) ? "490" : "930";
at the beginning could become
$width = ($facebook &amp;&amp; $twitter_username) ? "930" : "490";
If it is not the case, could the beginning be behind an if (twitter || facebook) test as creating an empty div (and giving it an arbitrary width) might not be relevant. If you want to keep it, for the definition of the width, I'd rather have someting like : 
$width = ($facebook &amp;&amp; $twitter_username) ? "930" : (($facebook || $twitter_username) ? "490" : "1");

It might be interesting to use &lt;a href="&lt;?= $website_url; ?&gt;" &gt; or something like that to display the url as an actual link to make things easier from a user point of view (here I assumed that the input has been sanitized properly). On top of that, I don't understand why you hardcode the www. string (have a look at your current adress bar for more details). If there was anything to be hardcoded (and I personally wouldn't go for that), it's more likely to be the http:// part.