vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.7 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=228)
-   -   Integration with vBulletin - BritePic Integration (https://vborg.vbsupport.ru/showthread.php?t=181384)

M-Tuning 06-02-2008 10:00 PM

BritePic Integration
 

Britepic is a service from Adbrite which includes ads in your images.
Here's a demo: http://www.britepic.com/

If you want to use this mod you first will need an account with Adbrite/Britepic.

You can make an account here: https://www.adbrite.com/mb/britepic_...ource=britepic

Open the file includes/class_bbcode.php
Search the line (~line 1950 ):

Code:

return '<img src="' .  $link . '" border="0" alt="" />';
And replace with:

Code:

return '<script>
 britepic_id="your_unique_britepic_id";
 britepic_src="' .  $link . '";
</script>
<script src="http://www.britepic.com/britepic.js"></script>
<noscript>
<img src="' .  $link . '" alt="" />
</noscript>';

Do not forget to put your BritePic ID in the Replacement code above.

Credits to
veenuisthebest for the idea & Milad for the XHTML 1.0 Transitional code change.

Please click Install when you like this hack!

M-Tuning 06-03-2008 01:21 PM

To do:

- Make links working with the images (Linked images don't work yet)
- Image resizing

If anyone want's to help me with these things, I will really appreciate it.

Milad 06-03-2008 01:30 PM

In order to be XHTML 1.0 Transitional compatible, the code must be like this:

PHP Code:

return '<script>
<!--
    britepic_id="Your unique BritePic ID";
    britepic_src="' 
.  $link '";
// -->
</script>
<script type="text/javascript" src="http://www.britepic.com/britepic.js"></script>
<noscript>
    <img src="' 
.  $link '" alt="" />
</noscript>'


Give credits to who deserve.

M-Tuning 06-03-2008 01:36 PM

Thanks, changed it.

Now i only have to see how I can get links and resizing to work with BritePic.

logicuk 06-03-2008 01:39 PM

If you can do this for guests only this would be an amazing hack!

M-Tuning 06-03-2008 01:41 PM

Quote:

Originally Posted by logicuk (Post 1539704)
If you can do this for guests only this would be an amazing hack!

That shouldn't be too hard.

7lanet 06-03-2008 02:13 PM

Your unique BritePic ID = site ?? (( www.7lanet.com/vb )) ??

M-Tuning 06-03-2008 02:14 PM

No, you will get the id ( a number ) when you register on adbrite/BritePic

7lanet 06-03-2008 02:14 PM

Parse error: syntax error, unexpected T_STRING in /home/joker/public_html/vb/includes/class_bbcode.php on line 1952

M-Tuning 06-03-2008 02:23 PM

I see, the code for showing only to guests is not ok right now, I will see what's the problem and place the code again when it works.


All times are GMT. The time now is 07:08 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01116 seconds
  • Memory Usage 1,738KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_code_printable
  • (1)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete