Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Can Vanillicon overide facebook / twitter images
essbo
New
Hello,
On my forum I'd like to use the Vanillicon even when someone signs up with facebook or twitter.
Is this possible?
thanks
0
Comments
From my experience, no. You can change your image in the forum but as soon as you log in again with fb or tw it fetches the image again..
❌ ✊ ♥. ¸. ••. ¸♥¸. ••. ¸♥ ✊ ❌
if the experience above is correct, which we will assume is accurate.
it is a a pretty kettle of fish, but you can Horse around with the plugins with a bit of monkey business.
untested but based on above input and a quick scan of the code, potentially you can with some effort.
Change What goes in... sanitize the input as
in facebook plugin
change "//graph.facebook.com/{$ID}/picture?type=large" to ""
in twitter plugin
change val('profile_image_url_https', $Profile) to ""
if the reset occurs on connection there is no need to modify the user table.
if you decide you want to affect the output instead change what comes out sanitize the output
override the UserPhoto in the functions.render.php via the bootstrap method.
look for if ($Photo) {
if (!isUrl($Photo)) {
above those two line - add
// check for photo and is it a url. if the url matches twimg or facebook set the photo to "".
if ($Photo) {
if (isUrl($Photo)) {
if (preg_match('/twimg/',$Photo)) {
$Photo = "";
}
if (preg_match('/facebook/',$Photo)) {
$Photo = "";
}
}
}
in the vanillicon plugin look for (this affects the pic on the profile page).
and do something similar setting the $Sender->User->Photo to "" if it matches either "facebook" or "twimg".
you will need to decide if it is worth the effort.
with UserPhoto override
// TRY ADDING CODE HERE....
// check for photo and is it a url. if the url matches twimg or facebook set the photo to "".
if ($Photo) {
if (isUrl($Photo)) {
if (preg_match('/twimg/',$Photo)) {
$Photo = "";
}
if (preg_match('/facebook/',$Photo)) {
$Photo = "";
}
}
}
Thanks so much, i will give that a whirl