MyBB Community Forums

Full Version: Profile Cover Photo Query
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
(2016-06-12, 11:45 AM)izakgewdrick Wrote: [ -> ]-snip-

i am assuming you followed the toutorial you have linked,
i am going to hop onto the forum that i manage and i will look into finding this out for you
This did not work as you can see....

uhhh yes I did, also tried taking advise from Electric Shock himself, he's no longer replying. I think he cannot solve it either :/
from what i can see the css is not in the correct order for this to work, i will look into it, if i have no luck i will let you know via pm so you are not waiting on a dead reply

ok i had a look into it and unfortunately the css overwrites it anyway, the only thing i can suggest is an if statment using php, however i am not familiar with this form
And might I add, the way the segments have been removed. It works fine (note the pictures) even with the other bits (which make the text unreadable) it will not work. It is not a functionality problem, it is the way it is scripted *and i didn't script it*. It works fine for me without the other parts.

I can code it into php but I need staff to point me to the right file
Got a couple days off, M are you cool to check over my code tonight?
Anything from anyone?????
Personally I made a plugin for this where a user could set a profile background image and it would be stored in the user table.

Then in the plugin file you can do

if(!empty($mybb->user['profilebg']))
{
$profilebg = $mybb->user['profilebg'];
}
else{
$profilebg = "Default bg url"
}
Does it display like this one does?
(2016-06-27, 09:44 AM)izakgewdrick Wrote: [ -> ]Does it display like this one does?

What do you mean?
You are trying to set a default background image? The tutorial uses user fields.

Example. Place this in member_profile:


<if (empty($userfields['fidX'])) then>
	<style>
		.profbg {
background-image: url(XXXX);
}		
       </style>
</if>
		
<if (!empty($userfields['fidX'])) then>
	<style>
           .profbg {
background-image: url({$userfields['fidX']});
}
	</style>
</if>


If that is what you are asking, it is using template conditionals. Paradigm's suggestion will work nicely as well.
Pages: 1 2 3