Bravo List
Register
Go Back   > Bravo List > Source Code > Archived Trackers > TBDev
Reply
Thread Tools
  #1  
Old 30th April 2011, 14:54
cherwonk cherwonk is offline
Senior Member
 
Join Date: Mar 2008
Posts: 15
Default HTTPS
working on our next tracker , newer 09 source. I've got a lot of addons from Bigjoos sources.

I went and add the https option in the usercp , its working real well with one exception....
when you upload to the bitbucket , the links return as https( of course) , well site doesnt like to display the images this way.

I can view the directly and they show up when I click 'View My Images'.
They just dont show in the forums or shouts???

Any ideas?

Thanks in advance
Reply With Quote
  #2  
Old 30th April 2011, 15:54
Bigjoos's Avatar
Bigjoos Bigjoos is offline
U-232 Dev
 
Join Date: May 2008
United Kingdom
Posts: 244
Default
Aye cherwonk seen this bugger happening so i'll do some testing today and will post back : )
Reply With Quote
  #3  
Old 3rd May 2011, 22:32
cherwonk cherwonk is offline
Senior Member
 
Join Date: Mar 2008
Posts: 15
Default
after a little digging and playing , I found that
PHP Code:
 //--img     
    
if (stripos($s'[img') !== false) {      
    
$s preg_replace_callback("/\[img\](http:\/\/[^\s'\"<>]+(\.(jpg|gif|png)))\[\/img\]/i""scale"$s);
    
$s preg_replace_callback("/\[img=(http:\/\/[^\s'\"<>]+(\.(gif|jpg|png)))alt=\"\"\]/i""scale"$s);

    } 
in bbcode_functions
If changed to
PHP Code:
 //--img     
    
if (stripos($s'[img') !== false) {      
    
$s preg_replace_callback("/\[img\](https:\/\/[^\s'\"<>]+(\.(jpg|gif|png)))\[\/img\]/i""scale"$s);
    
$s preg_replace_callback("/\[img=(https:\/\/[^\s'\"<>]+(\.(gif|jpg|png)))alt=\"\"\]/i""scale"$s);

    } 
brings up the pictures . Now my question is do I add a complete copy ...only with the https or can we incorporate it into the original?

atm moment I do have both with no errors and images are displayed for both


got the answer from
Diablo999 , thanks


Code:
   //--img     
    if (stripos($s, '[img') !== false) {      
    $s = preg_replace_callback("/\[img\]((http|https):\/\/[^\s'\"<>]+(\.(jpg|gif|png)))\[\/img\]/i", "scale", $s);
    // [img=http://www/image.gif]
    $s = preg_replace_callback("/\[img=((http|https):\/\/[^\s'\"<>]+(\.(gif|jpg|png)))alt=\"\"\]/i", "scale", $s);
    }

Last edited by cherwonk; 5th May 2011 at 22:25.
Reply With Quote
Reply

Tags
https


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



All times are GMT +2. The time now is 23:59. vBulletin skin by ForumMonkeys. Powered by vBulletin® Version 3.8.11 Beta 3
Copyright ©2000 - 2024, vBulletin Solutions Inc.